Get started
  • English
  • 简体中文
Official Site
Get started
  • English
  • 简体中文
Official Site
  • Get started
  • Concepts
  • Guides
  • Device capabilities & events
    • Browse by device type
    • Device capabilities
    • Events overview
    • Permission codes
    • Capability error codes
    • Alarm and capability messages
      • device.message.list (Receive alarm messages)
      • device.message.list (Query alarm history)
      • device.message.search (Search messages by type)
      • device.message.detail (Query one alarm message)
      • device.message.delete (Delete alarm messages)
      • Event types
    • Capability FAQ
    • Legacy ability and push types
  • API reference
  • SDK and tools
  • Solutions
  • Platform and support
On this page
What it does
Request URL
Minimum permission
Request parameters
Request example
Response data fields
Response example
Error codes

device.message.list (Query alarm history)

device.message.list: Query alarm history

What it does

Query capability event history by device and time. Response shape: data.count, data.nextAlarmId, data.messages. Each messages[] entry matches the push payload in Receive alarm messages, plus feedback (history only). msgType equals eventId.

Real-time legacy alarm / deviceStatus callbacks use string msgType and did/cid—see Receive device messages and Event message types, not this API.

beginTime / endTime are device-local yyyyMMdd'T'HHmmss (quotes mean literal T), e.g. 20201022T000000. Do not use Unix seconds or UTC from time-sync APIs. No eventIds or client count; batch size is platform-defined.

Platform fields (token, thumbUrl, picUrlArray, labelType, Smart View fields) are not inside capability outputData.

Request URL

POST https://openapi-[DataCenter].easy4ip.com/openapi/v2/device.message.list

Minimum permission

Administrator on bound devices: no extra permission. Shared devices: alarm message permission. Sub-user bound devices: none. Sub-account: per-message share/sub codes from the event’s capability row (see Permission codes)—not Alarm alone (system events often need Config). Only authorized events returned; not whole-call DV2011. Device must be bound.

Request parameters

NameTypeRequiredDefaultValid valuesDescription
tokenStringyesAdministrator, sub-user, or sub-account accessToken
deviceIdStringyesDevice serial number
productIdStringnoOptional. If sent and it does not match the device model → DV2009
channelIdStringnoChannel id; IPC often "0". Do not pass -1Omit: device-level only; set: that channel only
beginTimeStringyesDevice-local yyyyMMddTHHmmssStart time, e.g. 20201022T000000
endTimeStringyesDevice-local yyyyMMddTHHmmssEnd time, e.g. 20201022T235959
nextAlarmIdStringnoOptional on first page"-1" or previous batch valueFirst page: "-1" or omit; then previous nextAlarmId

Request example

{
 "id": "d5c287b4-5b2f-4f03-baf5-8032c5c354af",
 "system": {
 "ver": "1.0",
 "appId": "lcdxxxxxxxxx",
 "sign": "xjhCQBoJ9hRDsCjyDcHjtDNzRZ3ZJezcawsfWeiaoxU=",
 "time": 1706511734,
 "nonce": "f5a1ae2d-c09c-4d39-a744-83a5c2c653c2"
 },
 "params": {
 "token": "<yourAccessToken>",
 "deviceId": "TESTIPC000012345",
 "channelId": "0",
 "beginTime": "20201022T000000",
 "endTime": "20201022T235959",
 "nextAlarmId": "-1"
 }
}

Response data fields

NameTypeDescription
countIntBatch count
nextAlarmIdStringNext batch cursor; omitted when no more
messagesArrayBatch of push payloads; fields match Receive alarm messages plus table below

Each messages[] entry is a push payload; only this API adds feedback

NameTypeDescription
msgTypeStringEquals eventId, e.g. detection.motion.detected
deviceIdStringDevice serial number
productIdStringModel
channelIdStringChannel events; omitted on device-level
outputDataObjectEvent fields; {} when none
timeIntReport time, Unix seconds
localTimeStringDevice-local yyyyMMddTHHmmss
alarmIdStringAlarm id for detail/delete/paging
tokenStringWhen linked cloud recording exists
thumbUrlStringThumbnail; when image exists
picUrlArrayArrayAlarm images; expire—copy promptly
labelTypeStringMessage type label
aiCopyWritingStringSmart View when plan is active
securityRiskLevelIntSmart View; matches push (1–10); Mix may normalize to level text
aiTagArraySmart View; matches g04 push; Mix may normalize to single tag string
feedbackObjectHistory only. type: String (1 person, 2 face, 3 LLM); result: Array<String> (e.g. ["1"] accurate / ["0"] inaccurate)

Property reports (push channel, fixed msgType device.property.report) use properties keys as propertyId.

Response example

{
 "id": "d5c287b4-5b2f-4f03-baf5-8032c5c354af",
 "result": {
 "code": "0",
 "msg": "Operation is successful",
 "data": {
 "count": 1,
 "nextAlarmId": "116257862023505xxxx",
 "messages": [
 {
 "msgType": "detection.motion.detected",
 "deviceId": "TESTIPC000012345",
 "productId": "56WGTET2",
 "channelId": "0",
 "outputData": {
 "extendContext": {
 "handleBit": 1
 }
 },
 "time": 1673406989,
 "localTime": "20230111T111629",
 "alarmId": "116257862023505xxxx",
 "token": "f2dc8c09eeae4b5bad6abf522c93d825",
 "thumbUrl": "https://example.imou.com/pic/thumb.jpg",
 "picUrlArray": ["https://example.imou.com/pic/alarm1.jpg"],
 "labelType": "humanAlarm",
 "feedback": {
 "type": "1",
 "result": ["1"]
 }
 }
 ]
 }
 }
}

Error codes

This API may return the codes below.

Unauthorized events are filtered per row; the whole call does not fail for that.

include 未找到:06.dv20-message.md

device.message.list (Receive alarm messages)
device.message.search (Search messages by type)