パッケージ、リポジトリ、アプリカテゴリを検索

パッケージ詳細v1.1.1

flutter_uae_pass

iOS、Android、Web プラットフォームをサポートする Flutter 用の UAE Pass プラグイン。これは非公式バージョンです。

AndroidiOSWeb
30日間ダウンロード
108
いいね数
17
Pub ポイント
130

パッケージをインストール

flutter pub add flutter_uae_pass

パッケージ概要

公開情報に基づく選定ガイドです。参考としてご利用ください。

Android、iOS、Web プラットフォーム向けに UAE Pass との統合を可能にする Flutter プラグインです。この非公式実装により、ユーザーは UAE Pass の資格情報を使用して認証でき、アラブ首長国連邦の政府および民間サービスへのアクセスがスムーズになります。プラグインは安全なトークン取得をサポートし、プラットフォーム固有の設定を処理するため、開発者がアプリ内に信頼できる本人確認機能を実装しやすくなります。アラブ首長国連邦のデジタルアイデンティティ基準に準拠する必要があるアプリケーション向けに設計されています。

用途

  • アラブ首長国連邦を拠点とする政府サービスアプリ
  • 本人確認を必要とする民間セクターのアプリ
  • デジタルオンボーディングワークフロー
  • アラブ首長国連邦在住者の安全なログイン
  • Webおよびモバイルアプリ認証

主な機能

  • クロスプラットフォーム対応(Android、iOS、Web)
  • 公式ではないが機能的な実装
  • トークンベースの認証
  • UAEパスの本人確認をサポートしています
  • pub.dev を通じたシンプルな統合

適している対象

  • アラブ首長国連邦を対象としたアプリケーションを開発する開発者
  • コンプライアンス対応のデジタルアイデンティティソリューションを必要とするアプリ
  • セキュアなユーザー認証を必要とするプロジェクト
  • アラブ首長国連邦市場をターゲットにしたスタートアップ
  • サードパーティ認証を統合するフロントエンドチーム

注意事項

  • UAEパスによって公式に推奨されていません
  • 新しいUAEパスAPIの変更に対応するための更新が必要になる場合があります
  • 公式プラグインと比べてドキュメントが限られている
  • 追加のバックエンド検証が必要になる可能性
  • プラットフォーム固有のセットアップ手順は異なる場合があります

元の README

関連するソースリポジトリの README 原文のスナップショットです。最新の内容はリポジトリをご覧ください。

flutter_uae_pass

Un-official UAE Pass Flutter plugin for iOS, Android, and Web.

Demo

Platform Screenshots

Android iOS Web
Android iOS Web

Platform Support

Platform Supported Implementation
iOS ✅ WKWebView with full screen modal
Android ✅ Custom WebView Activity
Web ✅ OAuth2 popup authentication

Getting Started

  • Add the plugin to your pubspec.yaml file
flutter_uae_pass: ^1.0.6
  • Run flutter pub get
flutter pub get
  • Import the package
import 'package:flutter_uae_pass/flutter_uae_pass.dart';
final _uaePassPlugin = UaePass();


  • Initialize the plugin - Sandbox
  await _uaePassPlugin.setUpSandbox();
  • Initialize the plugin - Production
    await _uaePassPlugin.setUpEnvironment(
      clientId: "<clientId>",
      clientSecret: "<clientSecret>",
      urlScheme: "myappscheme",
      redirectUri: "<redirectUri>",
      isProduction: true,
      language : "en",
    );

Scopes are as follows

  • urn:uae:digitalid:profile:general
  • urn:uae:digitalid:profile

Main features

  • signIn()
  • getAccessToken(String authCode)
  • getProfile(String token)
  • signOut()

Call the authenticate method

  String? authCode = await _uaePassPlugin.signIn();

To get access token

  String? accessToken = await _uaePassPlugin.getAccessToken(authCode);

To get public profile data

you can fetch this information from profile

  • idn
  • email
  • firstnameAR
  • firstnameEN
  • fullnameEN
  • gender
  • lastnameAR
  • lastnameEN
  • mobile
  • nationalityAR
  • nationalityEN
  • sub
  • userType
  • uuid
  ProfileData? profileData = await _uaePassPlugin.getProfile(accessToken);

iOS Setup

  • Add the following to your Info.plist file

		<key>LSApplicationQueriesSchemes</key>
		<array>
			<string>uaepass</string>
			<string>uaepassqa</string>
			<string>uaepassdev</string>
			<string>uaepassstg</string>
		</array>
		<key>CFBundleURLTypes</key>
		<array>
			<dict>
				<key>CFBundleTypeRole</key>
				<string>Editor</string>
				<key>CFBundleURLName</key>
				<string>myappscheme</string>
				<key>CFBundleURLSchemes</key>
				<array>
					<string>myappscheme</string>
				</array>
			</dict>
		</array>

Android Setup

  • Update android:launchMode="singleTask" the AndroidManifest.xml file

 <activity
            android:name=".MainActivity"
            android:exported="true"
            android:launchMode="singleTask"
            .....

            </activity>

  • Set up the queries in your AndroidManifest.xml file (To make our app open UAE Pass App)
    <queries>
        <package android:name="ae.uaepass.mainapp" />
        <package android:name="ae.uaepass.mainapp.qa" />
        <package android:name="ae.uaepass.mainapp.stg" />
    </queries>

  • Set up the intent filter in your AndroidManifest.xml file (To Reopen our application after uaepass done)
            <intent-filter >
                <action android:name="android.intent.action.VIEW" />

                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.BROWSABLE" />


                <data
                    android:host="success"
                    android:scheme="myappscheme" />

                <data
                    android:host="failure"
                    android:scheme="myappscheme" />

            </intent-filter>

Web Setup

For web applications, no additional configuration is required! The plugin automatically uses a popup-based OAuth2 flow that works in all modern browsers.

Web-Specific Features:
  • Popup Authentication: Opens UAE Pass login in a secure popup window
  • Automatic Redirect Handling: Automatically detects and processes the authorization callback
  • CORS Compliance: Uses proper HTTP requests for token exchange and profile retrieval
  • Session Management: Handles cookies and localStorage for proper logout functionality
Browser Requirements:
  • Modern browsers with popup support (Chrome, Firefox, Safari, Edge)
  • JavaScript enabled
  • Cookies enabled for proper session management
Production Considerations:
  • Ensure your redirect URI is properly configured in the UAE Pass dashboard
  • For production, make sure your domain is whitelisted in UAE Pass configuration
  • Test popup blockers - inform users to allow popups for your domain if needed

References

Thanks for Faisal for this repo uae_pass_flutter i improve the code and create this package

カテゴリー

依存関係

依存関係一覧 1 件

  • plugin_platform_interface^2.0.2

ソースリポジトリ

このパッケージを使用しているプロジェクト

データはまだありません。