Query Monitoring Metrics

Last Updated on : 2023-06-21 07:13:09download

Query the configured product monitoring metrics.

API address

GET: /v1.0/iot-03/si/products/monitor-indicator

Request parameter

Parameter nameTypeINRequiredDescription
tuya_product_idStringqueryfalseThe ID of a Tuya product.
monitor_typeStringqueryfalseThe type of a specified metric.
  • core_monitor: general industrial metric.
  • energy_collect: industrial energy consumption metric.
  • environment: industrial environment metric.
  • other: others.
page_noLongqueryfalseThe page number. Default value: 1, which means the first page.
page_sizeLongqueryfalseThe number of items returned on each page. Default value: 20. Maximum value: 100.

Return parameter

Parameter nameTypeDescription
resultTyPageThe returned result.

Description of result

Parameter nameTypeDescription
page_sizeLongThe number of items returned on each page.
dataListThe data.
totalLongThe total number of items.
page_noLongThe current page number.

Description of data

Parameter nameTypeDescription
indicator_idStringThe ID of a specified metric.
tuya_product_idStringThe ID of a Tuya product.
indicator_codeStringThe code of a specified metric.
monitor_typeStringThe monitoring type.
create_timeLongThe time when it is created.

Request example

GET: /v1.0/iot-03/si/products/monitor-indicator?tuya_product_id=ng****

Return example

    "result": {
        "data": [
                "tuya_product_id": "5i****",
                "create_time": 1635678293063,
                "indicator_code": "switch_led",
                "indicator_id": "14****",
                "monitor_type": "energy_collect"
                "tuya_product_id": "5i****",
                "create_time": 1635678159020,
                "indicator_code": "switch_led",
                "indicator_id": "14****",
                "monitor_type": "core_monitor"
        "page_no": 1,
        "total": 2,
        "page_size": 20
    "t": 1635678589042,
    "success": true

Error code

For more information, see error code.