Skip to content

API Reference

The xQR API lets you manage links, QR codes, analytics, assets, and workspaces programmatically. Every endpoint documented in this reference is available to Pro plan accounts and above.

Base URL

All API requests are made to:

https://xqr.co/api/v1

A machine-readable OpenAPI 3.1 specification is also available for import into Postman, Insomnia, or code generators.

Authentication

Authenticate every request by sending your API key in the Authorization header:

Authorization: Bearer xqr_pk_a1b2c3d4.xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

API keys are scoped. Each endpoint requires a specific scope (e.g. links:read, qr:render). If the key does not include the required scope, the API returns 403 Forbidden.

Create and manage keys in Settings → Developers in the xQR dashboard.

Content Type

All request and response bodies use JSON. Set the Content-Type header on every request that includes a body:

Content-Type: application/json

The only exception is the QR render endpoint, which returns binary image data (image/svg+xml or image/png).

Response Envelope

Every JSON response is wrapped in a standard envelope:

{
"data": { ... },
"meta": {
"request_id": "req_8f3a2b1c4d5e6f70",
"rate_limit": {
"limit": 600,
"remaining": 594,
"reset": 1742572800
}
}
}
FieldTypeDescription
dataobject | arrayThe requested resource or collection.
meta.request_idstringUnique identifier for the request, useful for support tickets.
meta.rate_limit.limitnumberMaximum requests allowed in the current window.
meta.rate_limit.remainingnumberRequests remaining before throttling.
meta.rate_limit.resetnumberUnix timestamp (seconds) when the window resets.

Error responses follow the same envelope but replace data with an error object. See Error Handling for details.

Pagination

List endpoints accept two query parameters:

ParameterTypeDefaultDescription
limitinteger50Number of items to return (1 – 200).
offsetinteger0Number of items to skip.

The response meta includes pagination info when applicable:

{
"data": [ ... ],
"meta": {
"request_id": "req_8f3a2b1c4d5e6f70",
"total": 342,
"limit": 50,
"offset": 100,
"rate_limit": { ... }
}
}

Rate Limits

Default rate limits are 600 requests per minute per API key. The current usage is returned in every response via meta.rate_limit. When the limit is exceeded, the API returns 429 Too Many Requests with a Retry-After header.

See Rate Limits for plan-specific quotas and best practices.

Was this page helpful?