跳转到内容

结束直播

Request

停止云手机上的直播。

  • 前置条件:云手机必须已开机且未被其他成员占用,且机型必须支持直播。不校验当前是否真的在直播——无论如何都会下发停止命令。
  • 完成信号:已受理,未完成。请轮询 /cloudphone/live/status 直到 liveStatus 为 0。
  • 重试:效果幂等;重复调用只是再发一次停止命令。

已记录的业务错误码:33300, 33301, 33401。 各错误码的含义见 Error Codes。任何接口还可能返回通用错误码。

Bodyapplication/jsonrequired
phoneIdstringrequired

Cloud phone ID

Example:"190000000000000001"
curl -i -X POST \
  http://127.0.0.1:40000/api/cloudphone/live/end \
  -H 'Content-Type: application/json' \
  -d '{
    "phoneId": "190000000000000001"
  }'

Responses

Request processed; inspect code for the business result

Bodyapplication/json
codeintegerrequired

Business result code; 0 indicates success

Example:0
msgstring or nullrequired

Error message; null when successful

Example:null
requestIdstringrequired

Request ID for troubleshooting

Example:"1d4f3ea968664593860b94b35d4ebf5e"
databooleanrequired

Whether the live-streaming operation succeeded

Response
{ "code": 0, "msg": null, "data": true, "requestId": "1d4f3ea968664593860b94b35d4ebf5e" }