平台通知网关子设备删除
功能介绍
平台将该网关删除的子设备信息通知给网关设备。
Topic
下行: $oc/devices/{device_id}/sys/events/down
参数说明
|
字段名 |
必选/可选 |
类型 |
参数描述 |
|---|---|---|---|
|
object_device_id |
可选 |
String |
事件对应的最终目标设备,没有携带则表示目标设备即topic中指定的设备 |
|
services |
可选 |
List<ServiceEvent> |
事件服务列表 |
ServiceEvent定义表
|
字段名 |
必选/可选 |
类型 |
参数描述 |
|---|---|---|---|
|
service_id |
必选 |
String |
$sub_device_manager |
|
event_type |
必选 |
String |
delete_sub_device_notify |
|
event_time |
可选 |
String |
事件时间 |
|
paras |
必选 |
Object |
事件参数JSON对象 |
paras参数列表
|
字段名 |
必选/可选 |
类型 |
参数描述 |
|---|---|---|---|
|
devices |
必选 |
List<DeviceInfo> |
设备列表 |
|
version |
必选 |
Long |
子设备信息版本 |
DeviceInfo定义表
|
字段名 |
必选/可选 |
类型 |
参数描述 |
|---|---|---|---|
|
parent_device_id |
必选 |
String |
父节点设备ID |
|
node_id |
可选 |
String |
设备标识。 |
|
device_id |
必选 |
String |
设备ID |
示例
Topic: $oc/devices/{device_id}/sys/events/down
数据格式:
{
"object_device_id": "{object_device_id}",
"services": [{
"service_id": "$sub_device_manager",
"event_type": "delete_sub_device_notify",
"event_time": "20151212T121212Z",
"paras": {
"devices": [{
"parent_device_id": "c6b39067b0325db34663d3ef421a42f6_12345678",
"node_id": "subdevice11",
"device_id": "2bb4ddba-fb56-4566-8577-063ad2f5a6cc"
}],
"version": 1
}
}]
}
Last Article: 平台通知网关子设备新增
Next Article: 网关同步子设备列表
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.