Skip to content

MQTT Commanding Feature – Samples for subscribing to an MQTT topic

Commanding Feature Async API defines topics and message structures to subscribe MQTT commands to be executed by the agents and publish the command execution status.

For more information, refer Commanding Feature Async API specifications.

Subscribing Commands

This operation is used to receive the command to be executed by the agent.

Region Operation
Europe 1 tc/{tenantId}/{clientId}/i/cmd_v3/c

Payload example:

{
  "id": "99609765fed2452c8e126814c283a27f",
  "data": {
    "jobId": "21349765fe45652c8e126814c283a114",
    "createdAt": "string",
    "payload": {
      "property1": "string",
      "property2": "string"
    }
  }
}

Publishing Command Execution Status

This operation is used to publish the command execution status and progress.

Region Operation
Europe 1 tc/{tenantId}/{clientId}/o/cmd_v3/u

Payload example:

{
  "id": "11609765fed2452c8e126814c283a289",
  "requestId": "99609765fed2452c8e126814c283a27f",
  "data": {
    "timestamp": "2011-08-12T20:17:46.384Z",
    "jobId": "21349765fe45652c8e126814c283a114",
    "status": "EXECUTING",
    "response": {
      "property1": "string",
      "property2": "string"
    }
  }
}

Last update: September 11, 2023

Except where otherwise noted, content on this site is licensed under the Development License Agreement.