Authentication
API key management, environments, and security
All authenticated API requests require a Bearer token in the Authorization header.
Keys follow the pattern {prefix}{32_random_chars}:
Keys are environment-scoped. A pai_test_* key will return 401 Unauthorized on the production API, and vice versa.
expires_at date (if one was set).When you rotate a key, a new key is generated and the old key enters a 24-hour grace period during which both keys are accepted. This allows you to update your integration without downtime.
The new key plaintext is shown only once at creation. Store it securely — it cannot be retrieved later.
After creation, keys are displayed as a fingerprint: pai_live_...a3f9. This is safe to use in logs and support tickets. Never log the full key.
pai_test_* keys for development and CI pipelineslast_used_at timestamp — unused keys should be reviewed