Start a cloud recording
Overview
With ZEGOCLOUD's Cloud Recording, you can start cloud recording by sending a Server API request without integrating an SDK. When you are using ZEGOCLOUD's RTC service to publish and play streams, you can call server-side APIs to easily start cloud recording and uolad record files to specified third-party storage for scenarios like playback and Video-on-Demand (VOD).
This document describes how to start cloud recording, query cloud recording status, stop cloud recording, and more by sending a simple Server API request.
Basic process
The following diagram shows the complete process of implementing a cloud recording:

Prerequisites
Enable cloud recording
Contact ZEGOCLOUD Technical Support to enable the cloud recording service.
Integrate video/voice SDK
Integrated either the ZEGOCLOUD Video Call or Voice Call SDK in your project.
Enable Third-Party Cloud Storage
Before using the cloud recording service, you need to enable a third-party cloud storage service and obtain the corresponding Region, Bucket, Access Key, and Secret Key information (required parameters vary by service, please obtain them according to your needs).
Currently supported third-party cloud storage services:
- Amazon S3
- Alibaba Cloud OSS
- Tencent Cloud COS
- Qiniu Cloud Kodo
- Alibaba Cloud VOD
- Tencent Cloud VOD
- Huawei Cloud OBS
- Google Cloud Storage
- China Mobile Cloud EOS
- Storage providers using S3 protocol (e.g., DigitalOcean)
Implementation Guide
Start cloud recording
To start cloud recording, use the StartRecord
method to get the room ID to join a specific room.
After calling this method successfully, you can get the taskID (UID) from the response body.
- Each recording task has a maximum duration of 24 hours. Recording will automatically stop after 24 hours.
- The recording task will also automatically stop if no audio/video streams or whiteboard activities are detected in the room.
- ZEGOCLOUD recommends that you stop each recording task by calling the StopRecord method to avoid additional charges from continuous recording.
And you will need to use this taskID as a request parameter for the subsequent requests. For details, see Accessing Server APIs.
Query recording status
During recording, call the DescribeRecordStatus
method multiple times. After calling this method successfully, you can get the current recording status and the address to be uploaded from the response body.
Update mixed-stream layout
To update the layout of the mixed streams during video recording, call the UpdateLayout
method multiple times. For more details, see Set mixed-stream layout.
Update the whiteboard
To update the Whiteboard ID during recording, call the UpdateWhiteboard
method multiple times. For more details, see Multi-sector recording (Whiteboard).
Stop cloud recording
To stop the cloud recording, call the StopRecord
method.
Manage recorded files
Upload recorded files
After the cloud recording task is completed, the recording files will be uploaded to the pre-designated third-party cloud storage.
To check the uploading details, call the DescribeRecordStatus
method.
FileUrl
: Returns the URL of the recorded files to be uploaded.Status
: Returns the uploading status of the recorded files.VideoId
: Vod returns theVideoId
of the recorded files.
After uploading the recording files, the cloud recording sends a callback to the callback URL that is specified when activating the service.
Manage recorded file names
The recording file name contains information such as StreamId, timestamp of start recording. For more details, refer to the OutputFileRule
parameter of the StartRecord
method.