DeviceCommand
Represents a device command, a unit of information sent to devices.
Methods
Method | Authorization | Uri | Description |
---|---|---|---|
Access JSON Web Token (GetDeviceCommand) | GET /device/{deviceId}/command | Queries device commands. | |
Access JSON Web Token (GetDeviceCommand) | GET /device/{deviceId}/command/{commandId} | Gets information about device command. | |
Access JSON Web Token (CreateDeviceCommand) | POST /device/{deviceId}/command | Creates new device command. | |
Access JSON Web Token (UpdateDeviceCommand) | PUT /device/{deviceId}/command/{commandId} | Updates an existing device command. | |
Access JSON Web Token (GetDeviceCommand) | GET /device/{deviceId}/command/{commandId}/poll | Polls new device commands. | |
Access JSON Web Token (GetDeviceCommand) | GET /device/{deviceId}/command/{commandId}/poll | Waits for a command to be processed. | |
Access JSON Web Token (GetDeviceCommand) | GET /device/command/poll | Polls new device commands. |
Resource Representation
{
"id": {integer},
"timestamp": {datetime},
"userId": {integer},
"deviceId": {string},
"networkId": {integer},
"deviceTypeId": {integer},
"command": {string},
"parameters": {object},
"lifetime": {integer},
"status": {string},
"result": {object},
"lastUpdated": {datetime}
}
Property Name | Type | Description |
---|---|---|
id | integer | Command identifier. |
command | string | Command name |
timestamp | datetime | Command UTC datetime (yyyy-MM-dd'T'HH:mm:ss.SSS ISO 8601). |
userId | integer | Associated user identifier. |
deviceId | string | Device unique identifier. |
networkId | integer | Network unique identifier. |
deviceTypeId | integer | Device type unique identifier. |
parameters | object | Command parameters, a JSON object with an arbitrary structure. |
lifetime | integer | Command lifetime, a number of seconds until this command expires. |
status | string | Command status, as reported by device or related infrastructure. |
result | object | Command execution result, an optional value that could be provided by device. |
lastUpdated | datetime | Last command update UTC datetime (yyyy-MM-dd'T'HH:mm:ss.SSS ISO 8601). |
Updated over 4 years ago