You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 KiB

人群

公共分类

增加修改告警规则

基本信息

Path /api/warning_rule/

Method POST

接口描述:

请求参数

Headers

参数名称 参数值 是否必须 示例 备注
Content-Type application/x-www-form-urlencoded
Body
参数名称 参数类型 是否必须 示例 备注
warning_name text 告警规则名称
warning_type text 告警类型
is_use text 是否启用
person_number text 人数
appear_number text 出现次数
time_interval text 时间间隔(小时)
time_period text 时间段(小时)
trigger_start_time text 敏感起始时间
trigger_end_time text 敏感结束时间
id text 规则id修改时传递

返回数据

名称类型是否必须默认值备注其他信息
idnumber非必须
warning_namestring非必须
warning_levelnumber非必须
warning_typenumber非必须
is_usenumber非必须
person_numbernumber非必须
appear_numbernumber非必须
time_intervalnull非必须
time_periodnull非必须
trigger_start_timestring非必须
trigger_end_timestring非必须
create_timestring非必须
update_timestring非必须

增加修改设备

基本信息

Path /api/device/

Method POST

接口描述:

请求参数

Headers

参数名称 参数值 是否必须 示例 备注
Content-Type application/x-www-form-urlencoded
Body
参数名称 参数类型 是否必须 示例 备注
device_name text 设备名
device_code text 设备代码
device_api text 设备接口地址
is_use text 是否开启
note text 备注
device_status text 设备状态
id text 设备id(修改时传递)

返回数据

名称类型是否必须默认值备注其他信息
idnumber非必须
device_namestring非必须
device_codenull非必须
device_apistring非必须
is_usenumber非必须
device_statusnumber非必须
notenull非必须
create_timestring非必须
update_timestring非必须

新增检测结果

基本信息

Path /api/detect_result/

Method POST

接口描述:

请求参数

Headers

参数名称 参数值 是否必须 示例 备注
Content-Type application/x-www-form-urlencoded
Body
参数名称 参数类型 是否必须 示例 备注
person_id text 人员id
device_id text 设备id
device_name text 设备名称
appear_time text 出现时间
picture_path text 检测结果图片地址

返回数据

名称类型是否必须默认值备注其他信息
idnumber非必须
person_idstring非必须
device_idnumber非必须
device_namestring非必须
appear_timestring非必须
picture_pathstring非必须
is_ignorenumber非必须
create_timestring非必须
update_timestring非必须

查询修改告警规则

基本信息

Path /api/warning_rule/

Method GET

接口描述:

请求参数

Query

参数名称 是否必须 示例 备注
id 规则id单查时传递

返回数据

名称类型是否必须默认值备注其他信息
countnumber非必须
nextnull非必须
previousnull非必须
resultsobject []非必须

item 类型: object

├─ idnumber必须
├─ warning_namestring必须
├─ warning_levelnumber必须
├─ warning_typenumber必须
├─ is_usenumber必须
├─ person_numbernumber必须
├─ appear_numbernumber必须
├─ time_intervalnull,number必须
├─ time_periodnull,number必须
├─ trigger_start_timestring,null必须
├─ trigger_end_timestring,null必须
├─ create_timestring必须
├─ update_timestring必须

查询告警信息

基本信息

Path /api/warning_info/

Method GET

接口描述:

请求参数

Query

参数名称 是否必须 示例 备注
warning_type 告警规则类型

返回数据

名称类型是否必须默认值备注其他信息
countnumber非必须
resultobject []非必须

item 类型: object

├─ warning_namestring必须
├─ picture_pathstring必须
├─ device_namestring必须
├─ person_idstring必须

查询设备

基本信息

Path /api/device/

Method GET

接口描述:

请求参数

Query

参数名称 是否必须 示例 备注
id id=1 查询单个设备详情
page
page_size

返回数据

名称类型是否必须默认值备注其他信息
countnumber非必须
nextnull非必须
previousnull非必须
resultsobject []非必须

item 类型: object

├─ idnumber非必须
├─ device_namestring非必须
├─ device_codenull非必须
├─ device_apistring非必须
├─ is_usenumber非必须
├─ device_statusnumber非必须
├─ notenull非必须
├─ create_timestring非必须
├─ update_timestring非必须

登录

基本信息

Path /api/login/

Method POST

接口描述:

请求参数

Headers

参数名称 参数值 是否必须 示例 备注
Content-Type application/x-www-form-urlencoded
Body
参数名称 参数类型 是否必须 示例 备注
username text
password text

返回数据

名称类型是否必须默认值备注其他信息