设备命令下发 websocket测试 POST devices/command 接口描述 用来发布设备命令 请求参数 application/json 参数名 类型 描述 必填 参数要求 jsonrpc str JSON-RPC协议版本,必须写为“2.0” 必填 2.0 method str 请求方法,设为"command-distribute" 必填 params dict 参数字典 必填 device_sn str 要操作的设备的sn 必填 command dict 命令,参见接收操作指令节的params 必填 id str 客户端标识id 必填 响应参数 application/json 参数名 类型 描述 必填 参数要求 jsonrpc str JSON-RPC协议版本,必须写为“2.0” 必填 2.0 result dict 成功时返回的字典 可选 code int 状态码 必填 200 error dict 失败时返回的字典 可选 code int 状态码 必填 message str 错误的简短描述 必填 data Any 错误附加信息 可选 id str 与请求时对应的客户端标识id 必填 与请求的客户端id一致