Skip to main content
POST
Send a remote command to a bound device. Commands are handed to either a Bluetooth relay in the mobile app or the next direct WiFi/4G heartbeat. The current API accepts ordinary commands only when the device has checked in within the previous 60 seconds; it does not queue them for an offline device. For factory reset, use Reset Device: POST /devices/{id}/reset with no request body. factory_reset is a command response type, not an accepted type on this command-creation endpoint.

Authentication

Requires an API key with devices:write scope.

Path Parameters

string
required
The device’s unique identifier (e.g., dev_abc123).

Request Body

string
required
The command type. One of:
  • start_recording - Start a new recording
  • stop_recording - Stop the current recording
  • trigger_upload - Upload any pending recordings stored on the device
object
Optional command data. These values are stored and forwarded, but the current released firmware control paths act on the command type only.
number
Reserved maximum recording duration in seconds (1-86400).
boolean
Reserved request to upload after recording stops.
object
Reserved application metadata stored with the command.
string
Unique key, up to 64 characters, used to return the previously created command for this device. Reuse it only for the same request.
number
Time-to-live for the command in seconds. Command expires if not executed within this time. Default: 300 (5 minutes).

Response

Returns the command object with status set to pending.

Response Fields

Command Lifecycle

Commands go through the following states:

Notes

  • The device must be bound and have a heartbeat less than 60 seconds old when an ordinary command is created.
  • delivered currently records backend handoff to a delivery response, not a device receipt. Ordinary commands are not automatically redelivered after that handoff.
  • For BLE-connected devices, the mobile app polls and relays the command.
  • For direct devices, the command is included in a WiFi/4G heartbeat response.
  • For trigger_upload, executed means the device accepted the upload trigger; use recording state and upload events to track actual file completion.