Developer documentation

App SDK and HTTP API reference

Identify customers, track lifecycle events, register push tokens and evaluate in-app placements using the implemented Spinning Falcon SDK endpoints.

Base URL, identity and SDK key

Use the Functions API base URL and workspace ID supplied by your deployment. The public SDK endpoints below accept POST requests with JSON. Send Content-Type: application/json and the workspace public SDK key as Authorization: Bearer YOUR_SDK_PUBLIC_KEY when a key is configured.

The SDK key is for app-side messaging and event operations. It is not a RevenueCat secret, an administrative credential or an API for managing flows. Keep RevenueCat and sender credentials out of client code. The current public API does not expose general flow CRUD, audience administration or reporting export.

Content-Type: application/json
Authorization: Bearer YOUR_SDK_PUBLIC_KEY

POST /identifyCustomer

Create or update customer attributes without recording a lifecycle event. Use the same appUserId that RevenueCat uses. Attributes can supply message-template values; avoid sending unnecessary personal or sensitive data.

{
  "workspaceId": "YOUR_WORKSPACE_ID",
  "appId": "YOUR_APP_ID",
  "appUserId": "YOUR_USER_ID",
  "email": "test@example.com",
  "attributes": { "first_name": "Sam", "plan": "trial" }
}

POST /trackLifecycleEvent

Track a supported lifecycle event or a custom event you instrument in your app. Custom event names do not automatically collect behaviour; your app must send the event at the relevant point. Matching active flows can execute from these events.

DOWNLOADED and FIRST_OPEN are deduplicated by workspace, app, user and install identifier. Supply install_id for stable install tracking; without it, the handler falls back to a daily user/app/event key.

{
  "workspaceId": "YOUR_WORKSPACE_ID",
  "appId": "YOUR_APP_ID",
  "appUserId": "YOUR_USER_ID",
  "eventType": "FIRST_OPEN",
  "properties": { "install_id": "YOUR_INSTALL_ID" }
}

POST /registerPushToken and /unregisterPushToken

Register the current compatible Firebase messaging token for a user and app after permission is granted. The JavaScript SDK does not acquire a device token; your app supplies it. The iOS push package can handle permission and registration.

Send the same workspaceId, appId and appUserId to /unregisterPushToken to deactivate the registration. App IDs must match the app selected for dashboard test sends. A token from another push provider is not necessarily compatible.

{
  "workspaceId": "YOUR_WORKSPACE_ID",
  "appId": "YOUR_APP_ID",
  "appUserId": "YOUR_USER_ID",
  "token": "YOUR_FCM_TOKEN",
  "platform": "ios"
}

POST /evaluateInAppPlacement

Request eligible content for a placement after identifying the customer. Your app renders messages from the response and reports impressions or clicks. App-load banners should be evaluated again when the app returns to the foreground.

A draft queued with Test on a device is available only to the specified test user and placement for 30 minutes. It includes test: true. Placement evaluation alone does not display anything on the device.

{
  "workspaceId": "YOUR_WORKSPACE_ID",
  "appUserId": "YOUR_USER_ID",
  "placementId": "home"
}

POST /trackInAppEvent

Record impressions, clicks or dismissals after your app displays a message. For targeted banners, a click consumes the banner; impression and dismiss events do not permanently remove it, so your app can manage session-level display.

{
  "workspaceId": "YOUR_WORKSPACE_ID",
  "appUserId": "YOUR_USER_ID",
  "messageId": "MESSAGE_ID_FROM_RESPONSE",
  "eventType": "impression",
  "metadata": { "placementId": "home" }
}

POST /submitInAppSurveyResponse

Survey placement responses include question definitions. Render those definitions and submit answers against their question IDs. Responses are validated against the stored survey; one-response-per-user surveys are no longer returned after submission.

{
  "workspaceId": "YOUR_WORKSPACE_ID",
  "appUserId": "YOUR_USER_ID",
  "messageId": "SURVEY_MESSAGE_ID",
  "placementId": "home",
  "answer": { "answers": [{ "questionId": "q_1", "rating": 5 }] }
}

Check errors before retrying

Inspect the response body as well as the HTTP status. Invalid or missing identifiers and content can produce validation errors; an SDK key mismatch is an authentication error. Fix the request or configuration before retrying.

Avoid automatic retry loops for event and engagement submissions unless you understand that endpoint’s deduplication behaviour. Use your own test user to validate each request, and verify the resulting profile, delivery or placement activity in the dashboard.

Prepare your first growth workflow.

Start with your RevenueCat connection and one tested messaging channel.

Start free