Skip to main content

RevenueCat

Written by Daria Mamchenkova

RevenueCat is a platform for managing in-app subscriptions and purchases in mobile applications. It provides cross-platform SDKs and backend services that simplify subscription implementation, receipt validation, customer management, and purchase synchronization across the Apple App Store and Google Play.

In addition to subscription infrastructure, RevenueCat offers analytics, integrations with third-party services, and tools for monitoring and optimizing subscription performance.

Before you begin

RevenueCat

1. Add the application to Affise MMP.

⚠️ Affise MMP SDK initialization is to be made before RevenueCat SDK initialization to make further integration function correctly.

3. Add all required events.

🔎 Affise recommends adding the following events:

  • Login

  • Start Trial

  • Subscription

4. In the Event Login, add the customer_user_id parameter to send the RevenueCat user ID. To pass the RevenueCat user ID, you are to make the Get random device ID request and to send the obtained value via the customer_user_id parameter.

⚠️ Using customer_user_id and synchronizing it between Affise and RevenueCat is obligatory, otherwise installs and subscriptions will not be attributed.

Examples of passing customer_user_id in events where you can use any event:

"events": [
{
"affise_event_id": "8002007e-017b-1000-a2fe-16198a99e2a1",
"affise_event_name": "AddToCart",
"affise_event_category": "native",
"affise_event_timestamp": 1734659765614,
"affise_event_first_for_user": false,
"affise_event_user_data": "Subscription",
"affise_event_data": {
"affise_event_add_to_cart_timestamp": 1734659765614
},
"affise_parameters": {
"affise_p_currency": "USD",
"affise_p_product_id": "subscription",
"affise_p_price": 14,
"affise_p_customer_user_id": "100C063B-267A-451B-9768-AC7C503C3E3D"
}
}
],

 "events": [
{
"affise_event_id": "90023l6e-013b-1000-a2de-20000a43e4a0",
"affise_event_name": "Login",
"affise_event_timestamp": 1728660123456,
"affise_event_first_for_user": true,
"affise_event_data": {
"affise_event_login_timestamp": 1728660123456
},
"affise_parameters": {
"affise_p_customer_user_id": "190C061B-538E-981B-7347-DC7C007C0E2D"
}
}
]

5. Set the integration with RevenueCat WebHook. For that, do the following:

a. In the Affise MMP panel, select the needed application.

b. In the application settings, select the Subscription tab.

c. In the Integrations dropdown list, select Revenue cat.

The system generates two fields: Revenue cat and Secure Code.

6. Go to the RevenueCat panel.

7. Select your project in the RevenueCat dashboard, find the Integrations card in the left menu, and select Webhooks.

8. Select Add new configuration.

9. In the Webhook name field, enter the name of the Webhook integration.

10. In the Webhook URL field, enter the Affise RevenueCat link.

11. In the Authorization header value field, enter the Affise secure code.

12. In the Environment to send events for drop-down list, select whether to send events for production purchases, sandbox purchases, or both.

13. Optional. Configure the transmission of the required events.

🔎 Affise recommends sending all events.

14. Save changes.


Please contact the Affise Customer Support team regarding all raised questions via the e-mail: [email protected].​

Did this answer your question?