API Keys
All requests to the /v1/agent/lookup endpoint require a valid API key passed via the Authorization header using the Bearer scheme.
Authorization: Bearer YOUR_API_KEY
Creating a key
- Go to encrata.com/api-keys
- Click Create Key
- Copy the key — it’s only shown once
Key behavior
| Behavior | Detail |
|---|
| Format | Opaque string |
| Scope | Tied to your user account |
| Revocation | Instant — revoked keys are rejected immediately |
| Usage tracking | Every request is logged with credits consumed and response time |
Error responses
If authentication fails, the API returns:
{
"c": 401,
"m": "bad key"
}
Keep your API key secret. Do not commit it to version control or expose it in client-side code.