4e064cf81dae

latestOpenAPI 3.1.02026-08-131831,331960.0 KB
models

Replace a custom model

Replace editable fields for a custom model. The model_name path value remains the identifier.

put/api/models/{model_name}/

Path parameters

model_namestring required

Model name. The route supports names containing slashes, such as openai/gpt-4o-mini.

Headers

Authorizationstring required

Use your Respan API key for Respan API authentication. Enter only the Respan API key value; clients send Authorization: Bearer <RESPAN_API_KEY>. For /api/responses, provider credentials such as Perplexity, OpenAI, or Azure OpenAI go in Settings -> Providers or respan_params.credential_override in the request body, not in this authentication field.

Request body

base_model_namestring

Base model to inherit properties from.

display_namestring

Human-readable display name.

custom_provider_idstring

Custom provider string ID or provider identifier to associate.

provider_idstring

Alternative to custom_provider_id.

input_costnumber double

Cost per 1M input tokens in USD.

output_costnumber double

Cost per 1M output tokens in USD.

cache_hit_input_costnumber double

Cost per 1M cached input tokens in USD.

cache_creation_input_costnumber double

Cost per 1M cache creation input tokens in USD.

max_context_windowinteger

Maximum context window size.

streaming_support'0' | '1'
function_call'0' | '1'
image_support'0' | '1'
supported_params_overrideobject

Partial override for model parameter support. The response returns computed supported_params.

Response

Updated model.

idstring required

Model string ID. Same value as model_name.

model_namestring required

Model name used in API calls.

display_namestring

Human-readable model name.

base_model_namestring

Base model inherited from, when configured.

affiliation_category'respan' | 'custom'

Whether the model is built in or organization-specific.

is_called_by_custom_nameboolean

Whether requests are sent upstream using this custom model name.

input_costnumber double

Cost per 1M input tokens in USD.

output_costnumber double

Cost per 1M output tokens in USD.

cache_hit_input_costnumber double

Cost per 1M cached input tokens in USD.

cache_creation_input_costnumber double

Cost per 1M cache creation input tokens in USD.

max_context_windowinteger

Maximum context window size.

streaming_support'0' | '1'

Streaming support. 0 = no, 1 = yes.

function_call'0' | '1'

Function/tool calling support. 0 = no, 1 = yes.

image_support'0' | '1'

Vision input support. 0 = no, 1 = yes.

source'db' | 'hardcoded'

Source of the model definition.

model_type'chat' | 'embedding' | 'audio'

Model type.

supported_paramsobject

Computed parameter support after applying model-specific overrides.

created_atstring date-time nullable
updated_atstring date-time nullable