Revenue Cat is an in-app subscription platform that lets you analyze and grow your cross-platform app subscriptions.

RudderStack supports Revenue Cat as a destination to which you can seamlessly send your event data.

Find the open source transformer code for this destination in the GitHub repository.

Getting started

Before configuring Revenue Cat as a destination in RudderStack, verify if the source platform is supported by Revenue Cat by referring to the table below:

Connection ModeWebMobileServer
Device mode---
Cloud modeSupportedSupportedSupported
To know more about the difference between cloud mode and device mode in RudderStack, refer to the RudderStack Connection Modes guide.

Once you have confirmed that the source platform supports sending events to Revenue Cat, follow these steps:

  1. From your RudderStack dashboard, add a source. Then, from the list of destinations, select Revenue Cat.
  2. Assign a name to the destination and click on Continue.

Connection settings

To successfully configure Revenue Cat as a destination, you will need to configure the following settings:

Revenue Cat connection settings
  • Public API Key: Enter your Revenue Cat public API key.

For more information on getting your Revenue Cat public API key, refer to the FAQ section below.

  • X-Platform: Select your app platform from the dropdown.

Identify

The identify method lets you identify a user and associate them to their actions. It also lets you record any traits about them like their name, email, etc.

RudderStack uses the identify call to create or update new subscribers in Revenue Cat. It maps userId (a required trait in every event) to Revenue Cat's app_user_id before sending the data via the subscribers API.

A sample identify call is shown below:

rudderanalytics.identify("1hKOmRA4GRlm",{
email: "alex@example.com",
phone: "+1-202-555-0146",
})

Traits mapping

RudderStack maps the following identify traits to the corresponding Revenue Cat attributes:

RudderStack traitRevenue Cat attribute
userId (Required)app_user_id
name$displayName
email$email
phone$phoneNumber
apnsTokens$apnsTokens
fcmTokens$fcmTokens
context.ip, request_ip$ip
appsflyerId$appsflyerId
iterableUserId$iterableUserId
mparticleId$mparticleId
onesignalId$onesignalId
airshipChannelId$airshipChannelId
clevertapId$clevertapId

The following identify traits are also mapped to the corresponding Revenue Cat attributes:

Revenue Cat cannot modify these attributes so you must send them only once.

RudderStack traitRevenue Cat attribute
idfa/ advertisingId$idfa
idfv/ device.id$idfv
gpsAdId$gpsAdId
advertisingId$androidId
campaign.name$campaign
creative$creative
keyword$keyword
mediaSource$mediaSource
ad$ad
addGroup$adGroup
adjustId$adjustId
fbAnonId$fbAnonId
iterableCampaignId$iterableCampaignId
iterableTemplateId$iterableTemplateId
mixpanelDistinctId$mixpanelDistinctId
amazonAdId$amazonAdId

The values for iterableCampaignId and iterableTemplateId must be valid non-negative, non-decimal integers. Otherwise, RudderStack will reject and skip these fields.

Track

The track method lets you capture user events along with the properties associated with them.

A sample track call is shown below:

rudderanalytics.track("Order Completed", {
userId: "1hKOmRA4GRlm",
currency: "USD",
fetch_token: "12456",
products: [{
product_id: "123454387",
name: "Game",
price: 15.99,
introductory_price: "24",
is_restore: true,
presented_offering_identifier: "123",
}
],
});

Event mapping

RudderStack maps the Order Completed event to Revenue Cat's Purchase event before sending it across via the receipts API. To do so, RudderStack requires the userId (mapped to app_user_id) and fetch_token properties to be present in the event.

Property mapping

RudderStack maps the following event properties to the corresponding Revenue Cat attributes:

RudderStack propertyRevenue Cat attributeComments
userId (Required)app_user_id-
fetch_token (Required)fetch_tokenThis must be a Base64 encoded receipt file for iOS, receipt token for Android, receipt for Amazon, and subscription token in case of Stripe.
currencycurrency-
payment_modepayment_mode-
product_id, products.product_idproduct_idThis is required for Google and should be the Apple, Google, or Amazon SKU or product identifier.
priceprice-
introductory_priceintroductory_price-
is_restoreis_restore-
presented_offering_identifierpresented_offering_identifier-

FAQ

Where can I find the Revenue Cat public API key?

To find the Revenue Cat public API key, follow these steps:

  1. Log into your Revenue Cat dashboard.
  2. From the top navigation bar, go to Projects and select your app, as shown:
Revenue Cat project in the dashboard
  1. Under Project settings, select API Keys. You will find your public API keys under Public app-specific API keys, as shown:
Revenue Cat public API key

Contact us

For more information on the topics covered on this page, email us or start a conversation in our Slack community.

Contents