Skip to main content
Skip to navigation

Customers | REST API v1 Reference (1.0)

Download OpenAPI specification:Download

RevenueCat API v1 endpoint reference for Customers.

Customers

Part of the REST API v1 Reference.

Operations about customers.

Endpoints

Get or Create Customer

Gets the latest Customer Info for the customer with the given App User ID, or creates a new customer if it doesn't exist.

Authorizations:
BearerAuth
path Parameters
app_user_id
required
string

The App User ID used with the mobile SDK.

header Parameters
X-Platform
string
Example: ios

Optionally set the X-Platform header to update the Customer's last_seen field. Set to either ios, android, amazon, macos, uikitformac. Don't set this if you are calling the getter for informational purposes or using a secret API key to fetch the customer's attributes.

Responses

Response samples

Content type
application/json
{
  • "request_date": "2019-07-26T17:40:10Z",
  • "request_date_ms": 1564162810884,
  • "subscriber": {
    }
}

Delete Customer

Permanently deletes a customer.

Authorizations:
BearerAuth
path Parameters
app_user_id
required
string

The App User ID of the customer to be deleted (might be an aliased App User ID).

Responses

Response samples

Content type
application/json
{
  • "app_user_id": "XXX-XXXXX-XXXXX-XX",
  • "deleted": true
}

Add Customer Attribution Data Deprecated

Attaches attribution data to a subscriber from specific supported networks.

Authorizations:
BearerAuth
path Parameters
app_user_id
required
string

The App User ID of the Customer.

Request Body schema: application/json
required
object

The data returned by the attribution network callbacks.

rc_idfa
string

The idfa from AdSupport on iOS. (iOS Only)

rc_gps_adid
string

The Google Play Services Advertising identifier. (Android Only)

network
required
string
Enum: "0" "1" "2" "3" "4" "5"

The attribution network the data is coming from:

  • 0: Apple Search AdSupport
  • 1: Adjust
  • 2: AppsFlyer
  • 3: Branch
  • 4: Tenjin
  • 5: Facebook

Responses

Request samples

Content type
application/json
{
  • "data": {
    },
  • "network": "0"
}

Response samples

Content type
application/json
"{}"

Update Customer Attributes

Updates attributes for a customer.

Authorizations:
BearerAuth
path Parameters
app_user_id
required
string

The App User ID used with the mobile SDK.

Request Body schema: application/json
object
required
object

Mapping of keys to attribute values.

value
required
string

The value of the attribute. If the value is null or an empty string, the attribute will be deleted.

updated_at_ms
integer <int64>

UNIX epoch in milliseconds of when the attribute was updated. This value is used to resolve conflicts, an attribute will only be updated if the new updated_at_ms value is newer than the value for the stored attribute.

Responses

Request samples

Content type
application/json
{
  • "attributes": {
    }
}

Response samples

Content type
application/json
{
  • "value": {
    }
}

Endpoint Reference

All API v1 resources, one page each. General concepts (authentication, request format, URL parameters) live on the API v1 overview.