UAE PASS
  • UAE PASS
  • Overview
  • Getting Onboarded with UAE PASS
    • Onboarding Process for UAE PASS Service Providers
      • Initiation Phase
      • Development Phase
      • Assessment Phase
      • Go live Phase
  • Quick Start Guide - UAE PASS Staging Environment
    • User Account Types
    • Create Staging UAE PASS Account
    • Upgrade Staging UAE PASS Account
    • Testing Credentials for POC
    • Conduct a POC with UAE PASS Authentication
  • Feature Guides
    • Authentication
      • Web Integration
        • Introduction
        • Pre-Requisites
        • Endpoints
        • 1. Authorization Code
        • 2. Access Token
        • 3. User Information
        • 4. Logout
        • Login Button
        • Authentication Postman Walkthrough
      • Mobile Integration
        • Introduction
        • Pre-Requisites
        • Requirements
        • Guide
          • SDK
          • API
        • SDK Integration
      • Token Validation API
        • Introduction
        • Pre-Requistes
        • Endpoints
        • Integration Steps
          • 1. Verify access token API using Basic Authentication
          • 2. Obtaining Authenticated User Information from the Access Token
        • Validation Decisions
      • User Linking
        • Automatic Linking
        • Manual Linking
        • Corporate Account
    • Digital Signature
      • Digital Signature (Single Document)
        • Signing Guide
          • Endpoints
          • Document Signing Steps
            • 1. Token
            • 2. Create Signer Process
            • 3. Sign Document
            • 4. Obtaining Document
            • 5. LTV Configuration
              • Integration Web Services
              • Postman Collection for LTV
            • 6. Deleting Document
          • Document Signature verification Process
          • Postman Collection for Digital Signature
            • Digital Signature Postman Walkthrough
        • Verification API Integration
          • Web Service Details
          • Postman Collection for Signature Verification API
      • Digital Signature (Multiple Document)
        • Signing Guide
          • Endpoints
          • Document Signing Steps
            • 1. Token
            • 2.Create Documents
            • 3. Create Signer Process
            • 4. Sign Document
            • 5. Obtaining Document
            • 6. LTV Configuration
              • Integration Web Services
              • Postman Collection for LTV
            • 7. Deleting Document
          • Document Signature verification Process
          • Postman Collection for Multiple Document Signing.
    • e-Seal
      • Introduction
      • DESC Process for Dubai Entities
        • Process overview
        • Detailed DESC process description
      • ICA Process for Non-Dubai Entities
        • Onboarding Process
        • Obtaining Credentials and Certificates
      • Integration Web Service
        • PAdES eSeal Signing
        • CAdES eSeal Signing
        • eSeal verification
        • eSeal error codes
      • Postman Collection
    • Hash Signing
      • Introduction
      • Hash Signing (Single Document)
        • Hash Signing (Java SDK Set Up)
          • Quick Setup
          • Hash Signing Process
            • 1. Start the Process
            • 2. Initiate Signing Process
            • 3. Sign PDF Document
          • Endpoints
          • Postman Collection
          • Utility Files
      • Bulk Hash Signing (Multiple Documents)
        • Quick Setup
        • Hash Signing Process
          • 1. Start Signing Process
          • 2. Initiate Signing Process
          • 3. Sign PDF Document
        • Endpoints
        • Postman Collection
  • Web Registration
    • Introduction
    • Steps to create account
    • Endpoints
      • 1. Access Code
      • 2. Access Token
      • 3. User Information
  • Facial Biometric Transactions Confirmation
    • Web Integration
      • Endpoints
      • Integration Steps
        • Obtain Authorization Code
        • Obtain Access Token
        • Obtain User Info
        • Log out User
    • Mobile Integration
      • Mobile Integration Guidelines
  • Guidelines
    • Use-Case Guidelines
      • Standard Authentication Scenarios for Service Provider Use Cases
      • Standard Digital Signature Scenarios for Service Provider Use Cases
      • Standard Implementation Guidelines
    • Design Guidelines
      • UAEPASS Button Guideline
      • Text Message Guidelines
  • Resources
    • Attributes List
    • Sample Apps
    • Staging Apps
    • Assets
  • FAQ
    • Common Integration Issues
  • Versioning
Powered by GitBook
On this page
  • Android Native:
  • iOS Native

Was this helpful?

  1. Feature Guides
  2. Authentication
  3. Mobile Integration
  4. Guide

SDK

PreviousGuideNextAPI

Last updated 2 years ago

Was this helpful?

