FastPay Flutter SDK

FastPay Developers Arena

Accept payments with FastPay's APIs. Our simple and easy-to-integrate APIs allow for less effort in processing payments. This is an official support channel, but our APIs support both Android and iOS.


Screenshot 1 Screenshot 2 Screenshot 3

Quick Glance


  fastpay_merchant: ^1.0.10
  #To handle callbacks (Redirection) from fastpay wallet application.
  app_links: ^4.0.0 

Android Setup

  • Requires AndroidX

Build Gradle

Include support in android/app/build.gradle add this line if not exit:

implementation ''


change theme app in android/app/src/main/res/values/styles.xml and android/app/src/main/res/values-night/styles.xml to :

if you want show appbar with app name title :
if you do not want show appbar with app name title :

Example :

<!-- change theme app to AppCompat theme -->
 <style name="LaunchTheme" parent="Theme.AppCompat.Light">
       <!-- update this line to change background payment color to white -->
        <item name="android:windowBackground">#ffffff</item>



add this line to manifest

       <-- lable name show in fastpay title screen -->
       <-- add this line in hear --> 


It doesn't need to be changed

  • iOS only supports real device you can't test it on simulator because FastPay SDK not support simulator

Initiate FastPaySDK

  • Store ID : Merchant’s Store Id to initiate transaction
  • Store Password : Merchant’s Store password to initiate transaction
  • Order ID : Order ID/Bill number for the transaction, this value should be unique in every transaction
  • Amount : Payable amount in the transaction ex: “1000”
  • isProduction : Payment Environment to initiate transaction (false for test & true for real life transaction)
  • Call back Uri: When the SDK redirect to the fastpay application for payment and after payment cancel or failed it throws a callback with this uri. It is used for deeplinking with the client app for catching callbacks from fastpay application.
  • Callback( Sdk status, message): There are four sdk status (e.g. FastpayRequest.SDKStatus.INIT) and status message.
  enum SDKStatus{


FastpayResult _fastpayResult = await FastPayRequest(
                    storeID: "********", 
                    storePassword: "********",
                    amount: "1000", 
                    orderID: "HBBS7657", 
                     isProduction: false,
              callback: (status,message){
            },callbackUri: "sdk://",);

 if (_fastpayResult.isSuccess ?? false) {
       // transaction success
     } else {
       // transaction failed

SDK callback Uri

//Using app_links
import 'package:app_links/app_links.dart';

Future<void> _handleIncomingIntent() async {
    final _appLinks = AppLinks();
    final uri = await _appLinks.getLatestAppLink();
    final allQueryParams = uri?.queryParameters;
    final status = allQueryParams?['status'];
    final orderId = allQueryParams?['order_id'];
    debugPrint("..........................STATUS::: "+status.toString()+", OrderId:::"+orderId.toString());

NOTE: Don't forget to add following code block to your android manifest file.

            <action android:name="android.intent.action.MAIN"/>
            <category android:name="android.intent.category.LAUNCHER"/>
            <data android:scheme="sdk" android:host="" android:pathPrefix="/further/paths"/>
            <action android:name="android.intent.action.VIEW" />
            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />

For iOS redirection:

  • Create URI Create a URI with a unique name (our suggestion is to provide your app name with prefix text "appfpclient", for example, if your app name is "FaceLook", your URI should be appfpclientFaceLook)
  • Add URI to your info.plist Now add this URI to your app info.plist file
    < string>appfpclientFaceLook</string>

When FastPayRequest call open FastPay SDK then after payment return FastpayResult that contains:

payment result

  • isSuccess : return true for a successful transaction else false.
  • errorMessage : if transaction failed return failed result
  • transactionStatus : Payment status weather it is success / failed.
  • transactionId : If payment is successful then a transaction id will be available.
  • orderId : Unique Order ID/Bill number for the transaction which was passed at initiation time.
  • paymentAmount : Payment amount for the transaction. “1000”
  • paymentCurrency : Payment currency for the transaction. (IQD)
  • payeeName : Payee name for a successful transaction.
  • payeeMobileNumber : Number: Payee name for a successful transaction.
  • paymentTime : Payment occurrence time as the timestamp.
callback URI pattern (SUCCESS): sdk://
callback URI pattern (FAILED): sdk://