{"openapi":"3.1.0","info":{"title":"modelschemas","version":"0.1.0","description":"Live AI model schema service: per-endpoint request/response JSON Schemas and model metadata for monitored providers, with stale-while-revalidate caching and a change feed. Anonymous reads are allowed at a low rate limit; register (agent-auth or API key) for higher limits and webhook subscriptions."},"servers":[{"url":"/"}],"paths":{"/v1":{"get":{"operationId":"getServiceIndex","summary":"Service description and endpoint index","responses":{"200":{"description":"Service index with _links to every surface.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/status":{"get":{"operationId":"getStatus","summary":"Per-provider sync status and row counts","parameters":[{"name":"wait","in":"query","description":"Long-poll: hold up to N seconds (cap 60; \"30s\" form accepted) until new data exists, then return current data.","schema":{"type":"string"}}],"responses":{"200":{"description":"Service status.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceStatus"}}}}}}},"/v1/providers":{"get":{"operationId":"listProviders","summary":"List monitored providers with sync status","responses":{"200":{"description":"Providers.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/providers/{provider}/models":{"get":{"operationId":"listProviderModels","summary":"List models for one provider","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}},{"name":"provenance","in":"query","description":"Include recorded per-field sources by default; 0 omits them.","schema":{"type":"string","enum":["0","1"],"default":"1"}}],"responses":{"200":{"description":"Models for the provider.","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/models":{"get":{"operationId":"listModels","summary":"Cross-provider model catalog","description":"The headline \"what can I use right now\" endpoint. Filterable.","parameters":[{"name":"activity","in":"query","schema":{"type":"string","enum":["chat","image","video","audio","embeddings","moderation"]}},{"name":"provider","in":"query","schema":{"type":"string"}},{"name":"capability","in":"query","description":"A capability flag the model is stated to support: matches rows whose capabilities map has this key set to true (capability=tools). Exact flag name, not a substring.","schema":{"type":"string"}},{"name":"q","in":"query","description":"Free-text match against id and display name.","schema":{"type":"string"}},{"name":"provenance","in":"query","description":"Per-field factSources are included by default. Set to 0 to omit them on list rows; 1 explicitly includes them. Model detail always includes factSources and OpenRouter discrepancies.","schema":{"type":"string","enum":["0","1"],"default":"1"}},{"name":"pricing","in":"query","description":"Set to 1 to include the full rate card on each list row. Default is a compact summary: per-million base rates for token cards, otherwise the unit the card bills by.","schema":{"type":"string","enum":["1"]}}],"responses":{"200":{"description":"Matching models. pricing is a compact token projection, a full RateCard when ?pricing=1, or null. OpenRouter-shaped vendor blobs are not served.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModelList"}}}}}}},"/v1/models/{provider}/{modelId}":{"get":{"operationId":"getModel","summary":"Full metadata for one model","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}},{"name":"modelId","in":"path","required":true,"description":"Model slug or raw provider id.","schema":{"type":"string"}}],"responses":{"200":{"description":"Model metadata with activity, schemaEndpointId (canonical generation route on grain=provider catalogs), a RateCard or null for pricing, factSources (per-field provenance), OpenRouter discrepancies, and _links.schema when bound.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Model"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/schemas":{"get":{"operationId":"listAllSchemas","summary":"System-wide schema index","description":"Every provider with extracted schemas, each with its activities and endpoint ids — the discovery entry point for all schemas on the system.","responses":{"200":{"description":"Provider → activity → endpoint-id index.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/schemas/{provider}":{"get":{"operationId":"listProviderSchemas","summary":"Activities and endpoint ids for a provider","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}}],"responses":{"200":{"description":"Activity → endpoint-id index.","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/schemas/{provider}/{activity}":{"get":{"operationId":"getActivitySchemas","summary":"Endpoint-id-keyed schema map for one activity","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}},{"name":"activity","in":"path","required":true,"description":"Activity group.","schema":{"type":"string","enum":["chat","image","video","audio","embeddings","moderation"]}}],"responses":{"200":{"description":"Map of endpoint id → { input, output } self-contained JSON Schemas (current versions).","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/schemas/{provider}/{activity}/{endpointId}":{"get":{"operationId":"getSchema","summary":"One self-contained JSON Schema","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}},{"name":"activity","in":"path","required":true,"description":"Activity group.","schema":{"type":"string","enum":["chat","image","video","audio","embeddings","moderation"]}},{"name":"endpointId","in":"path","required":true,"description":"Path-derived endpoint id (URL-encode slashes), or a listed model rawId/slug which aliases onto that activity's generation route and pins the request `model` field.","schema":{"type":"string"}},{"name":"kind","in":"query","description":"Defaults to input.","schema":{"type":"string","enum":["input","output"]}},{"name":"version","in":"query","description":"Content hash of a historical version.","schema":{"type":"string"}},{"name":"format","in":"query","description":"json (default) or types — a self-contained TypeScript module (schema const + generated types, tree-shakeable, zero imports). format=types on an input schema with a model property overlays the live catalog union plus ListedModelId; the schema const and content hash stay the bundled schema.","schema":{"type":"string","enum":["json","types"]}},{"name":"optional","in":"query","description":"format=types only: optional-property style. exact (default) emits `foo?: T`; undefined emits `foo?: T | undefined`.","schema":{"type":"string","enum":["exact","undefined"]}}],"responses":{"200":{"description":"Self-contained JSON Schema ($defs-bundled) — or, with format=types, a TypeScript module — served with ETag. JSON responses carry `provenance` (upstream sourceUrl, sourceHash, fetchedAt, extractorVersion) so derivations are independently verifiable. `provenance.derivation` grades how the content was arrived at — `upstream-spec` and `generated` are re-derived every sync and self-heal, while `probe-verified` (confirmed against live API calls on `provenance.verifiedAt`) and `docs-derived` (never confirmed) are point-in-time claims that can go stale.","content":{"application/json":{"schema":{"type":"object"}},"text/typescript":{"schema":{"type":"string"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/openapi/{provider}":{"get":{"operationId":"getProviderOpenApi","summary":"Generation-only OpenAPI document for one provider","description":"Assembled from classified endpoints plus the provider connect profile (servers, auth, required headers). Not a raw upstream-spec mirror. Model-grained providers (today: FAL) require ?model=. Selections over 40 classified endpoints, or a filter that matches none, return 400 spec_requires_selector. An unsynced provider returns 404 no_endpoints. ?model= pins the live model enum on provider-grained specs; it does not drop endpoints.","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}},{"name":"model","in":"query","description":"Pin to one model (raw id or slug). Required for model-grained providers.","schema":{"type":"string"}},{"name":"activity","in":"query","description":"Restrict to one activity group.","schema":{"type":"string","enum":["chat","image","video","audio","embeddings","moderation"]}}],"responses":{"200":{"description":"OpenAPI 3.1 document.","content":{"application/openapi+json":{"schema":{"type":"object"}},"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/validate":{"post":{"operationId":"validatePayload","summary":"Validate a payload against a provider endpoint schema","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateRequest"}}}},"responses":{"200":{"description":"Validation result.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateResult"}}}},"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/estimate":{"post":{"operationId":"estimateCost","summary":"Evaluate a stored rate card against request and usage","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateRequest"}}}},"responses":{"200":{"description":"The amount for this call and its currency, the card source, and which inputs (if any) were estimated.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EstimateResult"}}}},"400":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/changes":{"get":{"operationId":"listChanges","summary":"Changelog feed (cursor-paginated)","description":"The polling-friendly alternative to webhooks.","parameters":[{"name":"since","in":"query","description":"Unix epoch seconds lower bound.","schema":{"type":"integer"}},{"name":"provider","in":"query","schema":{"type":"string"}},{"name":"type","in":"query","schema":{"type":"string","enum":["model.added","model.removed","model.updated","schema.added","schema.updated","endpoint.added","endpoint.removed"]}},{"name":"cursor","in":"query","schema":{"type":"string"}},{"name":"wait","in":"query","description":"Long-poll: hold up to N seconds (cap 60; \"30s\" form accepted) until new data exists, then return current data.","schema":{"type":"string"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":200}}],"responses":{"200":{"description":"Changes page with next cursor.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChangesPage"}}}}}}},"/v1/admin/sync/{provider}":{"post":{"operationId":"syncProvider","summary":"Manually trigger a provider spec sync (admin only)","parameters":[{"name":"provider","in":"path","required":true,"description":"Provider slug (see GET /v1/providers).","schema":{"type":"string"}}],"security":[{"adminKey":[]}],"responses":{"200":{"description":"Sync outcome.","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/admin/extract/fal":{"post":{"operationId":"extractFalPricing","summary":"Manually trigger the FAL llms.txt rate-card extract (admin only). Spec sync stays on POST /v1/admin/sync/fal.","security":[{"adminKey":[]}],"responses":{"200":{"description":"Extract outcome.","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"securitySchemes":{"adminKey":{"type":"apiKey","in":"header","name":"X-Admin-Key"},"bearerAuth":{"type":"http","scheme":"bearer","description":"Agent JWT (agent-auth) or API key."}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"}}}}},"ServiceStatus":{"type":"object","required":["service","time","providers"],"properties":{"service":{"type":"string","const":"modelschemas"},"time":{"type":"integer"},"completenessComputedAt":{"type":["integer","null"],"description":"Epoch seconds the completeness scores were computed, at the last models poll (every 15 minutes). null when none is stored yet, as after a deploy that changes the scorer; every score is then null."},"providers":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"displayName":{"type":"string"},"status":{"type":"string","enum":["active","degraded","disabled","pending"]},"lastPolledAt":{"type":["integer","null"]},"lastSyncedAt":{"type":["integer","null"]},"docsFailing":{"type":"object","description":"Present only while the provider docs pages fail to load. Polls go on and models keep their stored docs-derived facts, which may be stale. Does not change status.","required":["since","polls","lastAt","failed","skipped","sources","error"],"properties":{"since":{"type":"integer","description":"Epoch seconds of the first failing poll."},"polls":{"type":"integer","description":"Consecutive failing polls."},"lastAt":{"type":"integer","description":"Epoch seconds of the latest failing poll."},"failed":{"type":"integer","description":"Documents that failed in the latest poll."},"skipped":{"type":"integer","description":"Documents not attempted after the failure budget."},"sources":{"type":"array","items":{"type":"string"},"description":"The first few failing documents."},"error":{"type":"string","description":"First error of the latest poll, at most 500 characters."}}},"updateStorm":{"type":"object","description":"Present only while the latest poll wrote model.updated for more than half of the live rows, and at least 20. The updates are written; this only marks a catalog-wide rewrite. Does not change status. The next poll under that line clears it.","required":["since","polls","lastAt","updated","live"],"properties":{"since":{"type":"integer","description":"Epoch seconds of the first storming poll."},"polls":{"type":"integer","description":"Consecutive storming polls."},"lastAt":{"type":"integer","description":"Epoch seconds of the latest storming poll."},"updated":{"type":"integer","description":"model.updated rows written by the latest poll."},"live":{"type":"integer","description":"Live rows, not deprecated, at the start of that poll."}}},"priceClearsRefused":{"type":"object","description":"Present only while polls refuse to clear most of the stored prices of the provider at once. The stored prices stay and may be stale. Does not change status.","required":["since","polls","lastAt","refused","priced"],"properties":{"since":{"type":"integer","description":"Epoch seconds of the first refusing poll."},"polls":{"type":"integer","description":"Consecutive refusing polls."},"lastAt":{"type":"integer","description":"Epoch seconds of the latest refusing poll."},"refused":{"type":"integer","description":"Stored prices the latest poll asked to clear; none was cleared."},"priced":{"type":"integer","description":"Listed models holding a stored price at that poll."}}},"completeness":{"type":"object","description":"The gap-report score over the live chat models of the provider: the share filled of the eleven chat facts (contextWindow, maxOutput, modalities, priced, cacheRead, capabilities, reasoning, efforts, requestMap, endpoint, replayReasoningContent). Summed per model, each fact counted only where it applies; provider-wide and exact-model source-silent exceptions are excluded. Computed at the models poll (completenessComputedAt), not per request.","required":["score","chat","filled","needed","silent"],"properties":{"score":{"type":["number","null"],"description":"filled / needed, 0 to 1. 1 when every fact that applies is in silent. null when the provider has no live chat models (nothing to score, not a score of zero), when no score is stored yet, and when the chat models changed since the stored score."},"chat":{"type":"integer","description":"Live chat models scored."},"filled":{"type":"integer","description":"Facts carried, summed over those models; silent facts left out."},"needed":{"type":"integer","description":"Facts that apply, summed over those models; silent facts left out."},"silent":{"type":"array","items":{"type":"string"},"description":"Facts the provider does not publish, left out of the score."}}},"counts":{"type":"object","description":"Model tallies count live models only: what GET /v1/models lists by default. Deprecated models are in deprecated and nowhere else.","properties":{"models":{"type":"integer"},"deprecated":{"type":"integer","description":"Models no longer listed upstream (GET /v1/models?deprecated=true)."},"priced":{"type":"integer","description":"Models with a stored rate card. priced / models is the price score."},"reasoning":{"type":"integer","description":"Models with stored reasoning metadata. reasoning / chat is the reasoning score."},"chat":{"type":"integer","description":"Models whose activity is chat."},"endpoints":{"type":"integer"},"schemas":{"type":"integer"}}}}}}}},"Change":{"type":"object","required":["id","type","providerId","subjectId","summary","createdAt"],"properties":{"id":{"type":"string"},"type":{"type":"string","enum":["model.added","model.removed","model.updated","schema.added","schema.updated","endpoint.added","endpoint.removed"]},"providerId":{"type":"string"},"subjectId":{"type":"string"},"summary":{"type":"string"},"payload":{"type":"object","description":"model.updated carries before, after, and changed. changed is the fact paths that differ and is never empty. A source hash, an extract time, the operand order of +, and the order of an input values list are not facts, so they do not appear here and do not produce an event. Schema events carry kind, contentHash, and previousHash instead.","properties":{"before":{},"after":{},"changed":{"type":"array","minItems":1,"items":{"type":"string"},"description":"Fact paths that differ, present on model.updated. For example contextWindow or pricing.tables.rate.base.input_tokens."},"kind":{"type":"string","enum":["input","output"]},"contentHash":{"type":"string"},"previousHash":{"type":["string","null"]}}},"createdAt":{"type":"integer","description":"Unix epoch seconds."}}},"ChangesPage":{"type":"object","required":["count","changes","nextCursor"],"properties":{"count":{"type":"integer"},"changes":{"type":"array","items":{"$ref":"#/components/schemas/Change"}},"nextCursor":{"type":["string","null"]},"_links":{"type":"object"}}},"ValidateRequest":{"type":"object","required":["provider","endpointId","payload"],"properties":{"provider":{"type":"string"},"endpointId":{"type":"string"},"kind":{"type":"string","enum":["input","output"]},"payload":{}}},"ValidateResult":{"type":"object","required":["valid","errors"],"properties":{"valid":{"type":"boolean"},"errors":{"type":"array","items":{"type":"object","properties":{"path":{"type":"string"},"message":{"type":"string"},"keyword":{"type":"string"}}}}}},"CompactPricing":{"type":"object","description":"List-row summary of a stored rate card. per=token cards carry per-million rates at the base tier (tiered marks a long-prompt re-quote above some threshold; fetch the card for it). Other values name the unit the card bills by; the full card is on the detail route or ?pricing=1.","required":["currency","per"],"properties":{"currency":{"type":"string","pattern":"^[A-Z]{3}$","description":"ISO-4217 code the rates are in. Rows in different currencies do not compare; nothing is converted."},"per":{"type":"string","enum":["token","second","character","image","request","unit"]},"inputPerMillion":{"type":"number"},"outputPerMillion":{"type":"number"},"tiered":{"type":"boolean","enum":[true]}}},"RateCardSource":{"type":"object","required":["url","hash","extractedAt"],"properties":{"url":{"type":"string","format":"uri"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"extractedAt":{"type":"string","format":"date-time"},"expiresAt":{"type":"string","format":"date-time"}}},"RateCardExample":{"type":"object","required":["params","usd","quote"],"properties":{"params":{"type":"object"},"usd":{"type":"number","description":"In the card's currency; the name predates currency."},"quote":{"type":"string"}}},"RateCardInput":{"type":"object","required":["param","kind"],"properties":{"param":{"type":"string"},"bound":{"type":"string","enum":["request","usage"]},"kind":{"type":"string","enum":["number","enum","boolean","count","dimensions"]},"estimate":{"type":"object","description":"Number inputs only: the source-published way to estimate this value when the caller omits it. Its own inputs bind only then, and POST /v1/estimate lists the param under estimated. Estimate inputs never carry an estimate of their own.","required":["inputs","value","source"],"properties":{"inputs":{"type":"object","additionalProperties":{"$ref":"#/components/schemas/RateCardInput"}},"value":{"description":"JSONLogic expression over the closed op set."},"source":{"type":"object","required":["url","hash"],"properties":{"url":{"type":"string","format":"uri"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}}}}},"RateCard":{"type":"object","required":["inputs","tables","price","examples","source"],"properties":{"inputs":{"type":"object","additionalProperties":{"$ref":"#/components/schemas/RateCardInput"}},"tables":{"type":"object"},"price":{"description":"JSONLogic expression over the closed op set, yielding USD. A card in another currency wraps it as { \"currency\": [\"CNY\", <expression>] } (ISO 4217); that wrapper is the only place a card states its currency, and an evaluator that does not know it refuses the card."},"examples":{"type":"array","items":{"$ref":"#/components/schemas/RateCardExample"}},"source":{"$ref":"#/components/schemas/RateCardSource"}}},"ChatRequestMap":{"type":"object","description":"Verified chat request wire map. A null field is unverified, not a guess. thinking.levels null means the level subset is unverified; a null level value means omit that field.","properties":{"thinking":{"oneOf":[{"type":"object","required":["on","off","levels"],"properties":{"on":{"type":"object","description":"Request body for thinking on at effort high.","additionalProperties":true},"off":{"description":"Request body that turns thinking off, or null when silence is off."},"levels":{"description":"Shared effort levels to the value this model accepts. null omits the field. The object itself is null when the subset is unverified.","oneOf":[{"type":"object","required":["off","minimal","low","medium","high","xhigh","max"],"properties":{"off":{"type":["string","null"]},"minimal":{"type":["string","null"]},"low":{"type":["string","null"]},"medium":{"type":["string","null"]},"high":{"type":["string","null"]},"xhigh":{"type":["string","null"]},"max":{"type":["string","null"]}}},{"type":"null"}]}}},{"type":"null"}]},"maxTokensField":{"type":["string","null"],"enum":["max_completion_tokens","max_tokens",null]},"developerRole":{"type":["boolean","null"]},"replayReasoningContent":{"type":["boolean","null"]},"store":{"type":["boolean","null"]},"strictTools":{"type":["boolean","null"]},"sessionAffinity":{"type":["boolean","null"]},"cacheControl":{"type":["string","null"],"enum":["anthropic",null]},"toolStream":{"type":["boolean","null"]},"reasoningEffort":{"type":["boolean","null"]}}},"Model":{"type":"object","properties":{"id":{"type":"string"},"provider":{"type":"string"},"rawId":{"type":"string"},"sameAs":{"description":"The catalog row this provider's own listing or docs identify as the same upstream model. It does not change this row's facts. null when no upstream is stated, or the stated one matches no row or more than one. When set, factSources.sameAs records the source, with normalized: true when the id matched only after reading dots as hyphens.","oneOf":[{"type":"object","required":["provider","rawId"],"properties":{"provider":{"type":"string"},"rawId":{"type":"string"}}},{"type":"null"}]},"activity":{"type":["string","null"],"enum":["chat","image","video","audio","embeddings","moderation",null]},"displayName":{"type":["string","null"]},"schemaEndpointId":{"type":["string","null"]},"contextWindow":{"type":["integer","null"]},"maxOutput":{"type":["integer","null"]},"modalities":{},"pricing":{"description":"Full RateCard on detail and on list rows with ?pricing=1; a CompactPricing summary on list rows otherwise. null only when no card is stored.","oneOf":[{"$ref":"#/components/schemas/RateCard"},{"$ref":"#/components/schemas/CompactPricing"},{"type":"null"}]},"capabilities":{"description":"Capability flags as a map. true: the provider states the model supports the flag. false: the provider states it does not. Key absent: unknown; never read a missing key as false. null: nothing is known. Test capabilities?.tools === true to offer a feature and === false to rule it out. factSources.capabilities holds one source per key, for a true and a false alike; a false whose source has path 'unlisted' comes from the provider publishing the model's whole flag list without that flag.","type":["object","null"],"additionalProperties":{"type":"boolean"}},"providerMetadata":{"description":"The provider's own listing object for the model, as published: not normalised, and different for every provider (fal category, BytePlus Ark features and task type, ElevenLabs languages, Replicate visibility). null when the provider lists none. Nothing in it is a capability flag; read capabilities for those.","type":["object","null"],"additionalProperties":true},"reasoning":{"description":"How thinking is configured, or null when the model does not reason or its source names no request field for it. mode names the one control the request exposes: adaptive (the model decides; Anthropic thinking.type adaptive, or a switch with an auto value), budget (a token budget: thinking.budget_tokens, Gemini thinkingBudget), effort (a level: reasoning_effort, Gemini thinkingLevel) or toggle (an on/off switch and nothing else: thinking.type enabled|disabled, enable_thinking; it says nothing about the default when the field is omitted). mandatory has one meaning on every mode. true: the provider states thinking cannot be turned off for this model (on a toggle: the off value is rejected, so send on or omit the field). false: the provider states it can be, in prose or by an off value in this model's own schema or level list. null: unstated. null must not be read as false: test mandatory === false before offering an off option. A toggle is never stored with mandatory null. efforts: the accepted effort values as published, an off value such as none included; never present on toggle. Rows from some providers still carry a true inferred from a level list with no off value; the README release notes list them.","oneOf":[{"type":"object","required":["mode","mandatory"],"properties":{"mode":{"type":"string","enum":["adaptive","budget","effort","toggle"]},"mandatory":{"type":["boolean","null"]},"efforts":{"type":"array","items":{"type":"string"}}}},{"type":"null"}]},"serverTools":{"description":"Provider-hosted tool type ids the model accepts in the request's tools array (web_search_20250305, google_search, x_search, …), or null when unknown. factSources.serverTools holds one source per id.","type":["array","null"],"items":{"type":"string"}},"requestMap":{"description":"How to build this chat model's request: thinking on/off and shared effort levels (null omits the field), max-token field name, developer vs system role, reasoning_content replay, and related flags. Null until verified. reasoning stays the readable fact (mode, mandatory, efforts).","oneOf":[{"$ref":"#/components/schemas/ChatRequestMap"},{"type":"null"}]},"aliases":{"description":"Caller ids that resolve to this row (for example claude-opus-4-5 → the dated snapshot). null when the provider documents none. GET /v1/models/{provider}/{id} accepts an alias and returns this row, whose rawId is the dated id.","type":["array","null"],"items":{"type":"string"}},"factSources":{"description":"Per-field provenance, included by default on detail and list responses (provenance=0 explicitly omits it on lists). A ledgered null chat fact carries derivation source-silent, with sourceUrl and checkedAt only when recorded. capabilities and serverTools normally contain per-item source maps; whole-field silence is a source-silent object. Missing cacheRead and efforts subfacts have separate provenance keys; endpoint silence is schemaEndpointId. Populated facts keep their existing provenance. Nulls without ledger evidence gain no entry."},"releasedAt":{"description":"The provider's own stated release or creation date, epoch seconds. null when the provider reports none. Unlike firstSeenAt it is never our observation.","type":["integer","null"]},"knowledgeCutoff":{"description":"Knowledge (training data) cutoff as the provider states it: YYYY-MM, or YYYY-MM-DD when the provider gives a day. Never padded to a day. null when unknown. factSources.knowledgeCutoff is its source.","type":["string","null"],"pattern":"^\\d{4}-\\d{2}(-\\d{2})?$"},"openWeights":{"description":"true when the provider itself states the weights can be openly downloaded, false when it states they cannot, null when it states neither. Never inferred from a model name. factSources.openWeights is its source.","type":["boolean","null"]},"weightsUrl":{"description":"Where the provider says the weights are. Set only when openWeights is true.","type":["string","null"]},"firstSeenAt":{"description":"The release date the provider reports when it reports one (the same date as releasedAt), otherwise when this service first observed the model. Read releasedAt to tell the two apart.","type":"integer"},"lastSeenAt":{"type":"integer"},"deprecatedAt":{"type":["integer","null"]}}},"ModelList":{"type":"object","properties":{"count":{"type":"integer"},"models":{"type":"array","items":{"$ref":"#/components/schemas/Model"}}}},"EstimateRequest":{"type":"object","required":["provider","model"],"properties":{"provider":{"type":"string"},"model":{"type":"string"},"request":{"type":"object"},"usage":{"type":"object"}}},"EstimateResult":{"type":"object","required":["amount","currency","cardSource","estimated"],"properties":{"amount":{"type":"number","description":"The price, in currency. Never converted."},"currency":{"type":"string","pattern":"^[A-Z]{3}$","description":"ISO-4217 code of the card's currency."},"usd":{"type":"number","deprecated":true,"description":"Deprecated: read amount and currency. Repeats amount when currency is USD; absent for any other currency."},"cardSource":{"$ref":"#/components/schemas/RateCardSource"},"estimated":{"type":"array","items":{"type":"string"},"description":"Params the caller omitted that the card estimated by its published method. Empty: amount is the price as billed for the supplied request and usage."}}}}}}