The Agora On-premise Recording SDK records communication and interactive live streaming
contents based on the Agora Native SDK.
This component package is compatible with the following SDKs:
|The Agora Native SDK||The Agora On-premise Recording SDK is compatible with the Agora Native SDK v1.7.0 or later. If, for example, any user in the channel uses the Agora Native SDK v1.6, the whole channel cannot record.|
|The Agora Web SDK||The On-premise Recording SDK is compatible with the Agora Web SDK v1.12.0 or later.|
leaveChannelmethod in the channel to stop recording, the recording file ends with a period of silence determined by the
idleLimitSecfield set for the configuration when calling the
The Agora On-premise Recording SDK supports both Java and C++ from v2.2.0.
v3.0.6 was released on May 18, 2021.
For scenarios requiring high security, to guarantee the confidentiality, integrity, and authenticity of the data and to improve the computational efficiency of the data encryption, this release adds the following options in
"aes-128-gcm": 128-bit AES encryption, GCM mode.
"aes-256-gcm": 256-bit AES encryption, GCM mode.
Once you enable the built-in encryption, all users in the same channel must use the same encryption mode and key.
MP3 format in composite recording mode
You can set the sample rate of the raw audio data in PCM format (
getAudioFrame is 2 or 3) through the
cfgFilePath parameter. See Record a Call for details.
Optimize the sensitivity and accuracy of
You can get a MP4 file after a composite recording or an individual recording without transcoding.
|Earlier than v3.0.6||v3.0.6 or later|
|Generates video files in TS format during the recording. When the recording ends, the SDK automatically converts the TS files to MP4 format.||Generates video files in TS format and MP4 format during the recording.|
Adds enumerators for
AV_CODEC_INDIVIDUAL_TS_ONLY: Generates video files in TS format, and audio files in AAC format in the individual recording mode.
AV_CODEC_INDIVIDUAL_TS_AND_MP4: Generates video files in TS format and MP4 format, and audio files in AAC format in the individual recording mode.
AV_CODEC_MIXED_TS_ONLY: Mixes the audio and video in real time into an TS file in the composite recording mode.
AV_CODEC_MIXED_TS_AND_MP4: Mixes the audio and video in real time into an TS file and an MP4 file in the composite recording mode.
Fix the issue that the transcoding script does not support UIDs with underscores, resulting in parsing errors.
v3.0.5 was released on January 13, 2021.
This release adds
VIDEO_FRAME_TYPE to get video data in JPG file format.
This release fixed the following issues:
leaveChannelmethod to leave a channel.
v3.0.4 was released on November 25, 2020.
cfgFilePath to set time interval between two successive recorded files in individual recording mode of a live interactive streaming channel.
OnActiveSpeakercannot get the corresponding callback.
OnAudioVolumeIndicationcannot get the corresponding callback.
setUserBackgroundcaused the recording service to crash.
v3.0.3 was released on September 17, 2020.
Repair of recording files after crashes
Before v3.0.3, the MP4 files generated after a recording might not be playable due to recording crashes. To solve this issue, as of v3.0.3, the Agora Recording SDK provides the following solutions:
crash_restore.shscript. If the recording service quits abnormally after multiple crashes, you can run the script to convert the TS files to MP4 files and repair the incomplete
v3.0.2 was released on July 15, 2020.
v3.0.1 was released on March 16, 2020.
Recorded files from an individual recording session have an incorrect timestamp in their names.
v3.0.0 was released on February 20, 2020.
Supports adding image watermarks, text watermarks, or a timestamp watermark in composite recording mode.
You can either configure watermark settings in the
setVideoMixingLayout method, or add, update, and remove watermark settings with the
updateWatermarkConfigs method. See Watermark for details.
2. Selective recording
Supports recording the audio or video of specified users.
To enable selective recording when calling
autoSubscribeas false in
RecordingConfigto specify the users to record.
Afterwards, you can call
updateSuscribeAudioUids methods to update the list of uids to record.
3. Last frame
Retains the last video frame from when the user leaves the channel in composite recording mode.
You can set the
keepLastFrame parameter when calling the
setVideoMixingLayout method to enable this feature.
4. Cloud proxy
Supports the cloud proxy service. See Use Cloud Proxy for details.
5. New callbacks
onRejoinChannelSuccess: Occurs when the recording server rejoins a channel.
onConnectionStateChanged: Occurs when the network connection state changes.
onRemoteVideoStats: Reports the statistics of the video stream from each remote user/host.
onRemoteAudioStats: Reports the statistics of the audio stream from each remote user/host.
onRecordingStats: Reports the statistics of the recording session.
onRemoteAudioStreamStateChanged: Occurs when the state of a remote audio stream changes.
onRemoteVideoStreamStateChanged: Occurs when the state of a remote video stream changes.
enableIntraRequestparameter in RecordingConfig. After this setting:
cfgFilePath, you do not have to set
Recording_Dirin the configuration file.
alphaparameter in the method call of
setVideoMixingLayoutcauses the recording service to crash.
onRemoteVideoStreamStateChangedcallbacks is inaccurate under poor network conditions.
v2.3.4 was released on August 5, 2019.
setUserBackgroundmethod which sets the background image of a specified user. When the user is online but does not send any video stream, the background image is displayed.
setLogLevelmethod which sets the logging level. The SDK generates logs in the selected level and in the levels preceding the selected level.
leaveChannelmethod to leave a channel.
v2.3.3 was released on April 1, 2019.
v2.3.3 adds the following callbacks to inform the app of the connection status between the recording SDK and Agora's edge server:
onConnectionLost: Informs that the SDK loses connection to the server.
onConnectionInterrupted: Informs that the connection between the SDK and the server is interrupted.
v2.3.3 adds the following callbacks to inform the app of receiving the first remote audio or video frame:
onFirstRemoteAudioFrame: Informs that the first remote audio frame is received.
onFirstRemoteVideoDecoded: Informs that the first remote video frame is decoded.
v2.3.3 adds the
onReceivingStreamStatusChanged callback to get status changes of the receiving audio or video stream.
v2.3.3 adds the
onAudioVolumeIndication callback to get the list of users who are speaking and their volumes.
-f . -m 3.
v2.3.0 was released on January 14, 2019.
The calculation of the usage of the On-premise Recording SDK v2.3.0 or later is separated from that of the Agora Voice Call/Interactive Audio Streaming SDK and the Agora Video Call/Interactive Video Streaming SDK. Contact email@example.com for details.
v2.3.0 supports high audio quality (a sample rate of 48 kHz, stereo, and a bitrate of up to 192 Kbps) in Composite Recording Mode.
Stereo is not applicable to raw data.
audio profile can be set as
audio profile=0: A sample rate of 48 kHz, the same number of audio channels as the original audio, and an adaptive bitrate.
audio profile=0: A sample rate of 48 kHz, mono, and a bitrate of 48 Kbps
audio profile=1: A sample rate of 48 kHz, mono, and a bitrate of 128 Kbps
audio profile=2: A sample rate of 48 kHz, stereo, and a bitrate of 192 Kbps
Video files transcoded in real time or transcoded by the transcoding script can be played by web browsers on Android, iOS/macOS, and Windows. The following is a list of compatible web browsers on each platform.
|macOS 10+||Chrome 47+||Safari 11+|
v2.3.0 adds the function for users to add a background image while recording audio in Composite Recording Mode. A custom image is used for any user who does not have video while recording video in Composite Recording Mode.
This function is not applicable to raw data and screenshots.
v2.3.0 provides two pre-defined layout templates for composite recording to make the On-premise Recording SDK sample code easier to use.
bestFit as the default layout supporting up to 17 video streams.
This layout automatically scales according to the number of video streams. The number of columns and rows varies depending on the number of video streams. For example:
v2.3.0 adds the function to display a specified user's video in a large window on the left of the screen, while displaying the other users' videos in small windows arranged vertically on the right. At most, two columns with eight video windows in each column are supported.
v2.3.0 adds the function to capture the screen of every user while recording video in Composite Recording Mode. Recording and screen capturing use the same video stream.
v2.3.0 adds the
onActiveSpeaker callback to return the UID of the active speaker in the channel.
This function is disabled by default and can be enabled by setting the
audioIndicationInterval parameter in
RecordingConfig. The On-premise Recording SDK returns the
onActiveSpeaker callback at set intervals.
startServicemethod is called.
v2.2.3 was released on October 18, 2018.
v2.2.2 was released on August 1, 2018.
v2.2.1 was released on June 5, 2018.
Port conflicts when the search for the port takes too long and exceeds the idle time. As a result, the port is not connected.
v2.2.0 was released on May 4, 2018.
Support for both Java and C++.
v2.1.0 was released on March 7, 2018.
|Recording Mode||Supports selecting auto or manual mode when joining a channel to flexibly control the recording.|
|Control Recording||Adds interfaces to unbind the operations of joining a channel and recording. If the auto recording mode is used, the recording starts when a user joins the channel. If the manual recording mode is used, you can control when to start and stop the recording.|
|Mix Raw Audio||Supports the function of mixing raw audio data.|
|Java Recording API||Supports Java APIs for recording.|
|Transcoding Script||Supports setting the transcoding frame rate and resolution, either in picture-in-picture or single-stream mode.|
v2.0 was released on November 21, 2017.
decodeVideoparameters, and adds the
captureIntervalparameter to set the time interval of capturing screenshots.
streamTypeparameter to support different video stream types.
v1.3 was released on October 20, 2017.
cfgFilePathparameters in the
getPropertiesmethod to get the recording path immediately after recording is started before joining any channel.
v1.2 was released on August 21, 2017.
recordingsys.loglog file to check for failures.
v1.1 was released on July 25, 2017.
Adds recording at the web client.
Adds the real-time video mixing function.
Adds a set of callback functions.
Modifies the file format after transcoding.
Enables configuring the UDP port.
Unable to playback VLC files.
v1.0.1 was released on June 27, 2017, and fixes the crash when you set the channel profile of the recording as live broadcast.
v1.0.0 was released on June 15, 2017.
This is the first release of the On-premise Recording SDK with the following functions: