Authorization header.
Key prefixes
| Prefix | Environment |
|---|---|
aigen_test_ | Sandbox |
aigen_live_ | Live |
Required headers
Create requests should include:X-Request-Id for log correlation:
request_id in API responses. Use it when investigating failures with support or correlating API responses, logs, and webhook events.
Key handling
- Store API keys in a secret manager or encrypted environment variable.
- Give each integration environment its own key.
- Rotate keys when a deployment, vendor, or team access changes.
- Revoke or delete keys that should no longer authenticate.
- Never ask merchants or frontend clients to call the API directly with your key.
Authentication errors
| HTTP status | Error code | Meaning |
|---|---|---|
401 | invalid_api_key | The key is missing, malformed, revoked, deleted, or unknown. |
401 | api_key_expired | The key expiration date has passed. |
401 | api_key_inactive | The key was deactivated from the dashboard. |
403 | api_access_not_enabled | The account is not eligible for live API processing. |
