Skip to content
MACHHUB MACHHUB MACHHUB
Contribute to this page

Troubleshooting

Common problems and how to resolve them.

Initialize returns false when it can’t resolve or reach the platform connection. The SDK works in both client and server contexts, so this is a connection problem, not an environment one: in development confirm the MACHHUB Designer proxy is connected; with manual config, check the HTTP API URL, developer key, and application ID. See your framework guide and SDK → Initialization.

Realtime/tag subscriptions don’t work in the browser

Section titled “Realtime/tag subscriptions don’t work in the browser”

Browsers require MQTT over WebSocket, and over HTTPS that must be wss://. Configure the MQTT URL accordingly (e.g. wss://your-server:1884), and make sure the broker’s WebSocket port is reachable. See Realtime.

If you omit the Domain header, requests default to domains:machhub_admin. Set the header (or the SDK’s application_id) to target the right domain. On the data plane, the domain also name-prefixes your tables.

JWTs expire after the configured TTL, and refresh tokens are planned but not yet available — log in again to get a new token. See Authentication.

update() and delete() need the full RecordID (myapp.products:PROD-001), and relations must be written as a reference object { Table, ID } — not a bare string. See RecordID.

A file field returns a filename instead of the file

Section titled “A file field returns a filename instead of the file”

Reading a record returns the file field as a filename string, not a URL. Fetch the bytes with getFile(fileName, fieldName, recordID) to get a Blob, then URL.createObjectURL(blob) to display it (and revokeObjectURL when done). See File handling.

If browser apps on other origins call the API, the server must allow those origins (CORS). See Configuration.

Activate by uploading your .mpl file under Settings → License. See Licensing.

A tag_change process didn’t receive the new value

Section titled “A tag_change process didn’t receive the new value”

A tag_change trigger does not auto-inject the value. Add a tag input so the value appears in context.inputs. See the Process model.