Modèles
Lister les modèles
client.beta.models.list(params?, options?): Page<BetaModelInfo>Lister les modèles disponibles.
Obtenir un modèle
client.beta.models.retrieve(modelID, params?, options?): BetaModelInfoObtenir un modèle spécifique.
Models
interface BetaCapabilitySupport { supported }Indicates whether a capability is supported.
Indicates whether a capability is supported.
Whether this capability is supported by the model.
interface BetaCompactionCapability { summarize; supported }Compaction capability details: whether the model accepts the top-level
compaction request parameter, with one entry per supported
compaction.type value.
Compaction capability details: whether the model accepts the top-level
compaction request parameter, with one entry per supported
compaction.type value.
summarize: BetaCapabilitySupport { supported }Whether the summarize compaction type is supported.
Whether the summarize compaction type is supported.
Whether this capability is supported by the model.
Whether this capability is supported by the model.
interface BetaContextManagementCapability { clear_thinking_20251015; clear_tool_uses_20250919; compact_20260112; supported }Context management capability details.
Context management capability details.
clear_thinking_20251015: BetaCapabilitySupport | nullWhether the clear_thinking_20251015 strategy is supported.
Whether the clear_thinking_20251015 strategy is supported.
Whether this capability is supported by the model.
clear_tool_uses_20250919: BetaCapabilitySupport | nullWhether the clear_tool_uses_20250919 strategy is supported.
Whether the clear_tool_uses_20250919 strategy is supported.
Whether this capability is supported by the model.
compact_20260112: BetaCapabilitySupport | nullWhether the compact_20260112 strategy is supported.
Whether the compact_20260112 strategy is supported.
Whether this capability is supported by the model.
Whether this capability is supported by the model.
interface BetaEffortCapability { high; low; max; /* 3 more */ }Effort (reasoning_effort) capability details.
Effort (reasoning_effort) capability details.
interface BetaModelCapabilities { batch; citations; code_execution; /* 8 more */ }Model capability information.
Model capability information.
interface BetaModelInfo { type: "model"; id; allowed_fallback_models; /* 9 more */ }
type BetaModelLine = "haiku" | "sonnet" | "opus" | 2 moreA Claude model line, such as opus or sonnet. More lines may be added as new values.
A Claude model line, such as opus or sonnet. More lines may be added as new values.
interface BetaServerToolsCapability { code_execution; supported; web_search }Web search and code execution tool support, with one entry per tool.
Web search and code execution tool support, with one entry per tool.
code_execution: BetaCapabilitySupport { supported }Whether the model supports the code execution tool: true when the model supports at least one version of the tool, not necessarily every version.
Whether the model supports the code execution tool: true when the model supports at least one version of the tool, not necessarily every version.
Whether this capability is supported by the model.
Whether this capability is supported by the model.
web_search: BetaCapabilitySupport { supported }Whether the model supports the web search tool: true when the model supports at least one version of the tool, not necessarily every version.
Whether the model supports the web search tool: true when the model supports at least one version of the tool, not necessarily every version.
Whether this capability is supported by the model.
interface BetaThinkingCapability { supported; types }Thinking capability details.
Thinking capability details.
Whether this capability is supported by the model.
types: BetaThinkingTypes { adaptive; disabled; enabled }Supported thinking type configurations.
Supported thinking type configurations.
adaptive: BetaCapabilitySupport { supported }Whether the model accepts thinking with type 'adaptive' (the model decides whether and how much to think).
Whether the model accepts thinking with type 'adaptive' (the model decides whether and how much to think).
Whether this capability is supported by the model.
disabled: BetaCapabilitySupport { supported }Whether the model accepts thinking with type 'disabled' (thinking turned off). False exactly when a request that sends it gets a 400 from this model. True on a model that does not support thinking.
Whether the model accepts thinking with type 'disabled' (thinking turned off). False exactly when a request that sends it gets a 400 from this model. True on a model that does not support thinking.
Whether this capability is supported by the model.
enabled: BetaCapabilitySupport { supported }Whether the model accepts thinking with type 'enabled' (extended thinking with a caller-set budget_tokens).
Whether the model accepts thinking with type 'enabled' (extended thinking with a caller-set budget_tokens).
Whether this capability is supported by the model.
interface BetaThinkingTypes { adaptive; disabled; enabled }Which thinking.type values the model accepts on requests. Read each key on its own: for example, enabled can be false while disabled is true.
Which thinking.type values the model accepts on requests. Read each key on its own: for example, enabled can be false while disabled is true.
adaptive: BetaCapabilitySupport { supported }Whether the model accepts thinking with type 'adaptive' (the model decides whether and how much to think).
Whether the model accepts thinking with type 'adaptive' (the model decides whether and how much to think).
Whether this capability is supported by the model.
disabled: BetaCapabilitySupport { supported }Whether the model accepts thinking with type 'disabled' (thinking turned off). False exactly when a request that sends it gets a 400 from this model. True on a model that does not support thinking.
Whether the model accepts thinking with type 'disabled' (thinking turned off). False exactly when a request that sends it gets a 400 from this model. True on a model that does not support thinking.
Whether this capability is supported by the model.
enabled: BetaCapabilitySupport { supported }Whether the model accepts thinking with type 'enabled' (extended thinking with a caller-set budget_tokens).
Whether the model accepts thinking with type 'enabled' (extended thinking with a caller-set budget_tokens).
Whether this capability is supported by the model.