Files
Antonio PallaresandAxel Le Pennec cf71bf1ddb [EXTERNAL] Adds a convenience method to set the Amplitude User ID and Amplitude Device ID (#5425) via @alpennec (#5446)
* [EXTERNAL] Adds a convenience method to set the Amplitude User ID ($amplitudeUserId) and Amplitude Device ID ($amplitudeDeviceId) (#5425)

* Adding Amplitude UserID and DeviceID

* Add convenience method for setting Amplitude User ID and Amplitude Device ID

* fix lint

---------

Co-authored-by: Axel Le Pennec <alpennec@users.noreply.github.com>
2025-08-01 09:55:35 +02:00

6.9 KiB

RevenueCat

😻 In-App Subscriptions Made Easy 😻

Overview

RevenueCat is a powerful, reliable, and free to use in-app purchase server with cross-platform support. Our open-source framework provides a backend and a wrapper around StoreKit and Google Play Billing to make implementing in-app purchases and subscriptions easy.

Whether you are building a new app or already have millions of customers, you can use RevenueCat to:

  • Fetch products, make purchases, and check subscription status with our native SDKs.
  • Host and configure products remotely from our dashboard.
  • Analyze the most important metrics for your app business in one place.
  • See customer transaction histories, chart lifetime value, and grant promotional subscriptions.
  • Get notified of real-time events through webhooks.
  • Send enriched purchase events to analytics and attribution tools with our easy integrations.

Sign up to get started for free.

RevenueCat SDK Features

RevenueCat
✅ Server-side receipt validation
➡️ Webhooks - enhanced server-to-server communication with events for purchases, renewals, cancellations, and more
🖥 iOS, tvOS, macOS and watchOS support
🎯 Subscription status tracking - know whether a user is subscribed whether they're on iOS, Android or web
📊 Analytics - automatic calculation of metrics like conversion, mrr, and churn
📝 Online documentation up to date
🔀 Integrations - over a dozen integrations to easily send purchase data where you need it
💯 Well maintained - frequent releases
📮 Great support - Help Center

Migrating from Purchases v4 to v5

Version 5.0 of the SDK enables full StoreKit 2 flow on the SDK and the RevenueCat backend by default.

Our doc:V5_API_Migration_guide provides information on how to migrate from v4 to v5.

Migrating from Purchases v3 to v4

When transitioning between our V3 SDK, we ported our entire SDK into Swift. Migrating from Objective-C to Swift required a number of API changes, but we feel that the changes resulted in the SDK having a more natural feel for developers. In addition, we introduced several new types and APIs.

Our doc:V4_API_Migration_guide provides information on how to migrate from v3 to v4.

Getting Started

For more detailed information, you can view our complete documentation at docs.revenuecat.com.

Or browse our iOS sample apps:

Topics

Purchases

  • Purchases

Configuring the SDK

  • Purchases/configure(withAPIKey:)
  • Purchases/configure(with:)-6oipy
  • PurchasesDiagnostics

Displaying Products

  • Offerings

  • Offering

  • Package

  • StoreProduct

  • TestStoreProduct

  • SubscriptionPeriod

  • Purchases/offerings()

  • Purchases/getOfferings(completion:)

  • Purchases/products(_:)

  • Purchases/getProducts(_:completion:)

Making Purchases

  • StoreTransaction

  • Purchases/purchase(package:)

  • Purchases/purchase(package:completion:)

  • Purchases/purchase(product:)

  • Purchases/purchase(product:completion:)

Making Purchases with Subscription Offers

  • IntroEligibility

  • PromotionalOffer

  • StoreProductDiscount

  • Purchases/checkTrialOrIntroDiscountEligibility(productIdentifiers:)

  • Purchases/checkTrialOrIntroDiscountEligibility(productIdentifiers:completion:)

  • Purchases/checkTrialOrIntroDiscountEligibility(product:)

  • Purchases/checkTrialOrIntroDiscountEligibility(product:completion:)

  • Purchases/promotionalOffer(forProductDiscount:product:)

  • Purchases/getPromotionalOffer(forProductDiscount:product:completion:)

  • Purchases/purchase(package:promotionalOffer:)

  • Purchases/purchase(package:promotionalOffer:completion:)

  • Purchases/purchase(product:promotionalOffer:)

  • Purchases/purchase(product:promotionalOffer:completion:)

Subscription Status

  • CustomerInfo

  • EntitlementInfo

  • EntitlementInfos

  • PurchasesDelegate

  • Purchases/getCustomerInfo(completion:)

  • Purchases/customerInfo(fetchPolicy:)

  • Purchases/customerInfoStream

Identifying Users

  • Purchases/logIn(_:)-arja
  • Purchases/logIn(_:completion:)-4km90
  • Purchases/logOut()
  • Purchases/logOut(completion:)

Managing Subscriptions

  • Purchases/syncPurchases()
  • Purchases/syncPurchases(completion:)
  • Purchases/restorePurchases()
  • Purchases/restorePurchases(completion:)
  • Purchases/beginRefundRequestForActiveEntitlement()
  • Purchases/beginRefundRequest(forEntitlement:)
  • Purchases/beginRefundRequest(forProduct:)
  • Purchases/showManageSubscriptions()
  • Purchases/showManageSubscriptions(completion:)

Parsing Receipts

  • PurchasesReceiptParser
  • AppleReceipt

Subscriber Attributes

  • Purchases/setAttributes(_:)
  • Purchases/setAd(_:)
  • Purchases/setEmail(_:)
  • Purchases/setDisplayName(_:)
  • Purchases/setKeyword(_:)
  • Purchases/setCampaign(_:)
  • Purchases/setCreative(_:)
  • Purchases/setAdGroup(_:)
  • Purchases/setPushToken(_:)
  • Purchases/setPushTokenString(_:)
  • Purchases/setMediaSource(_:)
  • Purchases/setPhoneNumber(_:)
  • Purchases/setAttributes(_:)
  • Purchases/collectDeviceIdentifiers()

Integrations

  • Purchases/setAdjustID(_:)
  • Purchases/setAirshipChannelID(_:)
  • Purchases/setAppsflyerID(_:)
  • Purchases/setCleverTapID(_:)
  • Purchases/setFBAnonymousID(_:)
  • Purchases/setFirebaseAppInstanceID(_:)
  • Purchases/setMixpanelDistinctID(_:)
  • Purchases/setMparticleID(_:)
  • Purchases/setOnesignalID(_:)
  • Attribution/setPostHogUserID(_:)
  • Attribution/setAmplitudeUserID(_:)
  • Attribution/setAmplitudeDeviceID(_:)

Configuring the SDK with parameters (deprecated)

  • Purchases/configure(withAPIKey:appUserID:)-57pv0
  • Purchases/configure(withAPIKey:appUserID:purchasesAreCompletedBy:storeKitVersion:)-2k6md
  • Purchases/configure(withAPIKey:appUserID:observerMode:userDefaults:)
  • Purchases/configure(withAPIKey:appUserID:observerMode:userDefaults:useStoreKit2IfAvailable:)