Multiprotocol Access Product Introduction QuickStart User Guide Development Guide
EDP TCP transparent transmission MQTT Modbus HTTP
FAQ

Update trigger

Request format: PUT

URL: http://api.onenet.hk.chinamobile.com/triggers/trigger_id

trigger_id: to be replaced with the trigger ID

http body parameter

Name Format Required or not Description
title string No Trigger name
ds_id string Yes Data stream name
dev_ids array- string No Device ID, indicating all devices by default
url string No Alarm notification address
type string No Trigger conditions. See the type description list.
threshold No Trigger condition threshold, used in conjunction with type, see the type description list.
type description list
type Description
> The threshold must be a number.
\< The threshold must be a number.
>= The threshold must be a number.
\<= The threshold must be a number.
inout If the threshold is set to {“lolmt”:40, “uplmt”:52}, it means that data will be triggered when sent to or from the closed interval [40, 52].
change The threshold parameter is not transmitted. In case of change in the uploaded value, an alarm will be triggered.
frozen The threshold is a numerical value, specifying the time (in seconds) of triggering an alarm in case of no data and enabling the frozen status of the monitored object.
live The threshold is a numeric value, specifying the time required to trigger an alarm after data reporting.

Return parameter

Name Format Description
errno int Call error code, where 0 means success.
error string Error description. “succ” means the call is successful.

Example of request header

PUT http://api.onenet.hk.chinamobile.com/triggers/145709 HTTP/1.1
api-key: YHC**************VqKA=
Host: api.onenet.hk.chinamobile.com

Request parameter example

{
    "title": "trigger",
    "ds_id": "gps",
    "url": "http://aoic.choqf.com",
    "type": ">",
    "threshold": 100
}

Return example

{
    "errno":0,
    "error":"succ"
}

个搜索结果,搜索内容 “

    0 个搜索结果,搜索内容 “