Setup With Swift Package Manager

The Olo Pay SDK supports Swift Package Manager (SPM). For more information about SPM and how it works, refer to the Swift Pacakge Manager site. This guide will walk through adding the Olo Pay SDK to your app using Swift Package Manager.

Important

If you have manually added the Olo Pay SDK as a dependency to your project and are now switching to Swift Package Manager, please manually remove all Olo Pay and Stripe dependencies from your project and then follow the First Time Setup instructions

First Time Setup

  1. Create development and production targets for your app (if you don’t have them already)
  2. In Xcode, choose File --> Add Package Dependencies...

    Note

    Some versions of Xcode say Add Packages...

  3. In the search bar, enter the iOS SDK Repo url: https://github.com/ololabs/olo-pay-ios-sdk-releases

  4. Select the olo-pay-ios-sdk-releases package

  5. Select your dependency rules and click the Add Package button

    Note

    SPM support was added in v4.0.1

SDK Updates

  1. In Xcode, right-click on OloPaySDK under Package Dependencies and select Update Package