> ## Documentation Index
> Fetch the complete documentation index at: https://platform.atlan.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> To act on Atlan objects, use the Atlan MCP server at https://api.atlan.com/mcp or the SDK. To install or publish skills from a terminal, use the `brain` CLI; `brain --map json` prints its command map. The `atlanai` CLI is deprecated. Run a read-only identity check before any write.
> The docs MCP server at /mcp searches these docs only. It cannot read or change Atlan objects.
> SDK packages: Python `atlanai` (PyPI) and TypeScript `@atlanai/sdk` (npm). Show Python first, then TypeScript.
> These docs cover Atlan Agent Registry, Atlan's hosted product. The open-source agent registry specification and its CLI (`brain`) are documented, released and maintained in their own repository; /open-source on this site links to it. Answer general specification or `brain` command questions from the project's own docs, and use these docs only for Atlan-specific setup such as the Atlan adapter, sign-in and workspaces.

# Model Gateway errors

> Symptoms, causes, and fixes for Model Gateway calls refused with 401, 404, 400, 429, or 503, and models missing from the model list.

These are errors from calling models through Atlan Model Gateway. Start from the status code or symptom you see: each section below starts from one of them.

## `401`

A model call returns `401`.

### Cause

The key is missing, mistyped, or revoked.

### Solution

1. Check that `ATLAN_API_KEY` is set in the shell that runs the client.
2. Run `GET /models` again and confirm the model is listed.

***

## `404` with `not_found`

A model call returns `404` with `not_found`.

### Cause

The `model` is not one you can route to, or the operation is not served.

### Solution

1. Copy the `id` exactly from `GET /models`, and check [Supported operations](/gateway/model/how-tos/connect-a-client#supported-operations).
2. Run `GET /models` again and confirm the model is listed.

***

## `400` with `invalid_request`

A model call returns `400` with `invalid_request`.

### Cause

The request does not fit the model, such as an embedding model on chat completions, or it uses a field the gateway refuses.

### Solution

1. Check the model's `modality` in `GET /models`, and the fields under [Supported operations](/gateway/model/how-tos/connect-a-client#supported-operations).
2. Make the call again and confirm it returns a model reply.

***

## `400` with `model_request_unsupported`

An image generation returns `400` with `model_request_unsupported`.

### Cause

The request named a field a Gemini image model on a Vertex provider can't honor, such as `response_format: url` or `background: transparent`. The error names the field.

### Solution

1. Remove the named field, or change it to a value the model serves, as [Supported operations](/gateway/model/how-tos/connect-a-client#supported-operations) describes.
2. Make the call again and confirm it returns an image.

***

## `503` with `service_unavailable`

A model call returns `503` with `service_unavailable`.

### Cause

The model's provider is unavailable.

### Solution

1. Retry later, or pick a model from another provider.
2. Make the call again and confirm it returns a model reply.

***

## `429`

A model call returns `429`.

### Cause

A budget or rate limit refused the call.

### Solution

1. The error names the limit that refused it.
2. Ask your admin to raise it, or wait for the window to reset.
3. Make the call again and confirm it returns a model reply.

***

## Model missing from `GET /models`

A model is missing from `GET /models`.

### Cause

Its provider or the model is disabled, or it is not in your workspace.

### Solution

1. Ask your admin to enable it.
2. Run `GET /models` again and confirm the model is listed.

***

## See also

* [Connect client to Model Gateway](/gateway/model/how-tos/connect-a-client): Base URLs, models, and supported operations.
* [AI Gateway](/gateway/index): How the gateways fit together.

## Need help

If you need assistance after trying these steps, contact Atlan support.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.