Superwall

Integrate in-app purchase events from RevenueCat with Superwall

RevenueCat can automatically send billing, subscription, and revenue metrics to Superwall, a paywall SDK that lets you remotely update every aspect of your paywall. This can be helpful in optimizing pricing and understanding which paywalls are producing customers with the highest LTV. For example, customers with the Superwall integration enabled can:

  • Create paywalls on-the-fly without shipping app updates
  • Determine which paywalls have high trial conversion rates
  • Find which product & paywall combinations have the highest LTVs
  • Offer discounts to users who churn

Events

The Superwall integration tracks the following events:

EventDescription
Initial PurchaseThe first purchase of an auto-renewing subscription product, includes free trials.
Non Subscription PurchaseThe purchase of any product that's not an auto-renewing subscription.
RenewalWhen an auto-renewing subscription product renews OR a user repurchases the auto-renewing subscription product after a lapse in their subscription.
Product ChangeA subscriber has changed the product of their subscription.
CancellationA subscription or non-renewing purchase has been cancelled.
UncancellationWhen a user re-enables the auto-renew status for a subscription.
Billing IssuesThere has been a problem trying to charge the subscriber.

This does not mean the subscription has expired (in the case of a grace period enabled).
Subscription pausedA subscription has been paused.
TransferA transfer of transactions and entitlements was initiated between one App User ID(s) to another.
ExpirationA subscription has expired and access should be removed.

Setup

1. Set Superwall User Identity

In order to associate RevenueCat subscription data with Superwall paywall events, the RevenueCat app user ID must match the Superwall app user ID. You can read more about how Superwall handles user ID’s in their documentation here. You can set up a custom app user ID in RevenueCat by following the instructions in our Identifying Users documentation.

2. Send RevenueCat events to Superwall

After you've set up the Purchases SDK and Superwall SDK to have the same user identity, you can "turn on" the integration from the RevenueCat dashboard.

  1. Navigate to your project in the RevenueCat dashboard and find the Integrations card in the left menu. Select + New
332332
  1. Choose Superwall from the Integrations menu
  2. Add your Superwall Token (Superwall settings > Integrations)

Remember to select Add Integration

18641864

Testing the Superwall integration

Make a sandbox purchase with a new user

Simulate a new user installing your app, and go through your app flow to complete the sandbox purchase.

Check that the Superwall event delivered successfully

While still on the Customer View, select the purchase event in the Customer History page and make sure that the Superwall integration event exists and was delivered successfully.

22462246

Check Superwall dashboard for the delivered event

Navigate to your Superwall dashboard > Users and search for the created app user ID. You will see events RevenueCat has dispatched to the Superwall under 'Recent Events'.

23522352

Sample Event

Below is a sample JSON that is delivered to Superwall for a Trial Started event.

{
  "api_version": "1.0",
  "event": {
    "aliases": [
      "$RCAnonymousID:646c8236950c4ffdb7eda9618c32fe66"
    ],
    "app_id": "app83e93e5855",
    "app_user_id": "$RCAnonymousID:646c8236950c4ffdb7eda9618c32fe66",
    "country_code": "US",
    "currency": "USD",
    "entitlement_ids": null,
    "environment": "SANDBOX",
    "event_timestamp_ms": 1644280494982,
    "expiration_at_ms": 1644280667000,
    "id": "D492AA52-07ED-4948-BF22-04A86636DA1E",
    "is_family_share": false,
    "offer_code": null,
    "original_app_user_id": "$RCAnonymousID:646c8236950c4ffdb7eda9618c32fe66",
    "original_transaction_id": "1000000964160097",
    "period_type": "TRIAL",
    "presented_offering_id": "default",
    "price": 0,
    "price_in_purchased_currency": 0,
    "product_id": "rc_3999_1y_1w0",
    "purchased_at_ms": 1644280487000,
    "store": "APP_STORE",
    "subscriber_attributes": {},
    "takehome_percentage": 0.7,
    "transaction_id": "1000000964160097",
    "type": "INITIAL_PURCHASE"
  }
}

👍

You've done it!

You should start seeing subscription data from RevenueCat appear in Superwall.