Available today: iOS (and macOS / Catalyst) and Android. The React Native, Flutter, Unity, Cordova, Capacitor and Web SDKs are on the roadmap and are not published yet. Their pages describe the intended API, not a package you can install. Track availability in the table below.
SDK Overview
One consistent purchase API. Available today for iOS, macOS and Android; other platforms are on the roadmap.
CashSDK wraps the platform store (StoreKit 2 on Apple, Play Billing on Android)
behind a single, consistent API. Every SDK does the same three things: run a
purchase, read entitlements, and keep a customer in sync across
devices with identify. Transactions are verified server-side, so your client
never has to trust the store on its own.
Pick your platform#
Swift and SwiftUI, built on StoreKit 2.
Kotlin coroutines over Play Billing v9.
Roadmap: one TypeScript API for iOS and Android.
Roadmap: a single Dart package for every target.
Roadmap: C# for games on iOS, Android, and desktop.
Roadmap: a plugin for Apache Cordova hybrid apps.
Roadmap: a native Capacitor plugin for Ionic and web apps.
Native macOS and Mac Catalyst on StoreKit 2.
Roadmap: Stripe checkout with unified entitlements.
Zero to a validated purchase in 15 minutes.
Platforms at a glance#
| Platform | Package | Native layer | Status |
|---|---|---|---|
| iOS | github.com/cashsdk/cashsdk-ios (SPM) | StoreKit 2 | Available |
| macOS / Catalyst | github.com/cashsdk/cashsdk-ios (SPM) | StoreKit 2 | Available |
| Android | com.cashsdk:cashsdk-android (Gradle, Maven Central) | Play Billing v9 | Available |
| React Native | cashsdk-react-native | StoreKit 2 + Play Billing | Roadmap |
| Flutter | cashsdk | StoreKit 2 + Play Billing | Roadmap |
| Unity | com.cashsdk.unity (UPM) | StoreKit 2 + Play Billing | Roadmap |
| Cordova | cashsdk-cordova | StoreKit 2 + Play Billing | Roadmap |
| Capacitor | cashsdk-capacitor | StoreKit 2 + Play Billing | Roadmap |
| Web | cashsdk-web | Stripe (and other web processors) | Roadmap |
The shared API#
The same calls power every integration. Configure once with your publishable key, then work with purchases and entitlements.
import CashSDK
CashSDK.configure(publishableKey: "csk_pk_…")
CashSDK.shared.identify(userId: "8841", userToken: tokenFromYourBackend)
switch try await CashSDK.shared.purchase("pro_monthly") {
case .success(let entitlements):
if entitlements.isActive("pro") { unlockPro() }
case .pending, .userCancelled:
break
}
try await CashSDK.shared.restore()
import com.cashsdk.CashSDK
CashSDK.configure(context = this, publishableKey = "csk_pk_…")
CashSDK.shared.identify(userId = "8841", userToken = tokenFromYourBackend)
val entitlements = CashSDK.shared.purchase(activity, "pro_monthly")
if (entitlements.isActive("pro")) unlockPro()
CashSDK.shared.restore()
The building blocks#
- Configure: call once on launch with your
csk_pk_…publishable key. Secret keys (csk_sk_…) are backend-only and must never ship in a client app. - Purchase: takes a product identifier, runs the native store flow, and verifies the transaction server-side before returning the customer's updated entitlements.
- Paywalls:
register(placement:)resolves and presents the paywall your team configured in the dashboard, so pricing and copy change without a release. - Entitlements: the access a customer has right now (
pro,premium). CheckisActiveto gate features. - Identify: link the SDK to your own
app_user_idso entitlements follow a customer across devices and platforms.
New to the model? Read Concepts for how products, entitlements, offerings, paywalls, and customers fit together.
Billing backends#
Store purchases are only half the picture. CashSDK also reconciles revenue from web and merchant-of-record billing providers (Stripe, Paddle, Lemon Squeezy, and more) into the same entitlement and analytics model. See Billing overview to connect one.