Skip to main content
This article explains how to integrate Unity Payment Links with the Android platform. To integrate with Android:
  1. Go to the Build Settings window and make sure your Unity project is set to Android. Once set, the AppchargeConfig file updates to display Android-specific configuration options. Android Build Settings
  2. Click Player Settings > Publisher Settings, and scroll to the Build section.
  3. Expose (enable) the following android plugin files or the build process will be passed without changes:
    • Custom Main Manifest (AndroidManifest.xml)
    • Custom Main Gradle Template (mainTemplate.gradle)
    • Custom Gradle Properties Template (gradleTemplate.properties)
    Android Editor Configurations
  4. Your configuration settings should look like this: Android Configurations
    By default, the configuration file is preconfigured for integration. However, you must set the required Environment and Checkout Public Key fields under Publisher Info.

    Publisher Info

    These settings can also be changed at runtime, but doing so requires re-initializing the SDK.

    Platform Auto Integration Settings

    Gradle Properties

    These settings automatically modify your AndroidManifest.xml and Gradle files to include all necessary dependencies at build time.
    You can choose to exclude or disable specific dependencies based on your project’s needs.

    Gradle Dependencies

    Manifest Modifications

    • If Exclude Checkout Service isn’t checked, the SDK automatically adds the required permissions and the CheckoutService declaration to your manifest file without duplicating existing permissions. If Exclude Checkout Service is checked, the SDK doesn’t modify your manifest file.
    • If you’re upgrading an existing integration that already includes the CheckoutService declaration, update android:foregroundServiceType from dataSync to shortService in your manifest.

    Example Manifest

    If the options above are not excluded (disabled), your final Manifest will look like this:
    The intent-filter includes a scheme "acnative-{IDENTIFIER}". Change the {IDENTIFIER} to the last sequence of your package name. For example, if your package name is com.appcharge.mysupergame, the identifier will be mysupergame.This name must be lowercase with no spaces, according to the Android code style guide.

    General Auto Integration Settings

    Disabling Enable Integration Options prevents automatic configuration required for the Checkout SDK from functioning correctly. If disabled, you must manually configure each required file.