cloudpayments_flutter

A Flutter plugin for integrating Cloudpaymanets in Android and iOS (test) applications.

It is not an official plugin. It uses SDK-Android on Android and SDK-IOS on iOS.

See the official documentation:

Supports

  • X Check the validity of the card's parameters.
  • X Generate card cryptogram packet.
  • X Show 3ds dialog.

Getting Started

Initializing for Android

If you want to show 3ds dialog on Android, make MainActivity implements FlutterFragmentActivity instead of FlutterActivity

android/app/src/main/.../MainActivity.kt:

import io.flutter.embedding.android.FlutterFragmentActivity

class MainActivity: FlutterFragmentActivity() {}

Usage

  • Check card number validity.
bool isValid = await CloudpaymentsFlutter.isValidNumber(cardNumber);
  • Check card expire date.
bool isValid = await CloudpaymentsFlutter.isValidExpireDate(cardNumber); // MM/yy
  • Generate card cryptogram packet. You need to get your publicId from your personal account.
final cryptogram = await CloudpaymentsFlutter.cardCryptogram(cardNumber, expireDate, cvcCode, publicId);
  • Showing 3DS form and get results of 3DS auth.
final result = await CloudpaymentsFlutter.show3ds(acsUrl, transactionId, paReq);

Libraries

cloudpayments_flutter
cryptogram
three_ds_response