Request format: GET
URL: http(s)://api.onenet.hk.chinamobile.com/devices/device_id/datastreams/datastream_id
device_id: to be replaced with device ID
datastream_id: to be replaced with data stream ID
Parameter Name | Format | Description |
---|---|---|
errno | int | Call error code, where 0 means success. |
error | string | Error description. “succ” means the call is successful. |
data | json | Device-related information returned after interface is successfully called. See the Data Description Table. |
Parameter Name | Format | Description |
---|---|---|
id | string | Data stream ID |
create_time | string | Data stream creation time |
update_at | string | Upload time of the latest data |
current_value | string/int/json... | The latest data point |
GET http://api.onenet.hk.chinamobile.com/devices/20474930/datastreams/temperature HTTP/1.1
{
"errno": 0,
"data": {
"update_at": "2017-11-20 10:03:10",
"id": "temperature",
"create_time": "2017-11-20 09:59:35",
"current_value": "31303130303030303433"
}
},
"error": "succ"
}