---
title: "Create Model Alias"
method: POST
path: "/models/aliases"
tags: ["models"]
---

# Create Model Alias

`POST /models/aliases`

Create a model alias with fallback models for the organization that owns the API key.

A model alias allows you to define a name that resolves to an ordered list of fallback models.
For example, you could create an alias called "sonnet-4" that falls back to
["anthropic/claude-3-5-sonnet-latest", "anthropic/claude-3-5-sonnet-20241022"].

## Request body

- CreateModelAliasRequest
  - `name` string, required — The name of the model alias
  - `fallback_models` string[], required — Ordered list of model names to try as fallbacks
  - `description` string, nullable — Optional description of the model alias
  - `options` ModelAliasOptions
    - `first_token_timeout_ms` integer, nullable — First-token failover guard. If a streaming call to an alias member produces no output within this many milliseconds, the gateway abandons it and fails over to the next fallback model — rescuing provider queueing stalls that never surface as errors. Disarmed after the first token, so long responses are never cut. Recommended: 5000-15000. Omit or null to disable.

## Response `200`

Successful Response

- CreateModelAliasResponse
  - `id` string, uuid, required — The ID of the model alias
  - `name` string, required — The name of the model alias
  - `fallback_models` string[], required — Ordered list of model names to try as fallbacks
  - `description` string, nullable — Optional description of the model alias
  - `options` ModelAliasOptions
    - `first_token_timeout_ms` integer, nullable — First-token failover guard. If a streaming call to an alias member produces no output within this many milliseconds, the gateway abandons it and fails over to the next fallback model — rescuing provider queueing stalls that never surface as errors. Disarmed after the first token, so long responses are never cut. Recommended: 5000-15000. Omit or null to disable.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `402` — Payment Required (out of credits)
- `404` — Not Found
- `409` — Conflict
- `422` — Request Validation Error

## Changes

- **2026-07-26** `d3ccdaa15678` — 2 info
  - added the new optional request property `options`
  - added the optional property `options` to the response with the `200` status

[Change history](https://skmtc.dev/opper/apis/opper-api-v2/changes/models/aliases/post.md)

---

[API](https://skmtc.dev/opper/apis/opper-api-v2.md) · [All operations](https://skmtc.dev/opper/apis/opper-api-v2/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/opper/opper-api-v2/revisions/d3ccdaa15678/schema)
