sbiepay_flutter_sdk 1.0.0 copy "sbiepay_flutter_sdk: ^1.0.0" to clipboard
sbiepay_flutter_sdk: ^1.0.0 copied to clipboard

SBIePay 2.0 Flutter SDK

sbiepay_flutter_sdk Integration Guide #

This guide outlines the different methods to integrate the sbiepay_flutter_sdk package into your Flutter project.

Requirements #

  1. SDK Download: Download the latest Flutter SDK from pub.dev.
  2. Development Environment: Use dart SDK version >=3.5.3 up to <4.0.0 and Flutter version >=3.3.0
  3. Network Requirements: Ensure the device can access the internet for API communication.
  4. Android Support: API level from 28 (Android 9) to 36
  5. iOS Support: Minimum iOS 13.0+
  6. Supported Payment Methods: Ensure the payment methods offered by the aggregator (credit card, debit card, UPI, etc.) match your requirements.

Installation #

Add the dependency to your pubspec.yaml:

dependencies:
  sbiepay_flutter_sdk: ^1.0.0

Then run:

flutter pub get

Only For IOS: Install Pods. #

For the SDK to work in Flutter iOS, navigate to the ios/ directory via terminal using cd ios command.

Then run:

pod install

Ensure that your Info.plist includes the necessary permissions for internet and networking.

Usage example: #

  1. Import the SDK in your Dart file:
import 'package:sbiepay_flutter_sdk/sbiepay_flutter_sdk.dart';	 
  1. Call your APIs to generate final url for payment.

  2. Create transactionCheckout instance:

final transactionCheckout = TransactionCheckout();
  1. Call below method which is override from SDK.
    transactionCheckout.initiateTransaction( 
        context: context, 
        paymentUrl: paymentUrl, 
        referrer: referrer, 
        transactionResultListener: TransactionResultListener( 
          onSuccess: (response) => handleTransactionSuccess(response), 
          onPending: (response) => handleTransactionPending(response), 
          onError: (response) => handleTransactionError(response), 
          onFailed: (response) => handleTransactionFailed(response), 
          onCancelled: (response) => 
              handleTransactionCancelled(response), 
          onTimeOut: (response) => handleTransactionTimeOut(response), 
       )); 
  1. Handle Transaction Responses Implement appropriate handlers for each transaction status:
void handleTransactionSuccess(dynamic response) {
// Handle successful transaction
}

void handleTransactionPending(dynamic response) {
// Handle pending transaction
}

void handleTransactionError(dynamic response) {
// Handle transaction error
}

void handleTransactionFailed(dynamic response) {
// Handle failed transaction
}

void handleTransactionCancelled(dynamic response) {
// Handle cancelled transaction
}

void handleTransactionTimeOut(dynamic response) {
// Handle transaction timeout
}
0
likes
110
points
147
downloads

Publisher

unverified uploader

Weekly Downloads

SBIePay 2.0 Flutter SDK

Homepage

Documentation

API reference

License

unknown (license)

Dependencies

flutter, plugin_platform_interface

More

Packages that depend on sbiepay_flutter_sdk

Packages that implement sbiepay_flutter_sdk