flutterwave_payment 0.0.4+2 copy "flutterwave_payment: ^0.0.4+2" to clipboard
flutterwave_payment: ^0.0.4+2 copied to clipboard

A new Flutter plugin for flutterwave payment integration

flutterwave_payment #

A new Flutter plugin for flutterwave payment integration This fluterwave_payment plugin is a fork from - rave_flutter plugin which is no longer being updated so flutterwave_payment is born to fix a lot of issues within it.

This is a stable version of the payment gateway with more functionalities still to come.

build status Coverage Status pub package

A robust Flutter plugin for accepting payment on Rave with

  • Card
  • Nigerian Bank Account
  • ACH Payments
  • Mobile money Francophone Africa
  • Mpesa
  • Ghana Mobile Money
  • Uganda Mobile Money

Keys #

Installation #

To use this plugin, add flutterwave_payment as a dependency in your pubspec.yaml file.

Webview is required so enable PlatformView on iOS by adding:

<key>io.flutter.embedded_views_preview</key>
<true/

to Info.plist file

Making Payment #

Instantiate RavePayInitializer and pass it to RavePayManager.prompt along with the BuildContext. The result of the transaction is the Future returned by RavePayManager.initialize

processTransaction() async {
    // Get a reference to RavePayInitializer
    var initializer = RavePayInitializer(
        amount: 500, publicKey: publicKey, encryptionKey: encryptionKey)
      ..country = "NG"
      ..currency = "NGN"
      ..email = "customer@email.com"
      ..fName = "Ciroma"
      ..lName = "Adekunle"
      ..narration = narration ?? ''
      ..txRef = txRef
      ..subAccounts = subAccounts
      ..acceptMpesaPayments = acceptMpesaPayment
      ..acceptAccountPayments = acceptAccountPayment
      ..acceptCardPayments = acceptCardPayment
      ..acceptAchPayments = acceptAchPayments
      ..acceptGHMobileMoneyPayments = acceptGhMMPayments
      ..acceptUgMobileMoneyPayments = acceptUgMMPayments
      ..staging = true
      ..isPreAuth = preAuthCharge
      ..displayFee = shouldDisplayFee;

    // Initialize and get the transaction result
    RaveResult response = await RavePayManager()
        .prompt(context: context, initializer: initializer);
  }

Documentation #

Documentation can be found here.

Contributing, Issues and Bug Reports #

The project is open to public contribution. Please feel very free to contribute. Experienced an issue or want to report a bug? Please, report it here. Remember to be as descriptive as possible.

13
likes
70
pub points
47%
popularity

Publisher

unverified uploader

A new Flutter plugin for flutterwave payment integration

Repository (GitHub)
View/report issues

Documentation

API reference

License

Apache-2.0 (LICENSE)

Dependencies

async, dart_des, dio, equatable, flutter, flutter_svg, get_it, http, intl, meta, tripledes_nullsafety, webview_flutter

More

Packages that depend on flutterwave_payment