{
  "service": "iot-dispatcher",
  "description": "Cloudflare Worker for Controlling & Querying JD Smart IoT Devices",
  "endpoints": {
    "GET /devices": "List locally registered device shortcuts",
    "GET /remote-devices": "Fetch all live account devices directly from JD Smart API",
    "GET /status": "Query real-time status (power state, set temp, env temp) for all devices",
    "GET /:device/status": "Query real-time single device snapshot (is_on, power, mark, scrdispaly, temp)",
    "GET /:device/is-on": "Query concise power status boolean (is_on: true/false, power_state: ON/OFF)",
    "POST /:device": "Default sleep scene: Query status -> Power ON if off -> Set silent wind (mark: 5) -> Turn off display (scrdispaly: 0)",
    "POST /:device/sleep": "Default sleep scene: Query status -> Power ON if off -> Set silent wind (mark: 5) -> Turn off display (scrdispaly: 0)",
    "POST /:device/power": "Toggle/Switch power state (Unified power control)",
    "POST /:device/silent": "Set AC to silent wind mode (mark: 5) & turn off display (scrdispaly: 0)",
    "POST /:device/display": "Control AC screen light (scrdispaly: 0/1) with smart status check"
  }
}