# Android Setup # Android SDK: Setup Prepare your Android project to consume the Ei Card Provider SDK (core) and the Digital Card Engine UI SDK. This page covers repositories, credentials, Gradle config, dependencies, and required permissions. ## Requirements * Android: `minSdk 29`, `compileSdk/targetSdk 35` * Kotlin: 2.0.x (`jvmTarget = 11`) * Jetpack Compose (BOM 2024.04.01 or newer) for UI components * Network access in your app manifest ## Repositories (including MeaWallet MCD) Add the Google, Maven Central, and MeaWallet MCD Maven repos to `settings.gradle.kts`: ```groovy pluginManagement { repositories { google() mavenCentral() gradlePluginPortal() maven { url = uri("https://nexus.ext.meawallet.com/repository/mcd-android-group/") credentials { username = providers.gradleProperty("MEA_MAVEN_USERNAME").get() password = providers.gradleProperty("MEA_MAVEN_PASSWORD").get() } } } } dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() maven { url = uri("https://nexus.ext.meawallet.com/repository/mcd-android-group/") credentials { username = providers.gradleProperty("MEA_MAVEN_USERNAME").get() password = providers.gradleProperty("MEA_MAVEN_PASSWORD").get() } } } } ``` Store credentials securely (for example, `~/.gradle/gradle.properties` or CI secrets): ```groovy MEA_MAVEN_USERNAME={{MEA_MAVEN_USERNAME}} MEA_MAVEN_PASSWORD={{MEA_MAVEN_PASSWORD}} ``` ## Module dependencies Add to your app module `build.gradle.kts`: ```groovy dependencies { // Core SDK (data + API) implementation("com.paymentology:card_provider_sdk:1.0.0") // MeaWallet MCD (secure card images) // For dev/testing: implementation("com.meawallet:mcd-test:1.7.1") // For production, use your provisioned artifact: // releaseImplementation("com.meawallet:mcd--:") // Digital Card Engine UI SDK // If consuming from this repo: implementation(project(":digital_card_engine_sdk_android")) // If consuming a published artifact: // implementation("com.paymentology:digital-card-engine-sdk-android:") } ``` ## Android and Compose configuration ```groovy android { compileSdk = 35 defaultConfig { minSdk = 29 } compileOptions { sourceCompatibility = JavaVersion.VERSION_11 targetCompatibility = JavaVersion.VERSION_11 } kotlinOptions { jvmTarget = "11" } buildFeatures { compose = true } composeOptions { kotlinCompilerExtensionVersion = "1.5.14" } } dependencies { implementation(platform("androidx.compose:compose-bom:2024.04.01")) implementation("androidx.compose.ui:ui") implementation("androidx.compose.material3:material3") implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.8.4") } ``` ## Permissions Ensure network permissions are declared in `AndroidManifest.xml`: ```xml ``` ## Verify setup 1. Sync Gradle. 2. Run a simple app build. 3. Call `DigitalCardEngineSDK.initialize(context, token, env)` (see the Initialize page). 4. If you plan to show secure card images, confirm the MCD artifact resolves and `MeaCardData.initialize` runs without errors.