Provision
Device provisioning and management APIs.
These APIs provide devices with the necessary provisioning APIs to manage communications with a device cloud.
GetCerts
Provision a device with MQTT certificates.
After a device has been claimed for management by a user into a device cloud, the device can call "getCerts" to request provisioning of MQTT certificates to secure communications.
This call returns the certificate, private key and communications endpoint to use for secure MQTT communications with the device cloud.
Endpoint
POST /provision/getCerts
Authorized User Role
device
Request Body
Field | Type | Required | Notes |
---|---|---|---|
id | string | yes | Device claim ID. |
Response
MQTT certificate and endpoints for device communications.
Field | Type | Notes |
---|---|---|
accountId | string | App Account ID. |
certificate | string | X.509 certificate. |
endpoint | string | MQTT host endpoint for communciations. |
id | string | Device ID. |
key | string | X.509 certificate key. |
port | number | MQTT TCP/IP port number. |
thing | string | AWS IoT Core thing name for the device. |
GetCreds
Get IAM credentials.
Get credentials for use in the device that is hosted in a dedicated cloud.
This will create temprorary IAM credentials based on the configured Cloud.deviceRole (default IotoDeviceRole). These credentials can be used with appropriate AWS SDK or Ioto AWS Sigv4 APIs.
Endpoint
POST /provision/getCreds
Authorized User Role
device
Response
A set of AWS IAM credentials that can be used with AWS APIs.
Field | Type | Notes |
---|---|---|
accessKeyId | string | AWS access key ID. |
secretAccessKey | string | AWS secret access key. |
sessionToken | string | AWS credentials session token. |
expires | date | When the credentials expire. |
region | string | AWS region. |
Update
Device update.
Check for software updates.
Returns a message if no update is available. Otherwise, returns a download URL, version, update ID and checksum.
Endpoint
POST /provision/update
Authorized User Role
update
Request Body
Field | Type | Required | Notes |
---|---|---|---|
id | string | yes | Device ID. |
product | string | yes | Product name. |
version | string | yes | Version to update to. |
test | boolean | Device is a test device. | |
* | any | Any other fields. |
Response
Object Record.
Field | Type | Notes |
---|---|---|
checksum | string | Download checksum. |
version | string | Version to update to. |
message | string | Message. |
url | string | Download URL for the software update. |
update | string | Selected update ID. |
UpdateReport
Device update report.
Post update status.
Endpoint
POST /provision/updateReport
Authorized User Role
update
Request Body
Field | Type | Required | Notes |
---|---|---|---|
id | string | yes | Device ID. |
update | string | yes | Update status. |
success | boolean | yes | Update success. |