The Push SDK requires a license to enable stream ingest. Learn how to obtain and integrate the Push SDK license.
All-in-one license
The Push SDK uses the all-in-one license service from ApsaraVideo, which authorizes multiple SDKs for your app, such as the Push SDK and Queen SDK. The LicenseKey and LicenseFile (certificate file) are shared across all services that use the all-in-one license, so you only need to configure them once. Make sure to use the latest certificate file.
Apply for a license
Log on to the ApsaraVideo Live console. In the navigation pane on the left, choose , go to the My Licenses page to manage license authorizations.
To apply for a Push SDK license, follow these steps:
Create an application
Before you bind a license, create an application. Applications are categorized by client type: Mobile Client and Web Client.
-
For the Push SDK, select Mobile.
-
If your application is already bound to another service that uses the all-in-one license and has the same client type, you do not need to create a new application.
Select the Applications tab.
Click Create Application and fill in the application information. Enter an Application Name, select a client type (the client type cannot be changed after the application is created), and enter the corresponding Android Package Name, iOS Bundle ID, and HarmonyOS Bundle ID to create the application.

Bind an Android application signature
-
If you select Android for Platform and select Bind Signature, this parameter is required.
-
Binding a signature improves security and prevents your license from being used by other applications with the same package name.
-
Newer SDK versions do not require a bound signature. This includes MediaBox Audio and Video SDK v1.7.0 and later, ApsaraVideo Player SDK v5.5.2 and later, Push SDK v4.4.9 and later, and the short video SDK v3.36.0 and later.
You can obtain the MD5 hash of the Android application signature in two ways:
-
From the command line: Run the
keytool -v -list -keystore your.keystorecommand to view the MD5 hash of the signature. -
From Android Studio: In the Gradle sidebar on the right, find and click signingReport under your app's Tasks > android. Convert the letters in the resulting MD5 hash to lowercase and remove the colons.

Purchase a license
Select the Order Instance tab.
Click Purchase License to go to the purchase page. Select the SDK, platform, and version.
You can bind each license order to only one application.

After you confirm the information, click Buy Now.
Bind the license
Click Bind License to go to the binding page. Select the SDK license order and the application that you want to bind. After you confirm the information, click Bind.

After the binding succeeds, return to the License Management tab to view the bound application and its authorization information.
Configure the license
Configure the license on Android
-
(Recommended) Copy the license file to the assets directory in your Android Studio project.
NoteYou can also copy the license file to another location. However, you must make sure that the value of
com.aliyun.alivc_license.licensefilein Step 2 matches the path of the license file. -
Add a <meta-data> node to the AndroidManifest.xml file.
ImportantIf license verification fails after configuration, check whether the <meta-data> node is under the <application> element and whether the name attribute of the <meta-data> node is correct.

<meta-data android:name="com.aliyun.alivc_license.licensekey" android:value="foIV**************************************"/> <!-- TODO: Set your LicenseKey value--> <meta-data android:name="com.aliyun.alivc_license.licensefile" android:value="assets/cert/release.crt"/> <!-- TODO: Set your LicenseFile path-->
Configure the license on iOS
-
Copy the license file to the specified directory in your Xcode project, and select the current project in Target Membership.

-
Open Info.plist. Set AlivcLicenseKey to your license key and AlivcLicenseFile to the path of your license file.
Integrate the license on Flutter
For Flutter applications, integrate the native licenses for each target platform. For more information, see Configure the license on Android or Configure the license on iOS.
