Skip to content

Live Streaming

Start, inspect, and stop Cloud Phone live streaming.

Start Live Streaming

Request

Start live streaming an uploaded MP4 on a Cloud Phone.

  • Preconditions: the phone must be powered on and not held by another member, and the device must support live streaming. The fileId must refer to a file uploaded as live-stream media that finished uploading; anything else is rejected as invalid or expired.
  • Completion: accepted, not complete. The response only confirms the service took the request. Poll /cloudphone/live/status until liveStatus is 1.
  • Note: the MP4-only restriction is enforced when you upload the file, not here.
  • Retry: no deduplication; a repeat call re-issues the start command.

Documented business errors: 33300, 33301, 33401, 33418. See Error Codes for what each code means. Any operation can additionally return the common codes.

Bodyapplication/jsonrequired
phoneIdstringrequired

Cloud phone ID

Example:"190000000000000001"
fileIdstringrequired

ID of an uploaded MP4 live-streaming file (uploadType=2)

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

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" }