Delete device
Deletes the user's device.
Request format
DELETE https://api.iot.yandex.net/v1.0/devices/{device_id}
device_id |
ID of the user device. |
Request headers
Header |
Description |
Required |
Authorization |
The authorization token of the OAuth application. |
Yes |
Response format
HTTP/1.1 200 OK
{
"request_id": String,
"status": "ok"
}
Parameter |
Type |
Description |
Required |
request_id |
String |
Request ID. Must be logged for the purpose of incident investigation. |
Yes |
status |
String |
Status of processing the request. Acceptable values:
|
Yes |
HTTP/1.1 404 Not Found
{
"request_id": String,
"status": "error",
"message": String
}
Parameter |
Type |
Description |
Required |
request_id |
String |
Request ID. Must be logged for the purpose of incident investigation. |
Yes |
status |
String |
Status of processing the request. Acceptable values:
|
Yes |
message |
String |
Error message. |
No |
Example
RequestResponse successfulResponse with error
curl -i -X DELETE 'https://api.iot.yandex.net/v1.0/devices/device-id-1' \ -H 'Authorization: Bearer 123qwe456a...'
HTTP/1.1 200 OK { "request_id": "667b3e0f-47a8-4136-9211-b4ff59062315", "status": "ok" }
HTTP/1.1 404 Not Found { "request_id": "667b3e0f-47a8-4136-9211-b4ff59062315", "status": "error", "message": "Устройство не найдено" }
String enclosed in quotation marks, for example: "Hello, world"
.
Идентификатор устройства пользователя.
Type
Description
Request ID. Must be logged for the purpose of incident investigation.
Required
Yes
Type
String
Description
Status of processing the request. Acceptable values:
ok
.
Required
Yes
Type
String
Description
Status of processing the request. Acceptable values:
error
.
Required
Yes
Type
String
Description
Error message.
Required
No