Skip to main content

Devices

Base: /v1/devices. Authenticate with an API key:
Device status lifecycle: pending → enrolled (Gateway) → revoked. Lists include all three unless you pass ?status=. Device activation / WebSocket is handled by the Device Gateway, not these routes. Functions are nested under the same prefix — see Functions API.

External id

Optional external_device_id (string, max 200). Trimmed; empty → null. Unique per customer when set (409 on conflict). Returned on device payloads. Filter list with ?external_device_id= (still requires customer_id). Updatable via PATCH.

Create device

Returns 201 with { "data": { …, "status": "pending", … } } until the Gateway enrolls the device.

List devices

By default returns all device statuses for the customer (pending, enrolled, revoked). Filter with license_id and/or status.
Response: { data: Device[], meta: { page, per_page, total_pages, total_count } }. Revoked devices sort last. You can also list by license path: GET /v1/licenses/{id}/devices (same statuses / status filter). API keys optionally filter by customer / license / device when those filters were set at key creation.

Patch device

At least one of name, adapter, or external_device_id is required. Cannot patch revoked devices.

Delete device

Only revoked devices can be deleted (409 if pending/enrolled). Success: { "data": { "ok": true } }.

Command history

If both page and per_page are omitted, returns the full command set. Response: { data: Command[], meta: { page, per_page, total_pages, total_count } }. Works for revoked devices (historical audit).