# Models (/docs/entwickler/models)

> List the models the API offers, check which endpoints each one supports, and choose models by their security level.

`GET /v1/ai/models` lists the models available through the API, in catalogue order. Send an entry's `id` as `model`.

## Example

**curl**

```bash
curl https://api.peakprivacy.ch/v1/ai/models \
  -H "Authorization: Bearer $PEAKPRIVACY_API_KEY" \
  -H "Accept: application/json"
```

**Python**

```python
import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.peakprivacy.ch/v1/ai",
    api_key=os.environ["PEAKPRIVACY_API_KEY"],
)

for model in client.models.list():
    print(model.id)
```

**JavaScript**

```js
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://api.peakprivacy.ch/v1/ai",
  apiKey: process.env.PEAKPRIVACY_API_KEY,
});

for await (const model of client.models.list()) {
  console.log(model.id);
}
```

## Response
```json
{
  "object": "list",
  "data": [
    {
      "id": "deepseek-v4-flash",
      "object": "model",
      "created": 0,
      "owned_by": "...",
      "max_tokens": 1000000,
      "security_levels": { "with_anon": 1, "without_anon": 1 },
      "meta": {
        "capabilities": { "vision": false, "chat_completions": true, "responses": true },
        "recommended": false,
        "is_new": false,
        "description": "..."
      },
      "info": { "meta": { "...": "..." } }
    }
  ],
  "catalog_policy": { "version": 1, "default_model_id": "deepseek-v4-flash", "default_status": "available" }
}
```

| Field | Type | Description |
|---|---|---|
| `id` | string | The value to send as `model`. |
| `owned_by` | string | Provider label from the catalogue. |
| `max_tokens` | integer | Upper limit for the answer length. A higher `max_tokens` in a request is reduced to this value. |
| `security_levels` | object | Security level without anonymisation (`without_anon`) and with `"anonymize": true` (`with_anon`). See [Security levels](#tiers). |
| `meta.capabilities` | object | Endpoint support, see [below](#capabilities). `vision` is `true` if the model reads images in messages. Send images only to such a model, see [Choosing a model](/docs/entwickler/choose-a-model#capabilities). |
| `meta.recommended`, `meta.is_new` | boolean | Labels from the catalogue. |
| `meta.description` | string | Short description, if set. `meta` can contain further fields. |
| `info` | object | Copy of `meta` for older clients. Read `meta`. |
| `catalog_policy` | object | The catalogue default set by PeakPrivacy. `default_model_id` is `null` if no default is set (`default_status: "unset"`) or it isn't listed (`"unavailable"`). You still send `model` with every request. |

The list is the same for every API token and changes when PeakPrivacy adds, retires or reconfigures models. Read ids from this endpoint, or check at startup that the ids you use are still listed. An unlisted id returns `400` with `The selected model is invalid.`

## Endpoint support
`meta.capabilities.chat_completions` covers both chat completions paths. `meta.capabilities.responses` covers `/v1/ai/responses`.

| Value | Meaning |
|---|---|
| `true` | Supported. |
| `false` | Not supported. The API returns `400` with code `unsupported_endpoint` before the model is called, also with `"stream": true`. |
| `null` | Not confirmed, for older or custom models. The request is attempted. |

## Security levels
Every model has one of three security levels: [Schweiz], [EU] or [Extern]. [Choosing a model › Security level](/docs/entwickler/choose-a-model#security-level) maps the numbers in `security_levels` to these badges, and [Which data belongs on which level](/docs/sicherheit/sicherheitsstufen#welche-daten) (German) explains what each badge suits.

Check the level before your application sends personal or confidential data. If people choose the model themselves, show them the badge next to the model name.

## Overview
A hand-maintained overview with German labels, taken from the web app. Its notes column ("Hinweis") and its footer describe the chat. Where the table differs from `GET /v1/ai/models`, the endpoint is right.

| Modell | ID | Stufe | Modellfamilie |
|---|---|---|---|
| GPT Swiss | `gpt-swiss` | Schweiz | gpt-oss-120b (OpenAI, Open Weight) |
| DeepSeek V4 Flash | `deepseek-v4-flash` | Schweiz | DeepSeek (Modell dahinter: DeepSeek V4.1 Flash, Vorschau) |
| GLM 5.2 | `glm5` | Schweiz | GLM (Zhipu AI) |
| Mistral Small Swiss | `mistral-small-swiss` | Schweiz | Mistral |
| GPT EU | `gpt-eu` | EU | gpt-oss-120b (OpenAI, Open Weight) |
| Qwen 3 | `qwen-3` | EU | Qwen3 235B (Alibaba) |
| Qwen 3 Fast | `qwen-3-fast` | EU | Qwen3 30B (Alibaba) |
| Gemma 3 | `gemma-3` | EU | Gemma 3 27B (Google, Open Weight) |
| DeepSeek R1 | `deepseek-r1` | EU | DeepSeek (Modell dahinter: DeepSeek V4 Pro) |
| GPT-5 | `gpt-5` | Extern | OpenAI (Modell dahinter: GPT-5.6 Sol bzw. GPT-5.2) |
| GPT-4.1 | `gpt-4.1` | Extern | OpenAI |
| GPT-4o | `gpt-4o` | Extern | OpenAI |
| Claude Opus 5.5 | `claude-opus` | Extern | Anthropic |
| Claude Sonnet 4.6 | `claude-sonnet` | Extern | Anthropic |
| Gemini 3.1 Pro (Preview) | `gemini-3-pro-preview` | Extern | Google |
| Gemini 3.5 Flash | `gemini-3.5-flash` | Extern | Google |

Welche Modelle verfügbar sind, legt die Organisation fest; massgeblich ist die Modellauswahl im Chat bzw. `GET /v1/ai/models`.

## See also
- [Chat completions](/docs/entwickler/chat-completions)
- [Errors and limits](/docs/entwickler/errors#unsupported-endpoint)
- [Security levels](/docs/sicherheit/sicherheitsstufen) (German)
