Provision a connectable
POSThttps://apis.<domain>/iot/provision/mapping
Authorization: http
name: bearerTokentype: httpscheme: bearerin: headerdescription: Authorization Header: `Authorization: Bearer <user_token>`
Provision a connectable.
Authorization Action:
core:provision:mapping
Request
- application/json
Body
init_id stringrequired
MAC address or other identifier.
init_key stringrequired
Unique identifier.
name string
migration_key string
migration_key_quota string
Responses
- 201
- 400
- 401
- 500
Created.
- application/json
- Schema
- Example (from schema)
Schema
things object[]
channels object[]
whitelisted object
Whitelisted is a map of thing id to boolean. If the boolean is true, the thing has been connected to its channels and is whitelisted to exchange message to the cloud.
{
"things": [
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"key": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "string",
"metadata": {}
}
],
"channels": [
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "string",
"metadata": {}
}
],
"whitelisted": {
"5c0b6453-2ec4-4204-801e-e46337fa707a": true
}
}
Bad request.
Unauthorized.
Unexpected server error.
- curl
- python
- go
- nodejs
- ruby
- csharp
- php
- java
- powershell
- CURL
curl -L -X POST 'https://apis.<domain>/iot/provision/mapping' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"init_id": "string",
"init_key": "string",
"name": "string",
"migration_key": "string",
"migration_key_quota": "string"
}'