---
title: "Discover Models Preview"
method: POST
path: "/v1/provider-configs/discover-preview"
tags: ["v1", "protected", "provider-configs"]
---

# Discover Models Preview

`POST /v1/provider-configs/discover-preview`

Discover models from a provider API using the provided API key, without requiring a saved config.

Not a dry run: the discovered specs, prices included, are persisted so the
caller can pick models by id. That makes it a price write.

## Request body

- DiscoverPreviewRequest
  - `api_key` string, nullable
  - `endpoint_url` string, nullable
  - `provider_key` string, required

## Response `200`

Successful Response

- DiscoverPreviewResponse
  - `discovered` integer, required
  - `models` DiscoverPreviewModelResponse[], required
    - `context_window` integer, required
    - `description` string, nullable
    - `display_name` string, required
    - `id` string, required
    - `input_cost_per_token` string, nullable
    - `is_new` boolean
    - `max_output_tokens` integer, nullable
    - `model_name` string, required
    - `output_cost_per_token` string, nullable
    - `supports_function_calling` boolean
    - `supports_reasoning` boolean
    - `supports_vision` boolean
  - `new_models` integer, required
  - `skipped` SkippedModelResponse[]
    - `missing` string[], required
    - `model_name` string, required

## Other responses

- `422` — Validation Error

## Changes

- **2026-09-25** `86958030d9bc` — 4 breaking
  - response property `models/items/input_cost_per_token` list-of-types was widened by adding types `string` to media type `application/json` of response `200`
  - response property `models/items/output_cost_per_token` list-of-types was widened by adding types `string` to media type `application/json` of response `200`
  - the `models/items/input_cost_per_token/anyOf[subschema #1]/` response's property type changed from `number` to `string` for status `200`
  - the `models/items/output_cost_per_token/anyOf[subschema #1]/` response's property type changed from `number` to `string` for status `200`
- **2026-09-07** `ceb9610bbb79` — 1 info
  - added the optional property `skipped` to the response with the `200` status
- **2026-07-30** `ce40e8663ec3` — 3 breaking, 3 info
  - response property `models/items/input_cost_per_token` list-of-types was widened by adding types `null` to media type `application/json` of response `200`
  - response property `models/items/max_output_tokens` list-of-types was widened by adding types `null` to media type `application/json` of response `200`
  - response property `models/items/output_cost_per_token` list-of-types was widened by adding types `null` to media type `application/json` of response `200`
  - the `input_cost_per_token` response's property default value `0` was removed for the status `200`
  - …2 more
- …earlier changes not shown

[Full history](https://skmtc.dev/agentarea/apis/agentarea-api/changes/v1/provider-configs/discover-preview/post.md)

---

[API](https://skmtc.dev/agentarea/apis/agentarea-api.md) · [All operations](https://skmtc.dev/agentarea/apis/agentarea-api/llms.txt) · [OpenAPI document](https://skmtc.dev/agentarea/apis/agentarea-api/revisions/ebd031ab895b?raw)
