Palbase IAP · API
/iap/meRead what the customer has
Everything the signed-in customer has, whatever store they bought in: each entitlement (whether it is on, until when, whether it renews, which store gives it, every source), their subscriptions and one-time purchases, credit balances and quota use. The first read makes the user a customer. A store's test purchases open entitlements as the project's sandbox setting says. The ETag is the customer's revision. The customer's apps join the realtime channel purchases:<project ref>:<user id> — theirs alone, read-only — whose state and changed broadcast carry {"revision": N}: a revision above the one read means reading GET /iap/me again.
Called by a signed-in user of your app, with their token and the publishable key.
curl -X GET "https://<your-ref>.palbase.studio/iap/me" \
-H "apikey: $PALBASE_PUBLISHABLE_KEY" \
-H "authorization: Bearer $USER_ACCESS_TOKEN"Responses
200What the customer has
400The request is malformed, or a field breaks a rule (the error names which)
401No customer's session (`session_required`): a customer's own is reached with the publishable key and their access token; or the edge refused the key or token
404The user's id is longer than a customer's (128 characters; `customer_not_found`)
409This guest's purchases went to the account it signed in to (`customer_merged`): read with the account's session
410The user was deleted (`customer_erased`): their id is no customer's again
429Over the project's request limit; Retry-After says when to try again
503Another change to this customer is in progress (`customer_busy`), or the platform could not answer now; retrying is safe after Retry-After
defaultAn error: the envelope names it (`error`) and explains it (`error_description`).
Operation GetMyCustomerInfo of iap's contract.