Authentication
All model endpoints authenticate with an API key.
Recommended header
http
Authorization: Bearer $MODELGO_API_KEY
Content-Type: application/jsonAnthropic-style clients may also use:
http
x-api-key: $MODELGO_API_KEY
Content-Type: application/jsonGemini-style clients may also use:
http
x-goog-api-key: $MODELGO_API_KEY
Content-Type: application/jsonWhen several are present, precedence is Authorization > x-api-key > x-goog-api-key.
Get & manage
- Console:
https://console.modelgo.ai - An API key is shown in full only once, at creation time
- Revoking or disabling a key takes effect after the auth cache expires
Common failures
| HTTP | error_class | Meaning |
|---|---|---|
401 | auth | Missing, invalid, disabled, or expired API key |
403 | policy | Key is valid but not allowed to call the model |
See Errors & Rate Limits for the unified error shape.