FortID LogoFortID

How to build EUDI Reference Wallet

A guide on setting up and verifying using Android Reference wallet

This guide describes how to setup Android EUDI Reference Wallet and how to use it with the FortID Verifier to verify a PID or mDL credential stored in the Android EUDI Reference wallet. Please note that the official reference Issuer https://issuer.eudiw.dev is updated regularly. As a result, the credentials it issues may become incompatible with the FortID components, and the previous versions of EUDI Reference Wallet, at the time of testing. To maintain compatibility, between the issuer, verifier and the wallet, we host version 0.7.2 of the Reference Issuer at link.

Android Reference Wallet build instructions

Prerequisites

  1. Android Studio

  2. Git

  3. Android Device

    • An Android device running Android 8.0 (API level 26) or higher
    • USB cable to connect your device to the computer

NOTE: Tested with Android Studio Meerkat | 2024.3.1 Patch 2

Setting Up the Project

  1. Clone the Repository

    git clone git@github.com:eu-digital-identity-wallet/eudi-app-android-wallet-ui.git
    cd eudi-app-android-wallet-ui
  2. Checkout the Specific Version

    git checkout Wallet/Demo_Version=2025.03.24-Demo_Build=24
  3. Open the Project in Android Studio

    • Launch Android Studio
    • Click on "Open an existing Android Studio project"
    • Navigate to the cloned repository folder and select it
    • Wait for the project to sync and download dependencies

Configure project

In order for the app to work with FortID verifier we need to update pre-registered OpenId4VP configuration:

  • open file in Android Studio
core-logic/src/demo/java/eu/europa/ec/corelogic/config/ConfigWalletCoreImpl.kt
  • add updates to file:
    1. Import in import section
    import eu.europa.ec.eudi.wallet.transfer.openId4vp.PreregisteredVerifier
    1. Add constants to companion object
    private companion object {
        const val VCI_ISSUER_URL = "https://ref-issuer.fortid.com"
        const val VCI_CLIENT_ID = "wallet-dev"
        const val AUTHENTICATION_REQUIRED = false
        const val OPENID4VP_VERIFIER_API_URI = "https://evs.fortid.com/protocol/authorization-response"
        const val OPENID4VP_VERIFIER_LEGAL_NAME = "FortID Verifier Service"
        const val OPENID4VP_VERIFIER_CLIENT_ID = "FortID-Verifier-Service"
    }
    1. Update OpenId4Vp configuration, withClientIdSchemes part, with constants declared in previous step
    withClientIdSchemes(
      listOf(ClientIdScheme.Preregistered(
         listOf(
            PreregisteredVerifier(
               clientId = OPENID4VP_VERIFIER_CLIENT_ID,
               verifierApi = OPENID4VP_VERIFIER_API_URI,
               legalName = OPENID4VP_VERIFIER_LEGAL_NAME
            )
         )
      )),
    )

Connecting Your Android Device

  1. Enable Developer Options

    • Go to Settings on your Android device
    • Scroll down to "About phone"
    • Find "Build number" and tap it 7 times
    • You'll see a message that you're now a developer
  2. Enable USB Debugging

    • Go back to Settings
    • Find "Developer options" (usually at the bottom)
    • Enable "USB debugging"
  3. Connect Your Device

    • Connect your Android device to your computer using a USB cable
    • On your device, you might see a prompt asking to allow USB debugging - tap "Allow"
    • In Android Studio, you should see your device listed in the "Device Manager"

Building and Running the Application

  1. Build and Run the Application

    • Make sure your Android device is selected in the device dropdown menu
    • Click the "Run" button (green play icon) in the toolbar
    • Alternatively, press Shift+F10 (Windows/Linux) or Control+R (Mac)
  2. First Run

    • The first build might take several minutes as Android Studio downloads dependencies and builds the project
    • You'll see the app being installed and launched on your device

Building Without a Device and Manual APK Installation

Building the APK

  1. Generate Release APK

    • In Android Studio, click on "Build" in the top menu
    • Select "Generate App Bundles or APKs"
    • Choose "Generate APKs"
    • Wait for the build to complete
    • You'll see a notification when the build is finished
  2. Locate the APK

    • After successful build, click on "locate" in the notification

    • Alternatively, navigate to:

      app/build/outputs/apk/demo/debug/app-demo-debug.apk
    • The APK file will be named something like app-demo-debug.apk

    • Once the APK is generated, please follow the instructions in How to Install the Reference Wallet APK.

Troubleshooting

  1. Device Not Recognized

    • Ensure USB debugging is enabled
    • Try a different USB cable
    • Check if your device appears in the list when running adb devices in the terminal
  2. Build Errors

    • Make sure you have the correct version of Android Studio
    • Check that you have the required SDK versions installed
    • Try "File" > "Invalidate Caches / Restart" if you encounter strange build issues
  3. App Crashes

    • Check the "Logcat" window in Android Studio for error messages
    • Ensure your device meets the minimum Android version requirement

Additional Resources

Remember to keep your Android Studio and SDK tools updated for the best development experience.

Verifying

At this point, the EUDI Reference Wallet stores the PID or mDL VC. You can now proceed with the verification flow by following this guide.

On this page