Get Air Conditioner Status in Bulk

Last Updated on : 2023-06-15 05:17:34

Based on the device ID, get the current status of air conditioners. Up to 100 devices can be queried at a time.

API address

GET: /v1.0/cloud/rc/infrared/ac/status/batch

Request parameter

Parameter nameTypeINRequiredDescription
device_idsStringquerytrueThe list of device IDs, separated with commas (,).

Return parameter

Parameter nameTypeDescription
resultListThe list of device status.
successBooleanIndicates whether the API is called successfully. Valid values:
  • true: The API call succeeded.
  • false: The API call failed.

Description of result

Parameter nameTypeDescription
devIdStringThe device ID.
powerOpenBooleanIndicates whether the specified air conditioner is powered on. Valid values:
  • true: The air conditioner is powered on.
  • false: The air conditioner is powered off.
modeStringThe working mode.
tempStringThe temperature.
fanStringThe wind speed level.
swingStringThe swing status.
wetStringThe humidity.

Request example

GET: /v1.0/cloud/rc/infrared/ac/status/batch?device_ids=dev1,dev2

Return example

{
    "tid": "303ea3d9dce111eda853c62a3bb695e3",
    "result": [
        {
            "devId": "dev1",
            "temp": "18",
            "mode": "0",
            "powerOpen": true,
            "fan": "0",
            "swing": "false"
        },
        {
            "devId": "dev2",
            "temp": "20",
            "mode": "0",
            "powerOpen": true,
            "fan": "0",
            "swing": "false"
        }
    ],
    "t": 1681709526090,
    "success": true
}

Error code

For more information, see error code.