Entitlements

Grant and revoke access for a customer programmatically.

An entitlement is a named level of access (like pro) that a customer either has or doesn't. Entitlements are normally driven by validated purchases, but you can also grant them directly — for promotions, customer support, cross-platform access, or migrating existing subscribers.

Entitlement state lives on the customer object: reading a customer tells you which entitlements are active. This page covers granting an entitlement to a specific customer.

The entitlement object#

idstring

The entitlement identifier, e.g. pro.

is_activeboolean

Whether the entitlement currently grants access.

product_idstring

The product that granted the entitlement, or null for a manual grant.

expires_atstring

ISO 8601 expiry, or null for a non-expiring grant.

storestring

The source of the entitlement, e.g. app_store, play_store, or promo for a manual grant.

Grant an entitlement#

POST /v1/apps/{app}/customers/{app_user_id}/entitlements

Grants an entitlement to a customer. If the entitlement is already active, its expiry is extended to the later of the current and requested expires_at.

appstringrequired

The app ID.

app_user_idstringrequired

The customer's app_user_id, e.g. u_812.

entitlementstringrequired

The entitlement ID to grant, e.g. pro. Must exist in the catalog.

expires_atstring

ISO 8601 expiry for the grant. Omit for a non-expiring (lifetime) grant.

bash
curl -X POST \
  https://api.cashsdk.com/v1/apps/app_2mK4pQ/customers/u_812/entitlements \
  -H "Authorization: Bearer csk_sk_..." \
  -H "Content-Type: application/json" \
  -d '{ "entitlement": "pro", "expires_at": "2026-12-31T23:59:59Z" }'
json
{
  "id": "pro",
  "is_active": true,
  "product_id": null,
  "expires_at": "2026-12-31T23:59:59Z",
  "store": "promo"
}

Granting an entitlement unlocks paid features without a store purchase. It does not create a subscription in the App Store or Google Play and will not renew or bill automatically.

Next steps#