Flutter Plugin Overview

Samsung Pay SDK Flutter Plugin enables to use the Samsung Pay SDK. The primary aim of the Samsung Pay SDK is to integrate selected Samsung Wallet features with Flutter based Android apps on Samsung devices.

The following major operations are supported in the plugin:

  • In-App Payment Gives customers the option of paying for products and services with Samsung Wallet.

  • Push Provisioning Allows customers add a bank card to Samsung Wallet from the issuer app by providing the required card details.

To integrate partner applications with the Samsung Pay SDK Flutter Plugin, the following components are included in the download:

  • Samsung Pay SDK Flutter Plugin Contains classes, interfaces, and required libraries of Samsung Pay which is required to communicate with Samsung Pay services.

  • API Reference Provides descriptions of the APIs included in the Samsung Pay SDK Flutter Plugin.

  • Sample merchant app and sample issuer app showing how Samsung Pay APIs can be coded in a finished Flutter Plugin project. All major operations of the Samsung Pay SDK Flutter Plugin are implemented for demonstration purposes.

Samsung Pay SDK Flutter Plugin architecture

The following diagram shows a high-level architecture revealing the general interactions between the Samsung Pay SDK flutter plugin and a partner app.

SDK high-level architecture

Viewed at this level, the partner apps leverage the Samsung Pay SDK Flutter Plugin to perform the operations shown ― push provisioning and opening Favorite Cards for issuers; online payments for merchants ― with Samsung Pay. The key components involved are:

  • Partner app - merchant- or issuer-developed app for making online/offline payments and provisioning payment cards through Samsung Pay.

  • Samsung Pay SDK Flutter Plugin - SDK integrated into the partner app for direct communication with Samsung Pay

  • Samsung Pay app - Pay app that the Samsung Pay SDK communicates with.

  • Financial network - comprises the payment gateways, acquirers, card associations, and issuers that participate in transaction processing under agreement with the merchant.

Setting up Flutter Plugin Environment

The importance of maintaining a good development environment cannot be overstated. For integrating the Samsung Pay SDK Flutter Plugin with your partner app, the following prerequisites and recommendations help ensure a successful plugin integration and implementation.

Please check the requirements below for the Samsung Pay SDK Flutter Plugin:

  1. For Android and system requirements please check the Samsung Pay Android SDK Overview.

  2. To develop a Samsung Pay SDK Flutter Plugin service, merchants and issuers need to create service. Please check this guide for service creation process: Service registration

  3. Download the Samsung Pay SDK Flutter Plugin to use the plugin

The plugin has the following directory structure:

Folder

Contents

Docs

API reference documentation

Libs

samsungpaysdkflutter_v1.01.00 flutter plugin – contains the Samsung Pay APIs to be used by your partner app

Samples

Sample apps

Integrate Samsung Pay SDK Flutter Plugin with your Project

Be sure to do the following before attempting to use the Plugin:

  1. If not already part of your environment, download and install an IDE. Android Studio is recommended.

  2. Download the Samsung Pay SDK Flutter Plugin

Configure your IDE to integrate the Samsung Pay SDK Flutter Plugin with your partner app.

  • Go to pubspec.yaml and enter the following dependency:
dependencies:
 samsung_pay_sdk_flutter:
  path: plugin_directory_path\

[NOTE] If your plugin path is C:\Users\USERNAME\Downloads, the dependency will be like below:

dependencies:
samsung_pay_sdk_flutter:
path: C:\Users\USERNAME\Downloads\

For Android ProGuard rules and DexGuard, please check the Android SDK Overview.