IotHub
  1. push&Webhook
IotHub
  • README
  • token
    • createToken
      POST
    • destroyToken
      POST
  • customer
    • customerPage
      POST
    • customerTree
      POST
  • device
    • command
      • commandSend
      • commandInfoList
      • cutOilElectric
      • getConfig
    • devicePage
      POST
    • deviceTypes
      POST
    • deviceTypeInfo
      POST
    • deviceDataByDeviceIds
      POST
    • deviceDataByCustomerId
      POST
    • deviceTripInfoByTripId
      POST
    • deviceTripsByDeviceId
      POST
    • deviceTraffic
      POST
    • deviceSensorData
      POST
    • expandInfoByDeviceId
      POST
    • saveDeviceChannelName
      POST
  • fence
    • fencePage
      POST
    • fenceInfo
      POST
    • addFence
      POST
    • saveFence
      POST
    • delFence
      POST
    • fenceDevices
      POST
    • fenceDeviceUpdate
      POST
    • fenceDeviceDel
      POST
    • fenceDeviceAdd
      POST
  • push&Webhook
    • README
  • video
    • H5 page
    • H5 Page-V2
    • history
      • README
      • playBackList
      • historicalUpload
      • playBack
      • replaySet
      • taskPage
      • taskStop
      • taskDelete
    • live
      • liveVideo
      • liveVideoControl
    • getNodes
  • alarm
    • Alert Types
    • alarmTypeList
    • alarmFilePage
    • alarmFileByAlarmId
    • alarmHistoryPage
    • alarmPageByUser
  • audio
    • README
    • talk「Deprecated」
    • talkPlus
  • gallery
    • filePageV2
    • filePage
    • deleteFile
    • capture
    • capturePage
    • captureRecord
  • fleet
    • faceRecordPage
    • rfidPage
  • gps
    • historyData
  • Protocol Analysis
    POST
  1. push&Webhook

README

1.
Using a webhook, push notifications will be made when data is reported on the device.
2.
Select the service that needs to be activated for push, fill in the URL address
image.png
3.
When the device reports data, it will integrate the reported data into a parameter called "data".
4.
Different push situations result in different data objects contained in "data"

AlarmData#

FieldTypeRequiredNote
actualbooleantrueReal time or supplementary transmission
deviceIdstringtrueDevice ID
reportCtnumbertrueDevice Data reporting time (Device Time Zone)
deviceCtnumbertrueGateway Data reporting time (UTC +0)
alarmTypestringtrueAlarm types ‘,’ multiple separated by commas
alarmIdstringtrueUnique alarmId,matches the “alarmFilePage” alarmId field “alarmHistoryPage” id field
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
latnumbertrue
lonnumbertrue
speednumberfalsekm/h
alarmAttributestringfalseStorage anomaly alarm, with storage ID. Camera loss alarm, with camera serial number. Fence entry and exit alarm, with fence name

"data":"{
\"actual\":true,
\"deviceId\":\"105045133913\",
\"reportCt\":1735296575,
\"deviceCt\":1735296575,
\"alarmType\":\"laneShift\",
\"id\":\"105045133913_1843895343409950720",
\"alarmId\":\"1843895343409950720\",
\"lat\":24.067906,
\"lon\":76.96842
}"
You can query the alarm file corresponding to the alarm ID through 'alarm/alarmFileByAlarmId'.

GPS Data#

FieldTypeRequiredNote
actualbooleantrueReal time or supplementary transmission
deviceIdstringtrueDevice ID
reportCtnumbertrueDevice Data reporting time (Device Time Zone)
deviceCtnumbertrueGateway Data reporting time (UTC +0)
numintegertruenumber of satellites
lonnumberfalse
latnumberfalse
speednumberfalse
courseintegerfalseindicates the direction of travel
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
"data":"{
\"actual\":true,
\"num\":9,
\"lon\":113.938709,
\"deviceId\":\"105045133913\",
\"speed\":0,
\"reportCt\":1724822445,
\"course\":154,
\"deviceCt\":1724793630,
\"id\":\"105045133913_1234567893043003392\",
\"lat\":22.577894
}"

DeviceInfo Data#

FieldTypeRequiredNote
actualbooleantrueReal time or supplementary transmission
deviceIdstringtrueDevice ID
reportCtnumbertrueDevice Data reporting time (Device Time Zone)
deviceCtnumbertrueGateway Data reporting time (UTC +0)
accintegerfalseAcc status 0 off/1 on
blockedStatusintegerfalseOil and electricity status 0 off/1 on
odometernumberfalseMileage Statistics
elecintegerfalsePower on status 0 off/1 on
ioStatusintegerfalseI/O status
signalintegerfalseGSM signal strength
voltagenumberfalsevoltage V,External voltage, only valid for wired devices
quantitynumberfalsePercentage of battery
accUpdateTimenumberfalseLast ACC status change time (Device Time Zone)
localizationFailurebooleanfalseThe device is not positioned, and if it is true, it means it is not located
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
"data":"{
\"acc\":1,
\"actual\":true, 
\"blockedStatus\":1,
\"odometer\":7.3,
\"elec\":0,
\"deviceId\":\"105045133913\",
\"reportCt\":1724837171,
\"ioStatus\":0,
\"deviceCt\":1724808355,
\"id\":\"105045133913_1234567895482220544\",
\"signal": 27
}"

PassThrough Data#

