单设备条件选择下拉菜单
本地
http://127.0.0.1:9999
本地
http://127.0.0.1:9999
GET
http://127.0.0.1:9999
请求参数
Query 参数
device_id
string
设备id
示例值:
5fd9b168-9e2a-d91c-a7c3-9c1f4d4b5137
Header 参数
x-token
string
可选
默认值:
{{x-token}}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET 'http://127.0.0.1:9999/api/v1/device/metrics/condition/menu?device_id=5fd9b168-9e2a-d91c-a7c3-9c1f4d4b5137' \
--header 'x-token: {{x-token}}'
返回响应
🟢200成功
application/json
Body
code
integer
必需
message
string
必需
data
array [object {2}]
必需
data_source_type
string
必需
options
array [object {4}]
必需
示例
{
"code": 200,
"message": "success",
"data": [
{
"data_source_type": "telemetry",
"options": [
{
"key": "humidity",
"label": null,
"data_type": "number",
"unit": null
},
{
"key": "temperature",
"label": "温度",
"data_type": null,
"unit": "℃"
}
]
},
{
"data_source_type": "attributes",
"options": [
{
"key": "version",
"label": null,
"data_type": "string",
"unit": null
},
{
"key": "mac",
"label": null,
"data_type": "string",
"unit": null
},
{
"key": "status",
"label": null,
"data_type": "string",
"unit": null
}
]
},
{
"data_source_type": "event",
"options": [
{
"key": "alert",
"label": "高温告警",
"data_type": "string",
"unit": null
}
]
}
]
}