Skip to content

Authentication

All API requests must include a valid authentication credential. AsyncQueue supports two authentication methods.

API keys are the recommended way to authenticate programmatic access. Include the key in the Authorization header:

Terminal window
curl https://api.asyncqueue.io/v1/tasks \
-H "Authorization: Bearer aq_live_abc123..."
PrefixEnvironment
aq_live_Production
aq_test_Sandbox (tasks are accepted but not executed)

You can create, list, and revoke API keys through the dashboard or the API:

Terminal window
# List keys
curl https://api.asyncqueue.io/v1/apikeys \
-H "Authorization: Bearer YOUR_API_KEY"
# Create a new key
curl -X POST https://api.asyncqueue.io/v1/apikeys \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"name": "production-worker"}'
# Revoke a key
curl -X DELETE https://api.asyncqueue.io/v1/apikeys/key_id \
-H "Authorization: Bearer YOUR_API_KEY"

JWT tokens are used for browser-based dashboard sessions. They are issued through the magic link login flow and expire after 24 hours.

The JWT is included as a Bearer token in the same way as API keys:

Terminal window
Authorization: Bearer eyJhbGciOiJIUzI1NiIs...

All authenticated requests are subject to rate limits based on your plan:

PlanRequests per minute
Free60
Pro600
EnterpriseCustom

Rate-limited responses return 429 Too Many Requests with a Retry-After header.