Android Native:

  1. Download .

  2. Add Client ID in UAEPassRequestModels.java

  3. Add Client Secret in UAEPassRequestModels.java

  4. Add Redirect URL in UAEPassRequestModels.java

  5. Choose the Environment, Whether it is staging or production.

  6. In the activity from where UAE Pass Authentication is required, copy the "Adding Custom Scheme and Host" section to the AndroidManifest file to that particular activity, and make the launch mode as singleTask. (android:launchMode="singleTask").

  7. In the modules Build.gradle file, copy the "Adding Custom Scheme Variables" section to the defaultConfig.

  8. Change "URI_SCHEME" and "scheme" value to your app name.

This is a mandatory step to avoid conflicting with other apps in the future.

9. Check whether the project has Kotlin enabled. If not, open app level Build.gradle and copy "Enable Kotlin Version" and "Enable Kotlin Dependency" to respective place. Also in the modules Build.gradle, copy "Enable Kotlin Dependency" section to the dependencies.

10. In the Activity from where UAE Pass Authentication is triggered, copy the section "Callback to handle UAE Pass callback".

A global search can be made for the term "//UAE PASS" which will display the modifications that are required to be made.

iOS Native

  1. Download SDK Files.

  2. Setup the Framework.

- Create LocalPods folder if not already created.

- Add UAEPPASSClient folder in LocalPods folder.

- Add pod 'UAEPassClient', :path => "LocalPods/UAEPassClient" to your podfile.

3. Open AppDelegate and add the following:

- import UAEPassClient

4. In didFinishLaunchingWithOptions, add the below:

UAEPASSRouter.shared.spConfig = SPConfig(redirectUriLogin: "client redirect url",
                                         scope: "client login scope",
                                         state: "RANDOM 24 alpha numeric",  //Randomly Generated Code 24 alpha numeric.
                                         successSchemeURL: "UUUUU://", //client success url scheme.
                                         failSchemeURL: "CCCCC://", //client failure url scheme.
                                         signingScope: "urn:safelayer:eidas:sign:process:document") // client signing scope.
UAEPASSRouter.shared.environmentConfig = UAEPassConfig(clientID: "your client id", clientSecret: "your client secret", env: .production)
env (environment can be : .production or .qa or .dev)
func application(_: UIApplication, handleOpen url: URL) -> Bool {
    print("<><><><> appDelegate URL : \(url.absoluteString)")
    if url.absoluteString.contains(HandleURLScheme.externalURLSchemeSuccess()) {
        if let topViewController = UserInterfaceInfo.topViewController() {
            if let webViewController = topViewController as? UAEPassWebViewController {
                webViewController.forceReload()
            }
        }
        return true
    }

    else if url.absoluteString.contains(HandleURLScheme.externalURLSchemeFail()) {
        guard let webViewController = UserInterfaceInfo.topViewController() as? UAEPassWebViewController  else {
            return false
        }
        webViewController.foreceStop()
        let alertController = UIAlertController(title: "Failed to login with UAE PASS Login", message: "Try again later", preferredStyle: .actionSheet)
        let okAction = UIAlertAction(title: "OK", style: UIAlertAction.Style.default) {
            _ in
            NSLog("OK Pressed")
            webViewController.navigationController?.popViewController(animated: true)
        }
        alertController.addAction(okAction)
        self.window?.rootViewController?.present(alertController, animated: true, completion: nil)
        return false
    }

    return true
}

5. Add UAE Pass scheme in your project info.plist in LSApplicationQueriesSchemes (Already added in this sample).

for Production: uaepass
for QA: uaepassstg
for DEV: uaepassdev

6. After pressing login with UAE PASS button, choose the prefered environment to login through UIAlertController and from this action a trace can be done to show how it works.

7. From application(_: UIApplication, handleOpen url: URL) -> Bool in AppDelegate

Apply a force to current webview to reload or stop loading incase of success or failure.

This sample contains three view controllers :

-- ViewController.swift (main screen which contains login button and UIAlertController to select required environment).

-- UserProfileViewController.swift (Just simple view to show user profile details and it contains sign document scneario as well).

-- UAEPassWebViewController.swift (Resposible for handling webView requests to generate uaepass code to use it for token generation).

8. For the Signing Flow, the following steps is required:

  1. It should be a valid PDF document, and the sample code for downloading the pdf file is given.

  2. A valid token should be generated for the signing process.

  3. The valid pdf document should then be uploaded to UAE PASS.

  4. After the upload, a request for signing should be sent. The following can then be selected:

    • Signature type: Advanced or Qualified

    • The page which signature will be placed

    • Signature coordinates and Signature size

9. testSignData.json is a very important file as this is the signing information which should be passed to UAEPASS and it is expected to be recieved from the backend. It is also required to be reconfigured to add SP's own app scheme.

This sample supports dark mode as well.

For visitor integration: SP need to use the below scopes to their first authentication call to retrieve the unifiedID and profileType attribute of the user:

 scope=urn:uae:digitalid:profile:general urn:uae:digitalid:profile:general:profileType urn:uae:digitalid:profile:general:unifiedId

SDK Files