lollipayDocs

Permissions

Scope each API key to the resources and actions it needs. A key without the right permission gets 403.

Every key holds a set of permissions, chosen when you create it and editable later from the key's menu in Dashboard → Developers → API keys. Each endpoint in the API reference lists the permission it needs.

  • Write includes read. Granting checkouts:write also grants checkouts:read.
  • Changes apply to the next request. You don't need a new secret after editing a key's permissions.
  • New keys get the Checkouts permissions unless you change them, which covers everything the API does today.

Scopes

ResourcePermissionsCovers
Checkoutscheckouts:read, checkouts:writeCreate and retrieve hosted checkout sessions. In the API now.
Paymentspayments:readPayment history, statuses and fees.
Refundsrefunds:read, refunds:writeRefund records and issuing refunds.
Customerscustomers:read, customers:writeBuyer profiles and their purchase history.
Productsproducts:read, products:writeCatalog, prices and inventory.
Subscriptionssubscriptions:read, subscriptions:writePlans, renewals and cancellations.
Payoutspayouts:readBalances and payout schedule.
Webhookswebhooks:read, webhooks:writeEndpoints and delivery logs.
Analyticsanalytics:readRevenue, conversion and reports.

Scopes other than Checkouts take effect as their endpoints launch, so a key you scope today keeps working without edits.

Missing permissions

A valid key without the permission an endpoint needs gets 403:

403 Forbidden
{
  "ok": false,
  "error": {
    "code": "forbidden",
    "message": "This API key doesn't have the checkouts:write permission. Add it in Dashboard → Developers → API keys."
  }
}

Choosing scopes

  • A server that only sells: checkouts:write.
  • A job that only checks orders: checkouts:read, so a leak can't create sessions.
  • Separate keys per service, each with the smallest set that works, so you can revoke one without touching the rest.

On this page