Appearance
Add Device (Single)
API Address:/v2/devicemgr/r3/openapi/device/create
Request Method:POST
Request Data Type:application/json
Response Data Type:*/*
API Description:
Request Example:
javascript
{
"authMode": 0,
"deviceKey": "",
"deviceName": "",
"fingerPrint": "",
"productKey": "",
"psk": "",
"sn": ""
}
Request Parameters:
Parameter Name | Parameter Description | Request Type | Required | Data Type | Schema |
---|---|---|---|---|---|
deviceCreateSingleR3Dto | deviceCreateSingleR3Dto | body | true | New device input parameters | New device input parameters |
authMode | Authentication method, 0-Dynamic authentication 1-Static authentication 2-X509, default 0 | false | integer(int32) | ||
deviceKey | Device DK | true | string | ||
deviceName | Device name | false | string | ||
fingerPrint | Device fingerprint, required for X509 device addition | false | string | ||
productKey | Product PK | true | string | ||
psk | psk, required for China Telecom AEP device addition | false | string | ||
sn | Device SN | false | string |
Response Status:
Status Code | Description | Schema |
---|---|---|
200 | OK | ActionResultOfobject |
201 | Created | |
401 | Unauthorized | |
403 | Forbidden | |
404 | Not Found |
Response Parameters:
Parameter Name | Parameter Description | Type | Schema |
---|---|---|---|
code | Return code | object | |
data | Object | object | |
exp1 | string | ||
msg | Prompt message | object | |
pageNum | Current page number | object | |
pageSize | Items per page | object | |
pages | Total pages | object | |
total | Total count | object |
Response Example:
javascript
{
"code": {},
"data": {},
"exp1": "",
"msg": {},
"pageNum": {},
"pageSize": {},
"pages": {},
"total": {}
}