コンテンツへスキップ

Live Streaming

Cloud Phone のライブ配信を開始、確認、終了します。

ライブ配信を開始

Request

アップロード済みの MP4 をクラウドフォンでライブ配信します。

  • 前提条件:クラウドフォンが起動済みで、他のメンバーに占有されておらず、そのデバイスサービスがライブ配信に対応していること。fileId はライブ配信メディアとしてアップロードが完了したファイルを指す必要があり、それ以外は無効または期限切れとして拒否されます。
  • 完了シグナル受理されただけで、完了ではありません。 レスポンスはデバイスサービスがリクエストを受け取ったことのみを示します。/cloudphone/live/status をポーリングし、liveStatus1 になるまで待ちます。
  • 補足:MP4 のみという制限は、ここではなくファイルのアップロード時に適用されます。
  • リトライ:重複排除はありません。再呼び出しは開始コマンドを再発行します。

文書化されたビジネスエラー: 33300, 33301, 33401, 33418。 各コードの意味は Error Codes を参照してください。どの操作でも共通コードが返る場合があります。

Security
Authorization
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 \
  https://api.morelogin.com/cloudphone/live/start \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -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" }