V2.1 Delete Device¶
Delete a device.
This API is available in EnOS 2.1.0 and above.
Operation Permissions¶
Ensure that the application has been granted with the invoking permissions. For more information, see Getting API Calling Permissions.
Request Format¶
POST https://{apigw-address}/connect-service/v2.1/devices?action=delete
Request Parameters (URI)¶
Note
Use one of the following methods to specify the device to be deleted:
Include
assetId
in the requestInclude
productKey
+deviceKey
in the request
Name |
Location (Path/Query) |
Mandatory/Optional |
Data Type |
Description |
---|---|---|---|---|
orgId |
Query |
Mandatory |
String |
The organization ID which the asset belongs to. How to get orgId>> |
assetId |
Query |
Optional (See Note above) |
String |
The asset ID. How to get assetId>> |
productKey |
Query |
Optional (See Note above) |
String |
The product key. To be used with |
deviceKey |
Query |
Optional (See Note above) |
String |
The device key. To be used with |
Error Codes¶
Code |
Message |
Description |
---|---|---|
11404 |
Device cannot be found |
The |
Samples¶
Request Sample¶
url: https://{apigw-address}/connect-service/v2.1/devices?action=delete&orgId=yourOrgId&assetId=mAEsF3sm
method: POST
Return Sample¶
responseBody:{
"code":0,
"msg":"OK",
"requestId":"12d7e3be-6bac-43de-8733-7e02a4eb8a88",
"data":null
}
SDK Samples¶
You can access the SDK samples for Connection Service on GitHub: