Authentication
The Operate API uses API key authentication. Every request must include a valid API key in thex-api-key header.
How it works
Obtaining an API key
- Log in to the Operate dashboard
- Go to Settings > API Keys
- Click Create API Key and copy the generated key
Using the API key
Include thex-api-key header with every request:
Error responses
| Status | Meaning |
|---|---|
400 | Missing x-api-key header |
401 | Invalid or expired API key |
403 | API key does not have access to the requested resource |
Best practices
Store keys in environment variables
Store keys in environment variables
Never hardcode API keys in source code. Use environment variables or a
secrets manager like AWS Secrets Manager, Doppler, or Infisical.
Use server-side requests only
Use server-side requests only
API keys should only be used in server-side code. Never expose them in
client-side JavaScript, mobile apps, or public repositories.
Rotate keys periodically
Rotate keys periodically
Generate new API keys and revoke old ones on a regular schedule to limit
exposure from potential leaks.