OloPaySDK

Welcome to the Olo Pay SDK

PCI compliance is your responsibility but the Olo Pay SDK simplifies your process of maintaining PCI compliance by doing the heavy lifting of processing sensitive credit card data for you. See below for details on adding the SDK to your project and integrating it into your app to submit payments to Olo's Ordering API.

Useful Links:


Setup

The easiest way to get set up with using the Olo Pay SDK is to add it as a dependency in your build.gradle file, replacing X.Y.Z with the version of the SDK you want to use.

implementation com.olo.olopay:olo-pay-android-sdk:X.Y.Z

Getting Started

The Olo Pay SDK helps with PCI compliance by creating a token to represent sensitive credit card data. The tokenized data is then used in your app to submit payments via Olo's Ordering API. The Olo Pay SDK supports two different types of tokens: Payment Method and CVV Update tokens. Specific details about each token and how to use the SDK to generate them can be found below.

Payment Methods (new cards & digital wallets)

This approach is used for cards that have not previously been saved on file with Olo. This includes new credit cards and digital wallets. With this tokenization approach, an IPaymentMethod is created that is then used to submit a basket with Olo's Ordering API.

  1. Initialize the SDK. It is recommended to initialize on application startup, but it can be initialized anywhere in your app that is convenient.

    Important: Make sure the SDK is initialized prior to calling methods that generate payment methods


  2. Choose how to create a payment method

  3. Submit the IPaymentMethod data to the Basket Submit endpoint of Olo's Ordering API

CVV Update Tokens (previously saved cards)

This approach is used for cards that have previously been saved on file with Olo, and you want to reverify the CVV of the saved card prior to submitting a basket and processing a payment. With this tokenization approach, an ICvvUpdateToken is created that is then used to submit a basket with Olo's Ordering API.

Important: It is up to you to determine when to verify the CVV on a saved card.

  1. Initialize the SDK. It is recommended to initialize on application startup, but it can be initialized anywhere in your app that is convenient.

    Important: Make sure the SDK is initialized prior to calling methods that generate payment methods


  2. Add the CVV control to your app

    • See PaymentCardCvvView: This will display an input field for entering a CVV value and provides full flexibility for styling and customization.

  3. Get an ICvvTokenParams instance

  4. Generate an ICvvUpdateToken instance

  5. Submit the ICvvUpdateToken data to the Basket Submit endpoint of Olo's Ordering API


Packages

Link copied to clipboard

Classes for initializing the Olo Pay SDK, as well as generating tokens for sensitive card data.

Link copied to clipboard

Convenience classes that help with initializing the Olo Pay SDK.

Link copied to clipboard

PCI-compliant credit card UI controls

Link copied to clipboard

Callback classes for responding to user input on the PCI-compliant credit card UI controls

Link copied to clipboard

An assortment of data and enum classes used throughout the Olo Pay SDK

Link copied to clipboard

Exceptions that can be thrown while making Olo Pay API calls

Link copied to clipboard

Classes for adding Google Pay to your app.

Link copied to clipboard
Link copied to clipboard