Skip to content

A Flutter wrapper to use the SumUp SDK. With this plugin, your app can easily connect to a SumUp terminal, login and accept card payments on Android and iOS.

License

Notifications You must be signed in to change notification settings

ed-oo/sumup_flutter_plugin

 
 

Repository files navigation

sumup

pub package likes popularity pub points

A Flutter wrapper to use the SumUp SDK.

With this plugin, your app can easily connect to a SumUp terminal, login and accept card payments on Android and iOS.

Prerequisites

  1. Registered for a merchant account via SumUp's country websites (or received a test account).
  2. Received SumUp card terminal: Air, Air Lite, PIN+ terminal, Chip & Signature reader, or SumUp Air Register.
  3. Requested an Affiliate (Access) Key and registered your application ID via SumUp Dashboard for Developers.
  4. Deployment Target iOS 12.0 or higher.
  5. Android minSdkVersion 23 or higher.

Installing

Add sumup to your pubspec.yaml:

dependencies:
  sumup:

Import sumup:

import 'package:sumup/sumup.dart';

Getting Started

Init SumUp SDK:

Sumup.init(affiliateKey);

Login:

Sumup.login();

Or login with token:

Sumup.loginWithToken(token);

Choose your preferred terminal:

Sumup.openSettings();

Prepare terminal for checkout:

Sumup.prepareForCheckout();

Complete a transaction:

var payment = SumupPayment(
    title: 'Test payment',
    total: 1.2,
    currency: 'EUR',
    foreignTransactionID: '',
    saleItemsCount: 0,
    skipSuccessScreen: false,
    tip: .0,
);

var request = SumupPaymentRequest(payment);

Sumup.checkout(request);

Available APIs

Sumup.init(affiliateKey);

Sumup.login();

Sumup.isLoggedIn;

Sumup.merchant;

Sumup.openSettings();

Sumup.prepareForCheckout();

Sumup.checkout(request);

Sumup.logout();

// iOS only
Sumup.isCheckoutInProgress;

About

A Flutter wrapper to use the SumUp SDK. With this plugin, your app can easily connect to a SumUp terminal, login and accept card payments on Android and iOS.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Dart 35.4%
  • Kotlin 33.2%
  • Swift 24.5%
  • Ruby 5.5%
  • Objective-C 1.4%