Overview
Memfault is a device reliability platform for MCU, Linux and Android fleets: it collects crashes, metrics and logs from devices through the Memfault SDKs and runs OTA updates by cohort. These connectors connect the Coreflux broker to the Memfault REST API, so plant logic can check a device’s health and release, move devices between cohorts, roll out firmware and react to new crash issues over MQTT.- MemfaultRestApi (
MemfaultRestApi.lot) is a client connector onhttps://api.memfault.comwith 32 events. - MemfaultWebhookReceiver (
cloud-iot_memfault_webhook.lot, opt-in, server mode) receives Memfault issue and alert webhooks, so new or regressed issues reach MQTT without polling.
Authentication
Every event takes"authorization" in its MQTT payload and sends it as the whole Authorization header, so you can use either Memfault credential:
- Store the full value as the secret
MEMFAULT_AUTHORIZATION. - Every project event also takes
"organization_slug"and"project_slug", as shown in the Memfault app URL. GetLatestReleaseForDeviceis the device-side check and sends"project_key"in theMemfault-Project-Keyheader instead. Project keys aren’t secret, but they let anyone send data into the project.
401 with {"error": {"message": "Unauthorized", "http_code": 401, "type": "UnauthorizedError", "code": 1004}}.
Payload conventions
- Path ids (
device_serial,cohort_slug,release_version,deployment_id,issue_id,task_id,software_type_slug,version) go at the top level of the MQTT payload. - Events marked
?{query}take the query string already URL-encoded, for examplepage=1&per_page=100(default 20, max 100) orstatus=open&sort=-created_date. Timestamps in filters must be ISO 8601 withZ. Send"query": ""when there is nothing to add. - Request bodies come from
"body"and are sent as JSON.
Projects and tasks
Devices
Cohorts
OTA: releases and deployments
A release is a firmware version with its payloads. A deployment activates a release for one cohort, and the devices in that cohort pick it up the next time they ask for the latest release. Astaged_rollout deployment only offers it to a share of the cohort.
Issues
Webhook receiver
Deploycloud-iot_memfault_webhook.lot only if you want Memfault to push notifications to the broker. It opens HTTP port 9004. Put a reverse proxy or tunnel with a public TLS certificate in front of it, and have it verify the X-Signature-SHA256 header (HMAC-SHA256 of the raw body with the target’s signing secret), because the connector itself doesn’t.
- In Memfault, open Settings → Notifications → External Targets and add a Webhook target with the public URL
https://<public host>/memfault/webhook/issues. Keep the signing secret it shows for your proxy. - Add a second target for
https://<public host>/memfault/webhook/alertsand pick it in your alerts. - Use the target’s test notification to check the path: it arrives with
"type": "test_notification.dispatched".
The body is
{"type": "<event type>", "project": {"id": "...", "slug": "..."}, ...}. The Memfault-Delivery header stays the same on retries, so your proxy can use it to drop duplicates. Memfault marks generic webhooks as experimental, so payload fields beyond type and project may change.
Golioth chunk forwarding
If your devices connect through Golioth, Golioth forwards their Memfault chunks itself with thememfault pipeline destination and the project key. Nothing extra runs on the broker. This connector then reads the resulting devices, issues and releases from Memfault. Chunk upload (chunks.memfault.com) isn’t packaged, because chunks are binary.
Examples
Read one device:beta cohort:
1.2.0 to 10% of the beta cohort:
Writes
11 events change data in Memfault, and each one is marked Write above.CreateDeployment, UpdateDeployment, UpdateDevice and MoveDevicesToCohort decide which firmware devices in the field install, so test them on a lab cohort first. No DELETE operation is packaged, so this connector can’t deactivate a deployment or delete devices, cohorts, releases or issues.
Memfault’s published spec has no request schemas for most writes. The
CreateDevice, UpdateDevice, CreateCohort and CreateDeployment bodies above come from the Memfault docs and CLI. Check the other bodies (CreateRelease, UpdateRelease, UpdateCohort, UpdateDeployment, UpdateDeviceAttributes, MoveDevicesToCohort, and the UpdateIssue values for resolved or muted) against your project before you rely on them.Not packaged
User API key management, project create, update and delete, project and client keys, data uploads (chunks, events, traces, coredumps, bug reports, symbols and release artifacts on thechunks, ingress and files hosts), software type and version create, installs (listed in the spec, but the live API returns 404 for them), SBOMs, nRF Cloud bulk device creation and every DELETE are left out of this template.
Status
Technical preview, and blocked on a live test. The events were checked against Memfault’s published OpenAPI, and all 32 events reach the realapi.memfault.com host and are rejected without a valid credential as expected. An authenticated read and write with a real Memfault organization token is still pending.