FieldTypeRequiredNote
messagestringtrueJSON string containing com1 and com2
deviceIdstringtrueDevice ID
reportCtnumbertrueDevice Data reporting time (Device Time Zone)
deviceCtnumbertrueGateway Data reporting time (UTC +0)
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
"data": "{
\"message\": \"{
\"com1\":\"f5fffff5d7dff5f5fff5fdd5ffdffddfd5dffdff7ddddfd5ffdfd5ffdfffd5fdf7dfddd5fdf5f5ffddd5f7\",
\"com2\":\"fffddffffff5ff55f5fffd5dfff5dffff555dddfd7ffffd5ffdffdffd7dfffd5dffffffdffdfff7dddffdfd7ddddfff7dfdddfdffff5f7fdf5ffdddfddffd5d7ffdffdffdfddfdfff5fd5dfff7f5dffd\"
}\",
\"deviceId\": \"105045133913\",
\"reportCt\": 1736756976,
\"deviceCt\":1736756976,
\"id\":\"105045133913_1878721045339443200\"
}"

AlarmFile Data#

FieldTypeRequiredNote
idstringtrueUnique alarmId,match with alarmId from alarm data
deviceIdstringtrueDevice ID
fileUrlstringtrueurl
fileTypestringtruePicture 00 Audio 01 Audio and video 02 Text 03 Others 04
"data": "{
\"id\":\"1924683352005763072\",
\"deviceId\":\"105045133913\",
\"fileUrl\":\"https://files.imettax.com/mettaxftp/202505%2Fsit_video_alarm_2025051303_17471079303273973080227010339153_00_00_122549.jpg\",
\"fileType\":\"00\"
}"

Device SensorData#

FieldTypeRequiredNote
idstringtrueunique alarmId
deviceIdstringtrueDevice ID
reportCtLongtrueDevice Data reporting time (Device Time Zone)
deviceCtLongtrueGateway Data reporting time (UTC +0)
adcstringtrueadc simulated data
"data": "{
\"id\":\"1924683352005763072\",
\"deviceId\":\"105045133913\",
\"reportCt\":1736756976,
\"deviceCt\":1736756976,
\"adc\":\"00\"
}"

CaptureFile Data#

When the capture API is called, captureId will be returned. When the capture file is uploaded, the webhook will push this message to push the captured image information.
FieldTypeRequiredNote
captureIdstringtrueunique alarmId
deviceIdstringtrueDevice ID
channelIdnumbertrueDevice channel id
fileUrlstringtrueCapture file address
"data": "{"captureId":"1009759838","deviceId":"240070466666","channelId":1,"fileUrl":"https://xxx.com/**/video_capture_2025101707_1791444020-240070466666_1.jpg"}"

Face Check#

It is important to note that the first and second messages are in no particular order, and the second message may be
faster than the first message, and you need to match it according to the id.
When the message type is 1, the data format pushed by the web hook is as follows:
FieldTypeRequiredNote
deviceIdstringtrueDevice ID
reportCtnumbertrueDevice Data reporting time (Device Time Zone)
deviceCtnumbertrueGateway Data reporting time (UTC +0)
licensePlatestringfalseLicense plate number
faceIdstringfalsethe driver s face id
driverNamestringfalseDriver name
latnumbertrueLatitude
lonnumbertrueLongitude
compaResultintegertrue0: Matching successful; 1: Matching failed; 2: Timeout; 3: The function is not enabled;4: Abnormal connection; 5: No driver picture 6: The terminal face library is empty
similaritynumbertruePercentage; Range: 0.00% - 100.00% in units is 0.01%
messageTypeStringtrueMessage type 1For face comparison result messages, 2 is driver picture messages
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
"data": "{
  "id": "333777444585_198669678696111100",
  "deviceId": "333777444585",
  "faceId": "15",
  "lat": "35.926264",
  "lon": "113.882785",
  "compaResult": "0",
  "similarity": 7577,
  "reportCt": 1762529189,
  "deviceCt": 1762500399,
  "licensePlate": "333777444585",
  "driverName": "zoeya11",
  "messageType": "1"
}"
When the message type is 2, the data format pushed by the web hook is as follows:
FieldTypeRequiredNote
deviceIdstringtrueDevice ID
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
imageUrlstringfalseDriver image URL
statusintegertrue0: Failure 1: Success;
messageTypeStringtrueMessage type 1For face comparison result messages, 2 is driver picture messages
"data":"{
  "id": "333777444585_198669678696111100",
  "deviceId": "333777444585",
  "imageUrl": "https://example.com/driver_image.jpg",
  "status": "1",
  "messageType": "2"
}"

Push RFID#

When the device has an RFID reader and reads the RFID card, the web hook will push the following data:
FieldTypeRequiredNote
deviceIdstringtrueDevice ID
reportCtnumbertrueDevice Data reporting time (Device Time Zone)
deviceCtnumbertrueGateway Data reporting time (UTC +0)
licensePlatestringfalseLicense plate number
rfidNostringfalsethe driver s rfidNo id
driverNamestringfalseDriver name
latnumbertrueLatitude
lonnumbertrueLongitude
statusintegertrueStatus 1: enter 2: exit
idstringtrueUnique ID, if it matches the ID in GPS, it indicates that the information attached to this GPS package
"data":"{
"id": "333845765947_1988448015257571328",
"deviceId": "333845765947",
"lat": "32.353134",
"lon": "121.357231",
"rfidNo": "7C3F88A9",
"status": 1,
"deviceCt": 1762917925,
"reportCt": 1762917925,
"licensePlate": "845765947",
"driverName": "zoeya11"
}"
5.
Sample code for receiving URL implementation
Java
NodeJS
Modified at 2025-11-27 02:13:09
Previous
fenceDeviceAdd
Next
H5 page
Built with