# Creative Lab model catalog

Source: [Creative Lab model catalog](<https://docs.gptunnel.ru/en/creative-lab/models/>)

<a id="_top"></a>
> **Note: Authentication**
>
> You need an API key to send requests. See [Quick start](<https://docs.gptunnel.ru/en/>)

<a id="request-for-model-list"></a>
## Request for model list

`GET https://gptunnel.ru/api/v2/media/models`

Returns the models available to your API key, filtered by the key’s allowed-model list when configured. Each entry includes a parameter schema (`params`), an input file schema (`inputs`) and pricing. Use the current schemas to see which parameters and inputs a model accepts.

For speech synthesis models, get allowed `voice` values from the separate [voice catalog](<https://docs.gptunnel.ru/en/creative-lab/voices/>).

### Query parameters

| Parameter | Type | Description |
| --- | --- | --- |
| `type` | `string` | Model type filter (e.g. IMAGE, VIDEO, MUSIC or 3D) |

The API ignores unrecognized query parameters, including `_`, `page` and `limit`. Use the documented filters to select models.

<a id="example-request"></a>
### Example request

Set the `GPTUNNEL_API_KEY` environment variable.

<a id="tab-panel-0-0"></a>
**Python**

```python
import json
import os
from urllib.request import Request, urlopen

url = 'https://gptunnel.ru/api/v2/media/models'
request = Request(url, headers={'Authorization': os.environ['GPTUNNEL_API_KEY']})
with urlopen(request, timeout=30) as response:
    print(json.load(response)['models'])
```

<a id="tab-panel-0-1"></a>
**cURL**

```bash
curl --fail-with-body 'https://gptunnel.ru/api/v2/media/models' \
  --header "Authorization: ${GPTUNNEL_API_KEY:?Set GPTUNNEL_API_KEY}"
```

<a id="tab-panel-0-2"></a>
**JavaScript (Node.js)**

```javascript
const key = process.env.GPTUNNEL_API_KEY
if (!key) throw new Error('Set GPTUNNEL_API_KEY')
const response = await fetch('https://gptunnel.ru/api/v2/media/models', { headers: { Authorization: key } })
if (!response.ok) throw new Error(await response.text())
const data = await response.json()
console.log(data.models)
```

<a id="example-response"></a>
### Example response

This excerpt for `kling-v3` shows one entry from `params`. Before creating a task, read the complete parameter and input-role schemas from the catalog. The `label` may contain a localization key. In requests, use the parameter’s `key` and the selected option’s `value`.

```json
{
  "code": 0,
  "models": [
    {
      "id": "kling-v3",
      "type": "VIDEO",
      "prompt": "required",
      "params": [
        {
          "key": "resolution",
          "type": "enum",
          "label": "wfc_param_quality",
          "options": [
            {
              "value": "720p",
              "label": "720P"
            },
            {
              "value": "1080p",
              "label": "1080P"
            }
          ],
          "default": "1080p"
        }
      ]
    }
  ]
}
```

<a id="model-fields"></a>
### Model Fields

| Parameter | Type | Description |
| --- | --- | --- |
| `id` (required) | `string` | Model ID to send in the model field when creating a task. |
| `type` | `string` | Output type: IMAGE, VIDEO, MUSIC, or 3D. MUSIC covers speech synthesis and music generation. |
| `price` (required) | `number` | Discounted rate in RUB for the unit in price\_unit. per\_generation is a rate for one generation. Rates per\_second, per\_megapixel, and per\_1k\_tokens are multiplied by duration, area, or token count. Use /media/price to quote a task. Input-billed models return 0 and omit price\_unit. |
| `price_unit` | `string` | The unit used to calculate price: per\_generation (one generation), per\_second (one second of output), per\_megapixel (one megapixel of output), or per\_1k\_tokens (1,000 output tokens). The list may grow. If this field is absent, use price\_input to find the rate for the input. |
| `price_input` | `number` | Discounted rate in RUB for models billed on input, such as prompt characters, prompt tokens, or megapixels of attached images. See price\_input\_unit for the billing unit. |
| `price_input_unit` | `string` | Unit billed in price\_input: per\_character, per\_1k\_characters, per\_token, per\_1k\_tokens, or per\_megapixel. This list may expand. See the note below. If the field is absent, input is not a separate charge |
| `discount_percent` | `number` | Percentage discount already included in price and price\_input for the same parameters. For input-billed models, price is 0 and the discount appears in price\_input. This field is omitted if there is no discount. |
| `pricing` | `object` | Rules for calculating the base price from model parameters, before any discounts. Available for some models. |
| `prompt` (required) | `string` | Prompt requirement: required, optional, or none. |
| `max_length` | `number` | Maximum prompt length in characters, based on the model’s available routes. |
| `max_bytes` | `number` | Maximum prompt text size in UTF-8 bytes, taking into account available model routes. |
| `prompt_optional_when` | `object` | Conditions for omitting prompt. For Suno, both is\_custom and instrumental must be true. |
| `params` (required) | `array` | Schema for configurable generation parameters, including each parameter’s key, type, allowed values, and default. |
| `inputs` | `array` | Input file schema with roles, supported formats, file counts, and limits. |
| `deprecated` | `boolean` | true means the model has reached its retirement date. Requests use a replacement or return HTTP 410. While false, the model operates normally. |
| `deprecated_at` | `string` | The model’s retirement date and time in ISO 8601 format. A future date gives advance notice. The model remains available until then. |
| `deprecation_redirect_to` | `string \| null` | Replacement model ID used after retirement. The originally requested model’s rate applies. null means no replacement, so task creation returns HTTP 410 after retirement. |

<a id="prompt-length"></a>
### Prompt length

Check the model’s `max_length` and `max_bytes` fields alongside `prompt`. An omitted field means the model catalog declares no limit for that unit. If both fields are present, the prompt must satisfy both limits. For a model with multiple routes, the API reports the maximum for each unit separately. An individual provider may enforce a stricter combination of the two limits.

Once a model reaches its retirement date and a replacement takes over, `prompt`, `max_length`, and `max_bytes` describe the replacement model’s requirements. The original model’s requirements apply while it still handles requests.

With `max_bytes: 4096`, a prompt can contain 2,048 copies of the Cyrillic letter “я”, which takes two bytes in UTF-8. Price quotes and task creation enforce the same byte limit. With 2,049 copies, the API returns HTTP 400 with `code: 3` and the following `details` array.

```json
[{ "key": "prompt", "message": "prompt is too long, max 4096 bytes (got 4098)" }]
```

> **Tip: Calculate the cost before creating a task**
>
> Send the task’s `model`, `prompt`, `params`, and `inputs` to the [price quote endpoint](<https://docs.gptunnel.ru/en/creative-lab/price/>). The quote accounts for parameters and discounts without starting a generation or charging your balance. For models billed on file metrics, the quote may be an estimate. See the price quote page for details.

> **Caution: How to interpret a zero price**
>
> A model billed on input has no output rate. The response contains `price: 0` and omits `price_unit`. Read the input rate and its unit in `price_input` and `price_input_unit`.
>
>
>
> For example, `tts2` with `price_input: 0.06` and `price_input_unit: "per_character"` costs 0.06 RUB per prompt character. A prompt with 26 characters costs 1.56 RUB.
>
>
>
> ```json
> {
>   "id": "tts2",
>   "type": "MUSIC",
>   "price": 0,
>   "price_input": 0.06,
>   "price_input_unit": "per_character",
>   "prompt": "required"
> }
> ```
>
>
>
> When `price: 0` comes with `price_unit`, the output rate is zero. When `price_unit` is absent, use `price_input` for the input rate.
>
>
>
> Compare rates together with their units. Some voices have their own rate per 1,000 characters in the [voice catalog](<https://docs.gptunnel.ru/en/creative-lab/voices/>), under `price_per_1k_chars`. When the selected voice has this rate, the task uses it instead of the model’s `price_input`.

> **Note: The catalog may return new price units**
>
> New models may introduce values for `price_unit` or `price_input_unit`. If you encounter an unfamiliar unit, [request a price quote](<https://docs.gptunnel.ru/en/creative-lab/price/>). Compare rates for the same unit.

> **Note: Model retirement fields appear together**
>
> The response includes `deprecated`, `deprecated_at`, and `deprecation_redirect_to` together for models with announced retirement. Other models omit these fields.

Example of a model with an announced retirement date.

```json
{
  "id": "kling-v2",
  "code": "kling-v2",
  "type": "VIDEO",
  "price": 210,
  "deprecated": false,
  "deprecated_at": "2026-09-01T00:00:00.000Z",
  "deprecation_redirect_to": "kling-v3"
}
```

> **Caution: After a model retires**
>
> After the date in `deprecated_at`, tasks run on the model in `deprecation_redirect_to`. The response headers indicate the replacement. If no replacement is listed, task creation returns `410` with `code: 21`. See the [error reference](<https://docs.gptunnel.ru/en/creative-lab/errors/>) and [deprecated models](<https://docs.gptunnel.ru/en/getting-started/deprecated-models/>).

> **Note: Fixed model parameters**
>
> The `params` schema lists parameters that clients can set. Some models also apply fixed values.
>
>
>
> Fixed parameters are not listed in the schema. They apply to each generation and appear in the `params` returned by the [price endpoint](<https://docs.gptunnel.ru/en/creative-lab/price/>) and [task result](<https://docs.gptunnel.ru/en/creative-lab/get-task/>). A request that supplies a value for a fixed parameter still runs. The API ignores the supplied value.
