文档
测试

查询报警信息(轮询)

GET
/api/v1/alarm_query

接口描述

地图查询报警信息,5s一次轮询

响应参数

参数名
类型
描述
必填
retcode
Int
返回代码即为返回HTTP头部的状态码 http status 示例:200
必填
status
String
返回信息 示例: 'success'
必填
device_id
string
设备号
必填
alarm_id
string
报警号
必填
begin_time
string
开始时间
必填
end_time
string
结束时间
必填
device_type
int
设备类型
必填
position
int
报警位置
必填
alarm_type
int
报警类型
必填
frequency
int
频率
必填
trusted
float
置信度
必填
longitude
float
经度
必填
latitude
float
纬度
必填
result
int
处理结果
必填
continue_time
int
持续时间
必填

说明 / 示例

```js request data: {} response data: { "retcode": 200, "status": "success", "result": [ { "id": 3, "device_id": "GT-SMT-201721-234567",设备号 "alarm_id": "20191120105655010002",告警号 "begin_time": "2019-11-18T10:56:55",告警开始时间 "end_time": "2019-11-20T10:56:56",告警结束时间 "device_type": 0,设备类型 "position": "设备GT-SMT-201721-234567第2防区,防区代码GT-SMT-201721-2345672",告警位置描述 "alarm_type": 3,告警类型 "continue_time": 1,告警持续时间 "frequency": 1000,告警频率 "trusted": "100.000000",置信度 "longitude": "0.000000000000"经度, "latitude": "0.000000000000",纬度 "result": "1",告警处理结果 "real": "1",是否真实事件 "control": 1,是否受控 "confirm": 1,是否确认 "name": "0",姓名 "phone": "0",电话 "level": 0,等级 "text": "0",未受控描述 "img_link": "0"现场图片 }, { "id": 4, "device_id": "GT-SMT-201621-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-17T10:56:55", "end_time": "2019-11-25T10:56:56", "device_type": 0, "position": "设备GT-SMT-201621-234567第2防区,防区代码GT-SMT-201621-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 1, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 5, "device_id": "GT-SMT-201521-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-20T10:56:55", "end_time": "2019-11-26T10:56:56", "device_type": 0, "position": "设备GT-SMT-201521-234567第2防区,防区代码GT-SMT-201521-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "2", "real": "1", "control": 0, "confirm": 1, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 6, "device_id": "GT-SMT-201421-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-20T10:56:55", "end_time": "2019-11-27T10:56:56", "device_type": 0, "position": "设备GT-SMT-201421-234567第2防区,防区代码GT-SMT-201421-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 0, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 7, "device_id": "GT-SMT-201321-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-20T10:56:55", "end_time": "2019-11-28T10:56:56", "device_type": 0, "position": "设备GT-SMT-201321-234567第2防区,防区代码GT-SMT-201321-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 0, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 8, "device_id": "GT-SMT-201221-234569", "alarm_id": "20191120105655010002", "begin_time": "2019-11-14T10:56:55", "end_time": "2019-11-20T10:56:56", "device_type": 0, "position": "设备GT-SMT-201221-234567第2防区,防区代码GT-SMT-201221-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 0, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 9, "device_id": "GT-SMT-201121-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-15T10:56:55", "end_time": "2019-11-20T10:56:56", "device_type": 0, "position": "设备GT-SMT-201121-234567第2防区,防区代码GT-SMT-201121-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 0, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 10, "device_id": "GT-SMT-200121-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-15T10:56:55", "end_time": "2019-11-20T10:56:56", "device_type": 0, "position": "设备GT-SMT-200121-234567第2防区,防区代码GT-SMT-200121-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 0, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" }, { "id": 11, "device_id": "GT-SMT-200121-234567", "alarm_id": "20191120105655010002", "begin_time": "2019-11-20T10:56:55", "end_time": "2019-11-20T10:56:56", "device_type": 0, "position": "设备GT-SMT-200121-234567第2防区,防区代码GT-SMT-200121-2345672", "alarm_type": 3, "continue_time": 1, "frequency": 1000, "trusted": "100.000000", "longitude": "0.000000000000", "latitude": "0.000000000000", "result": "0", "real": "1", "control": 0, "confirm": 0, "name": "0", "phone": "0", "level": 0, "text": "0", "img_link": "0" } ] } ```