Appendix: Packets of Subscribed Notification Messages
- Message attributes
{ "deviceIdentifier":"iottest2", //Device identifier "eventTime":"1588843914884", //Message time "gatewayIdentifier":"null", //Gateway identifier "deviceId":"D114VKx7a", //Device ID "gatewayId":"null", //Gateway ID "TAGS":"null" //Message tag }
- For a common device or gateway, set gatewayId and gatewayIdentifier to null.
- For a subdevice, gatewayId and gatewayIdentifier are deviceId and deviceIdentifier of the gateway respectively.
- Message content
- Adding a device
{ 'deviceType':'Default', //Device type 'instanceOid':'40', //Instance OID 'manufacturerName':'iotcompro1',//Manufacturer name 'productOid':'1', //Product OID 'manufacturerId':'iotcompro1', //Manufacturer ID 'remark':'', //Device description 'deviceId':'D114VKx7a', //Device ID 'deviceName':'iottest2', //Device name 'productName':'iotcompro1', //Product name 'notifyType':'deviceAdded', //Message type 'deviceIdentifier':'iottest2', //Device identifier 'deviceOid':'14', //Device OID 'createdBy':'admin', //Creator 'eventTime':'1588843914884', //Message time 'model':'iotcompro1', //Product model 'productType':'0', //Product type. 1: gateway product; 0: common product. 'status':'0', //Device status. 0: enabled; 1: disabled. 'parentDeviceOid':'null' //Parent device OID } - Deleting a device
{ 'notifyType':'deviceDeleted', //Message type 'deviceIdentifier':'iottest2', //Device identifier 'eventTime':'1588843914884', //Message time 'deviceId':'D114VKx7a', //Device ID } - Taking a device online
{ 'notifyType':'deviceOnline', //Message type: device online 'deviceIdentifier':'iottest2', //Device identifier 'eventTime':'1588843914884', //Message time 'deviceId':'D114VKx7a', //Device ID } - Taking a device offline
{ 'notifyType':'deviceDeleted', //Message type 'deviceIdentifier':'iottest2', //Device identifier 'eventTime':'1588843914884', //Message time 'deviceId':'D114VKx7a', //Device ID } - Changing the device type
{ 'instanceOid':'40', //Instance OID 'productOid':'1', //Product OID 'remark':'', //Device description 'deviceId':'D114VKx7a', //Device ID 'deviceName':'iottest1', //Device name 'notifyType':'deviceChange', //Message type 'deviceIdentifier':'iottest1', //Device identifier 'deviceOid':'1', //Device OID 'createdBy':'admin', //Creator 'eventTime':'1588843914884', //Message time 'status':'0', //Device status. 0: enabled; 1: disabled. 'parentDeviceOid':'null' //Parent device OID }
- Adding a device
Last Article: Subscribing to Device Notifications
Next Article: Data Source Management
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.