Authentication
All Claradb API requests require authentication via a Bearer token.
Creating an API key
- Sign in to your workspace.
- Navigate to Settings > API Keys.
- Click Create Key and give it a descriptive name.
- Copy the key immediately — it won't be shown again.
Using your key
Include the key in the Authorization header of every request:
Terminal
curl -H "Authorization: Bearer cdb_live_YOUR_KEY" \
https://claradb.com/api/v1/companies
Key prefixes
| Prefix | Environment |
|---|---|
cdb_live_ | Production |
cdb_test_ | Development/testing |
Test keys return the same data but don't count against your production rate limits.
Security best practices
- Never commit API keys to version control.
- Use environment variables to store keys in your application.
- Rotate keys periodically from the workspace settings.
- Use test keys during development.