The Worldline Connect Swift SDK provides a convenient way to support a large number of payment methods inside your iOS app. It supports iOS 12.0 and up out-of-the-box. The Swift SDK comes with an UIKit example app and a SwiftUI example app that illustrate the use of the SDK and the services provided by Worldline Global Collect on the Worldline Global Collect platform.
See the Worldline Connect Developer Hub for more information on how to use the SDK.
The Worldline Connect Swift SDK is available via the following package managers: CocoaPods, Carthage and Swift Package Manager.
You can add the Swift SDK as a pod to your project by adding the following to your Podfile
:
$ pod 'WorldlineConnectKit'
Afterwards, run the following command:
$ pod install
You can add the Swift SDK with Carthage, by adding the following to your Cartfile
:
$ github "Worldline-Global-Collect/connect-sdk-client-swift"
Afterwards, run the following command:
$ carthage update --platform ios --use-xcframeworks
Navigate to the Carthage/Build
directory, which was created in the same directory as where the .xcodeproj
or .xcworkspace
is. Inside this directory the .xcframework
bundle is stored. Drag the .xcframework
into the "Framework, Libraries and Embedded Content" section of the desired target. Make sure that it is set to "Embed & Sign".
You can add the Swift SDK with Swift Package Manager, by configuring your project as following:
https://github.com/Worldline-Global-Collect/connect-sdk-client-swift
When the package has successfully been added, it will automatically be added as a dependency to your targets as well.
To obtain the Swift SDK, first clone the code from GitHub:
$ git clone https://github.com/Worldline-Global-Collect/connect-sdk-client-swift.git
Open the Xcode project that is included to test the SDK.