This documents describes the async api for device communication through mqtt.
The topic on which can be subscribed to receive device commands for a certain device
Subscribe to Device Command
Tenant
Site
Device name
Accepts the following message:
{
"parameters": {
"property1": {},
"property2": {}
},
"device": "string",
"command": "string",
"dts": "2019-08-24T14:15:22Z",
"headers": {
"correlationData": "string",
"responseTopic": "string",
"messageExpiryInterval": 0
}
}
The topic on which device events can be published for a certain device
Publish Device Event
Tenant
Site
Device name
Accepts the following message:
Payload for the device event.
{
"device": "string",
"event": "string",
"data": {},
"dts": "2019-08-24T14:15:22Z",
"headers": {
"correlationData": "string",
"responseTopic": "string",
"messageExpiryInterval": 0
}
}
Payload for the device event.
Payload for the device event.
The response which must be posted on the responseTopic
The result of the processing of the device event which will be posted on the responseTopic if both responseTopic and correlationData are provided through the headers. Omit these headers if no result is required.