Cross-Promote for Android apps
Cross-promotion allows you to promote the family apps within your app and gives you an opportunity to make your users aware of all the different apps you develop. Refer to the user guide to configure your apps for cross-promotion.
Add the SDK
- Before your begin, make sure that Apptics is integrated into your project by following the integration guide.
- Declare the cross-promotion dependency using Apptics BoM.
Copieddependencies {
// ...
// Apptics BoM, latest version is mentioned in the integration guide.
implementation platform('com.zoho.apptics:apptics-bom:[latest-version]')
// Since BoM version is specified, no need to explicitly specify the dependency version.
implementation 'com.zoho.apptics:apptics-crosspromo'
}
- Alternatively, if you do not use Apptics BoM, you can directly declare the cross-promotion dependency with its version.
Copieddependencies {
// Have to explicitly mention the version, if you are not using BoM.
// latest version is mentioned in the integration guide.
implementation 'com.zoho.apptics:apptics-crosspromo:[latest-version]'
}
Note: It is recommend to use Apptics BoM to avoid unnecessary compatibility issues.
- Initialize cross-promotion SDK in application onCreate() method.
CopiedApptics.init(this)
Present cross-promotion activity
- On calling the below method, the cross-promotion activity will be presented with the apps list as configured in the Apptics web console.
CopiedAppticsCrossPromotion.startActivity(activity)
Note: For apps targeting Android 30 or above, add an element in AndroidManifest.xml with the list of package names that are configured for cross-promotion listing. Refer to this link.