Installation

This guide explains how to install the Wepin Flutter Widget SDK.

Requirements

  • Android: API version 21 or higher

    • You need to set the compileSdkVersion to 34 in the android/app/build.gradle file.

  • iOS: Version 13.0 or higher

    • Update the platform :ios version to 13.0 in your Flutter project’s ios/Podfile, and verify and modify the ios/Podfile as needed.

This package is only available for Android and iOS environments. It is not supported on Web, macOS, Windows, or Linux environments.

Installation

The Wepin Flutter Widget SDK is published on pub.dev, and you can install it by adding the following command or by adding a dependency in your app's pubspec.yaml.

  • Add using Flutter pub add command:

$ flutter pub add wepin_flutter_widget_sdk
  • Add to dependencies in pubspec.yaml:

dependencies:
    wepin_flutter_widget_sdk: ^0.0.1

Configuration

To enable OAuth login functionality (login.loginWithOauthProvider), you need to configure the Deep Link scheme.

  • Deep Link scheme format: wepin. + Wepin App ID

Android

  • Add manifestPlaceholders to the build.gradle (app) file to easily capture all redirects using this custom scheme with the Wepin Widget SDK.

iOS

  • Add the app’s URL scheme to the Info.plist file to redirect back to the app after the authentication process.

Permission Configuration

To use the Wepin Flutter Widget SDK, camera access permission is required. The camera function is essential for recognizing addresses in QR code format. [Reference: permission_handle]

Android

  • Add the following lines to your app's AndroidManifest.xml file:

iOS

  • Update Podfile: Add camera permission to your Podfile.

  • Update Info.plist: Add the required permission usage descriptions.

Last updated

Was this helpful?