opendunes
Catalogue
Copy page ▾

One model's providers

GET /v1/models/{lab}/{model}/endpoints lists the providers serving one model, each with its prices in DADAThe Algerian dinar, the one currency the docs show.More on Balance and charges →, its limits and how it has been running.

Request

Send it with an API keyAPI keyThe key you create and send with every request that calls a model.More on API keys →. The two fields go in the address: the model's ID, lab/model, split at its slash. The Models guide says where to copy it.

FieldNeededYou send
labyesthe lab's part of the model's ID: anthropic in anthropic/claude-sonnet-4.5
modelyesthe model's part: claude-sonnet-4.5

A picture model answers the same question in the picture routes' own terms at GET /v1/images/models/{lab}/{model}/endpoints, below.

import json
import os
import urllib.request

API_KEY = os.environ["OPENDUNES_API_KEY"]
MODEL = "anthropic/claude-sonnet-4.5"
ADDRESS = f"https://opendunes.com/v1/models/{MODEL}/endpoints"

request = urllib.request.Request(
    ADDRESS,
    headers={"Authorization": "Bearer " + API_KEY},
)
with urllib.request.urlopen(request) as response:
    model = json.load(response)["data"]

for endpoint in model["endpoints"]:
    print(
        endpoint["provider_name"],
        endpoint["context_length"],
        endpoint["pricing"]["prompt"],
    )

Response

200 OK.

FieldHolds
datathe model, and its providers
id · name · created · description · architecturethe model, as One model answers it
endpointsone entry per provider serving it

Each entry in endpoints holds:

FieldHolds
namethe provider and the model it serves there
model_idthe model's ID fixed to one release
model_namethe model's name on this provider's list
provider_namethe provider
tagthe provider's tag: send it in provider.only or provider.order to pick this entry
context_lengththe most tokens a request and its answer hold together here
max_completion_tokensthe longest answer, in tokens, or null
max_prompt_tokensthe longest prompt, in tokens, or null
pricingthis provider's prices in DA, one per meter, each a string per unit of that meter: prompt and completion per token, image per picture sent, request per request, and the rest the model has. Beside them, discount, where this provider runs a promotion: 0.5 for half off, already inside those prices
quantizationthe precision the model runs at here, such as fp8, or unknown
supported_parametersthe request fields this provider honours
supports_tool_choicewhich tool_choice values it honours: none, auto, required, function, each true or false
supports_implicit_cachingtrue when it caches a repeated prompt without being asked
status0 when it is serving normally; below 0, degraded or down
uptime_last_5m · uptime_last_30m · uptime_last_1dthe share of its requests that succeeded, in percent, or null
latency_last_30mtime to the first token, in milliseconds, at p50, p75, p90 and p99, or null
throughput_last_30mtokens per second, at the same four points, or null
perf_last_30m_by_workloadthe same readings, split by the kind of request served, such as text_generation or embeddings

A picture model. GET /v1/images/models/{lab}/{model}/endpoints answers data with the model's id and its endpoints, and a 404 for a model that does not make pictures. Each entry holds:

FieldHolds
provider_namethe provider
provider_slugthe provider's short name
provider_tagits tag, to pick this entry in provider
supports_streamingtrue when it streams a picture as it is made
supported_parametersthe request fields it honours, each with its type and the values it takes
allowed_passthrough_parametersthe provider's own settings it accepts, under provider
billablein each line of pricing: what is counted, such as output_image or input_image
unitin each line: the unit it is counted in: request, image, megapixel or token
variantin each line, where there is one: which kind of that output the line prices
costin each line: the price per unit, in DA, as a string
discountin each line: the promotion already inside cost, 0.5 for half off, 0 when there is none

What it cost

Free. Reading the catalogue is never charged.

Errors

error.code carries the status, and error.message says why.

StatusWhen
401the key is missing, wrong, disabled or expired
403the key answers only from the addresses set on it, and this request came from another
404the model is not on sale; on the picture route, or it does not make pictures
503the providers could not be read just now; Retry-After says how many seconds to wait

Last modified on