unauthorized
HTTP 401 · Unauthorized
What happened. The key was not accepted. This one answer covers every reason on purpose: a missing or mistyped key, a key that was revoked or rolled, a connection that was removed or paused, a shop that cannot use the API, a key without the scope the route needs, or a request from an address outside the connection’s allowlist. The answer never says which, so a stolen key teaches nothing.
What to do. Check that the header is Authorization: Bearer psk_live_… (or psk_test_… on a test shop) with the whole key, that the key is still listed in the portal under Settings → Integrations, and that its connection has the scope the route names. Do not retry in a loop.
Returned by
Section titled “Returned by”- The shop’s live cards —
GET /programs - A card’s type, rules, rewards and join form —
GET /programs/{id} - The shop’s branches —
GET /branches - Sign a customer up —
POST /enrolments - A fresh claim link for a card never in a wallet —
POST /cards/{id}/claim-link - Attach or change the integration’s customer id —
PUT /customers/{id}/external-id - Link a card made at an outlet to a store account —
POST /cards/link - Find a card by serial, card ID, phone, email or external id —
POST /cards/lookup - A card’s balance, rewards, tier, dates, status and whether it is in a wallet —
GET /cards/{id} - A card’s history —
GET /cards/{id}/transactions - Give value for a sale —
POST /awards - Refund or void an award, in full or in part —
POST /awards/{reference}/reverse - Spend value now —
POST /redemptions - Reserve value against an online order —
POST /redemption-holds - Spend what a hold reserved —
POST /redemption-holds/{id}/confirm - Free what a hold reserved —
POST /redemption-holds/{id}/release - The event feed —
GET /events - This connection’s webhook endpoints —
GET /webhook-endpoints - Add a webhook endpoint —
POST /webhook-endpoints - A webhook endpoint —
GET /webhook-endpoints/{id} - Change, switch off or switch back on a webhook endpoint —
PATCH /webhook-endpoints/{id} - Remove a webhook endpoint —
DELETE /webhook-endpoints/{id} - Send a webhook.test event to the endpoint —
POST /webhook-endpoints/{id}/test - Roll the endpoint’s signing secret —
POST /webhook-endpoints/{id}/roll-secret
The answer
Section titled “The answer”Errors are Problem Details, served as application/problem+json, with "code": "unauthorized" and "type": "https://passkaar.com/developers/errors/unauthorized", which opens this page on docs.passkaar.com.