SDK Programming Guide
  • Understanding and using the SDK: an overview
  • The Samsung Pay SDK is an application framework for integrating select Samsung Pay features with Android-based partner apps on Samsung devices. The following operations are supported:

  • In-App Payment. Gives customers the option of paying for products and services with Samsung Pay. See Use Case: Online Payments.
  • Push Provisioning. Lets customers add a bank card to Samsung Pay from the issuer app by providing the required card details. See Use Case: Push Provisioning.
  • Open Favorite Cards. Starts the Samsung Pay payment screen for a specific card from the issuer app and lets users select a card already registered in Samsung Pay to make in-store (offline) payments. See Use Case: Open Favorite Cards.
  • The overall architecture showing the interactions between Samsung Pay SDK and a partner app is depicted in Figure 1.
  • Figure 1: Samsung Pay SDK architecture (high level)

  • Viewed at a high level, partner apps can simply leverage the Samsung Pay SDK to perform the operations shown ― push provisioning and opening Favorite Cards for issuers; online payments for merchants ― with Samsung Pay. Key components include:
  • Partner app : merchant- or issuer-developed app for making online/offline payments and provisioning payment cards through Samsung Pay.
  • Samsung Pay SDK : SDK integrated into partner app for direct communication with Samsung Pay
  • Samsung Pay app : Pay app with which the Samsung Pay SDK communicates
  • Financial network : comprises the payment gateways, acquirers, card associations, and issuers that participate in transaction processing under agreement with the merchant.
  • 1.1 Use Case: Online Payments
  • The most common In-App (online) payment use case takes the following form:
    1. Merchant app presents user with the option of making payment with Samsung Pay.
    2. Upon user selection of the Samsung Pay option, merchant app calls the APIs included in the Samsung Pay SDK to initiate a transaction with Samsung Pay app.
    3. Samsung Pay app responds with the tokenized payment information necessary to complete the transaction.
    4. Merchant app forwards this payment information to the designated Payment Gateway (PG), either directly or through the merchant's web server, or indirectly via the Samsung-PG Interface server for normal transaction processing.
  • 1.2 Use Case: Push Provisioning
  • The push provisioning use case ― adding payment cards to Samsung Pay from the card issuer app ― generally takes this form:
    1. User logs into the issuer app.
    2. Issuer app checks if the Samsung Pay app is activated on the device and ready to use. If in ready status, issuer app displays the Add button for the cards not currently registered/enrolled with the Samsung Pay app.
    3. If the add card option is selected, issuer app calls the API to push the proper payload data to Samsung Pay.
    4. While card is provisioned, Samsung Pay stays in background.
  • 1.3 Use Case: Open Favorite Cards
  • Open Favorite Cards use cases via an issuer app using the Samsung Pay SDK will have the following form:
    1. User logs into issuer app.
    2. Issuer app checks if the Samsung Pay app is activated on the device and ready to use. If in ready status, the issuer app displays the Pay button for cards currently registered/enrolled with the Samsung Pay app.
    3. If user selects the pay option, the issuer app calls the API to request to open Favorite Cards with the selected card information.
    4. The Samsung Pay app starts its Favorite Cards screen, displaying the selected card for an in-store payment.
  • 1.4 Integrating the Samsung Pay SDK with your app
  • The following steps comprise the general process for integrating the Samsung Pay SDK with your app:
    1. Sign up for the Samsung Pay Developers portal by clicking SIGN UP and register your Samsung Account (or create it if you don’t already have one), then LOG IN.
    2. 2. Follow the on-screen instructions for adding your app and creating a new service to generate the SERVICE ID you’ll need to reference in your project code, along with a debug-api-key (see Understanding the Debug API key and API level below.
      • Note
      • The Service ID replaces Product ID as of SDK v1.4.
    3. Download the Samsung Pay SDK.
    4. Add the Samsung Pay SDK (samsungpay.jar) to your Android project using Android Studio.
    5. Develop your partner app with the required API calls and callbacks for Samsung Pay integration.
    6. Upload a release version of your app it to the Samsung Pay Developers portal for approval.
    7. Upon Samsung approval, publish your partner app to the Google Play store and Samsung Galaxy Apps.