Setup
Before starting, make sure you follow the Get started guide, where you'll find what's needed for integration.
In order to set up our Push ProvisioningPush Provisioning A method that allows cardholders to add their card to a digital wallet (such as Apple Pay or Google Pay) directly from your app. The card details are securely tokenized and sent to the wallet provider, streamlining the process and enhancing the user experience compared to manual provisioning. This feature is currently in beta. SDK, follow these steps.
Add our Push Provisioning SDK
From v2, the SDK is distributed via the Weavr Push ProvisioningPush Provisioning A method that allows cardholders to add their card to a digital wallet (such as Apple Pay or Google Pay) directly from your app. The card details are securely tokenized and sent to the wallet provider, streamlining the process and enhancing the user experience compared to manual provisioning. This feature is currently in beta. SDK Maven repository. All required runtime dependencies are bundled transitively with the SDK.
1. Get repository credentials
Contact [email protected] to receive:
- A username with access to the Android SDK artifacts
- An access token with permission to download the SDK
2. Add Weavr Push Provisioning SDK repository in settings.gradle
Add our Push ProvisioningPush Provisioning A method that allows cardholders to add their card to a digital wallet (such as Apple Pay or Google Pay) directly from your app. The card details are securely tokenized and sent to the wallet provider, streamlining the process and enhancing the user experience compared to manual provisioning. This feature is currently in beta. SDK Maven repository under dependencyResolutionManagement:
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
// Weavr Push Provisioning SDK Maven repository
maven {
url = uri("https://maven.pkg.github.com/weavr-io/push-provisioning-android")
credentials {
username = project.findProperty("WEAVR_SDK_USERNAME") as String?
?: System.getenv("WEAVR_SDK_USERNAME")
password = project.findProperty("WEAVR_SDK_PASSWORD") as String?
?: System.getenv("WEAVR_SDK_PASSWORD")
}
}
}
}
3. Store credentials securely in gradle.properties or environment variables
Store the repository username and access token either in your global Gradle properties file (recommended) or as environment variables. For example:
WEAVR_SDK_USERNAME=their-username
WEAVR_SDK_PASSWORD=sdk-access-token
You can also use a project-level gradle.properties file, but ensure it is gitignored and never committed.
Treat the access token as a secret. Use your team's secret management solution (such as CI secrets or a password manager) to share and rotate these values.
4. Add the SDK dependency in app/build.gradle
With the repository and credentials configured, add our Push ProvisioningPush Provisioning A method that allows cardholders to add their card to a digital wallet (such as Apple Pay or Google Pay) directly from your app. The card details are securely tokenized and sent to the wallet provider, streamlining the process and enhancing the user experience compared to manual provisioning. This feature is currently in beta. SDK dependency to your app module:
dependencies {
implementation 'io.weavr.push-provisioning:push-provisioning:<latest_version>'
}
That is all that is required. The SDK brings in its own transitive dependencies, so you do not need to declare any additional libraries manually.
Add provisioning_config file
In addition to adding the SDK and dependencies, you'll have to provide a configuration file.
To do so, you need to add the provisioning_config file to your raw assets folder.
Contact our support team at [email protected] to obtain this file.
This file is sensitive, make sure you store and distribute it in a secure manner.
Do not commit this file to your repository. Distribute it via secure file-sharing software among your team.
Finally, use the secrets feature of your CI software of choice to avoid impacting your CI/CD pipelines.