Query Tags¶
Upstream
- Request TOPIC:
/sys/{productKey}/{deviceKey}/thing/tag/query
- Reply TOPIC:
/sys/{productKey}/{deviceKey}/thing/tag/query_reply
Sample Request Format¶
{
"id": "123",
"version": "1.0",
"params": {
"tags": ["tag1", "tag2"]
},
"method": "thing.tag.query"
}
Sample Response Format¶
{
"id": "123",
"code": 200,
"data": {
"tag1": "value1",
"tag2": "value2"
}
}
Request Parameter Description¶
Parameter | Type | Description |
---|---|---|
id | String | The message ID. It is a reserved parameter that is reserved for future use. |
version | String | The version of the protocol. The current version is 1.0. |
params | Object | The parameters used for querying tags. |
tags | Array | The list of unique tag IDs. When not specified, the request will query all tags. |
method | String | The method of the request. |
Response Parameter Description¶
Parameter | Type | Description |
---|---|---|
code | Integer | The return code. “200” indicates that the requested operation is executed successfully. |
data | JSON | The information of the queried tags. |