【REST API】操作屏幕类[Inputs]-转移事件

描述:

操作设备进行方向滑动操作。

对应JS API:


var device = Device.getMain();
device.shift();

是否支持多设备:

支持

请求方式:

POST
http://IP:8090/TotalControl/v1/devices/:device/screen/inputs

参数:

参数名 类型 必选 描述
token string Y Total Control TOKEN
:device string Y 主控设备对象值 id
direction string Y 方向的常量值
-up
-down
-left
-right

请求示例:


示例一:
http://127.0.0.1:8090/TotalControl/v1/devices/device@1116106541/screen/inputs?token=270eq7lXQK8bXYsJ&direction=up

示例二:
http://127.0.0.1:8090/TotalControl/v1/devices/device@1116106541/screen/inputs
{
"token":"270eq7lXQK8bXYsJ",
"direction":"up"
}

返回示例:


{
    "status":true
}

返回字段说明:

字段 类型 描述
status boolean true:成功; false:失败

猜你喜欢

转载自blog.csdn.net/lemon5814/article/details/83149932