608 pages for reason.
Titles and paths first, then pages whose text carries it. Each row opens that page as this site last read it.
handling-stop-reasons
Claude Developer Platform · title
build-with-claude/handling-stop-reasons
choosing-a-model
Claude Developer Platform · in the page
about-claude/models/choosing-a-model
…f your evals at `xhigh` or `max` effort still fall short on demanding reasoning or long-horizon agentic work, move to [Claude Fable 5.2](https://platform.claude.com/docs/en/models/fable-5-2/overview).…
Or, for the model with the same capabilities and no access approval requirement:
Claude Developer Platform · in the page
about-claude/models/migration-guide
…Fable 5 runs safety classifiers that can decline requests with `stop_reason: "refusal"`. Claude Mythos 5 does not include these classifiers. See [Refusals and fallback](https://platform.claude.com/do…
optimizing-for-cost-and-intelligence
Claude Developer Platform · in the page
about-claude/models/optimizing-for-cost-and-intelligence
…lligence#compare-models-on-cost-per-task) | | Attempts end with `stop_reason: max_tokens` | Raise `max_tokens` to 64,000: in Anthropic’s tests only 7 of about 18,000 turns were longer, and cost per so…
pricing
Claude Developer Platform · in the page
about-claude/pricing
…, Sonnet for most production workloads, and Opus for the most complex reasoning. 2. **Implement prompt caching:** Reduce costs for repeated context. 3. **Batch operations:** Use the Batch API for non-…
content-moderation
Claude Developer Platform · in the page
about-claude/use-case-guides/content-moderation
…n title="You need consistent policy decisions"> With its advanced reasoning capabilities, Claude can interpret and apply complex moderation guidelines uniformly. This consistency helps ensure fair…
customer-support-chat
Claude Developer Platform · in the page
about-claude/use-case-guides/customer-support-chat
…cost, including the most complex support scenarios that require deep reasoning across long, multistep conversations. However, for instances where you have a conversation flow with multiple prompts in…
legal-summarization
Claude Developer Platform · in the page
about-claude/use-case-guides/legal-summarization
…lls to Claude in parallel so that the summaries can be completed in a reasonable timeframe. Refer to Anthropic’s [rate limits](https://platform.claude.com/docs/en/api/rate-limits#rate-limits) to deter…
ticket-routing
Claude Developer Platform · in the page
about-claude/use-case-guides/ticket-routing
…ect matter expertise, a large volume of intent categories, or complex reasoning, you may opt for the [larger Sonnet model](https://platform.claude.com/docs/en/models/overview). ### Build a strong pro…
PDF Processing
Claude Developer Platform · in the page
agents-and-tools/agent-skills/best-practices
…anced): Is the Skill clear and efficient? * **Claude Opus** (powerful reasoning): Does the Skill avoid over-explaining? What works perfectly for Opus might need more detail for Haiku. If you plan to…
claude-api-skill
Claude Developer Platform · in the page
agents-and-tools/agent-skills/claude-api-skill
…k into thinking summarization (`thinking.display: "summarized"`) when reasoning is surfaced to users on Claude Opus 4.8 and Claude Opus 4.7 * **Refusal fallback configuration**, in three parts: *…
quickstart
Claude Developer Platform · in the page
agents-and-tools/agent-skills/quickstart
…_execution_20260521", "name": "code_execution"}], ) print(f"stop_reason={response.stop_reason}, blocks={len(response.content)}") ``` ```typescript TypeScript // Create a message with the P…
advisor-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/advisor-tool
…d when | | ----- | ----- | ----- | | `advisor_result` | `text`, `stop_reason` | The advisor model returns plaintext (for example, Claude Opus 4.8). | | `advisor_redacted_result` | `encrypted_content`,…
bash-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/bash-tool
…] ) puts response ``` </CodeGroup> Claude responds with `stop_reason: "tool_use"` and a `tool_use` block that contains the command for your application to run: ```json Output { "id": "msg_0…
browser-use-sdk
Claude Developer Platform · in the page
agents-and-tools/tool-use/browser-use-sdk
…ents-and-tools/tool-use/browser-use-sdk#implement-a-driver) gives the reason. ### Scale coordinates and size images Every point Claude sends is a pixel position in the screenshots you return: each `…
browser-use-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/browser-use-tool
…response ``` </CodeGroup> Claude’s first response ends with `stop_reason: "tool_use"` and carries one or more member `tool_use` blocks, each naming a member tool in `name` and carrying `"toolset_n…
build-a-tool-using-agent
Claude Developer Platform · in the page
agents-and-tools/tool-use/build-a-tool-using-agent
…rmines that a tool call is needed, the response comes back with `stop_reason: "tool_use"` and a `tool_use` content block containing the tool name, a unique `id`, and the structured `input`. Your code…
code-execution-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/code-execution-tool
…`container` parameter to get a new container. ### `pause_turn` stop reason The response might include a `pause_turn` stop reason, which indicates that the API paused a long-running turn. You may pr…
computer-use-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/computer-use-tool
…CodeGroup> When Claude acts on the desktop, the response has a `stop_reason` of `tool_use` and contains one or more member `tool_use` blocks, each naming a member tool and carrying `"toolset_name": "…
define-tools
Claude Developer Platform · in the page
agents-and-tools/tool-use/define-tools
…aque internal references, and include only the fields Claude needs to reason about its next step. Bloated responses waste context and make it harder for Claude to extract what matters. * **Ask for an…
fine-grained-tool-streaming
Claude Developer Platform · in the page
agents-and-tools/tool-use/fine-grained-tool-streaming
…receive partial or invalid JSON. A response that ends with the [stop reason](https://platform.claude.com/docs/en/build-with-claude/handling-stop-reasons) `max_tokens` can also cut a parameter off mid…
handle-tool-calls
Claude Developer Platform · in the page
agents-and-tools/tool-use/handle-tool-calls
…ks). ## Handling results from client tools The response has a `stop_reason` of `tool_use` and one or more `tool_use` content blocks that include: * `id`: A unique identifier for this particular too…
how-tool-use-works
Claude Developer Platform · in the page
agents-and-tools/tool-use/how-tool-use-works
…your code runs the operation, and you send back a `tool_result`. The reason to use an Anthropic-schema tool instead of defining your own equivalent is that these schemas are trained-in. Claude has be…
manage-tool-context
Claude Developer Platform · in the page
agents-and-tools/tool-use/manage-tool-context
…d context editing to trim stale results as the conversation grows. A reasonable starting point for a high-volume agent: 1. Enable prompt caching on your tool definitions from the start. Cache writes…
memory-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/memory-tool
…}) if err != nil { log.Fatal(err) } if message.StopReason != anthropic.StopReasonToolUse { for _, block := range message.Content { if block.Type == "text" { fmt.Pr…
overview
Claude Developer Platform · in the page
agents-and-tools/tool-use/overview
…nd `text_editor`) run in your application. Claude responds with `stop_reason: "tool_use"` and one or more `tool_use` blocks. Your code runs the operation and sends back a `tool_result`. **Server tools…
parallel-tool-use
Claude Developer Platform · in the page
agents-and-tools/tool-use/parallel-tool-use
…xecution semantics When Claude calls tools, the response has a `stop_reason` of `tool_use` and can contain several `tool_use` blocks in a single assistant turn. How you run those calls is your decisi…
Process results programmatically
Claude Developer Platform · in the page
agents-and-tools/tool-use/programmatic-tool-calling
…e employees who exceeded their limits, shrinking what Claude needs to reason over from hundreds of kilobytes down to a few lines. <Tip> For a deeper look at the inference and context costs that pro…
server-tools
Claude Developer Platform · in the page
agents-and-tools/tool-use/server-tools
…e` block appears without its result, and the response ends with `stop_reason: "tool_use"`. The API runs the tool when you return the client `tool_result` blocks in your next request. ## The server-si…
text-editor-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/text-editor-tool
…"msg_01XAbCDeFgHiJkLmNoPQrStU", "model": "claude-opus-5-5", "stop_reason": "tool_use", "role": "assistant", "content": [ { "type": "text", "text": "I'll help you fix the syntax…
Log at info level
Claude Developer Platform · in the page
agents-and-tools/tool-use/tool-runner
…92; for await (const message of runner) { if (message.stop_reason === "max_tokens") { const current = runner.params.max_tokens; if (current >= MAX_TOKEN_CEILING) {…
tool-search-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/tool-search-tool
…, discovers `get_weather`, and calls it. The response ends with `stop_reason: "tool_use"`. Run the discovered tool and return a `tool_result` as in [Handle tool calls](https://platform.claude.com/docs…
troubleshooting-tool-use
Claude Developer Platform · in the page
agents-and-tools/tool-use/troubleshooting-tool-use
…e waiting tool from running. The error message and the previous `stop_reason` show why. Use the first case that matches: * **The message ends with ``but no `<name>` tool was provided`` or `is not ava…
web-fetch-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/web-fetch-tool
…group of parallel tool calls: the API returns the response with `stop_reason: "tool_use"` before that fetch has run, then runs the fetch when you send back the client `tool_result` blocks. See [Mixing…
web-search-tool
Claude Developer Platform · in the page
agents-and-tools/tool-use/web-search-tool
…server_tool_use": { "web_search_requests": 1 } }, "stop_reason": "end_turn" } ``` This example shows a direct search. When a search runs through [dynamic filtering](https://platform.cla…
Beta
Claude Developer Platform · in the page
api/beta
…ed by the model. - `effort: BetaEffortCapability` Effort (reasoning_effort) support and available levels. - `high: BetaCapabilitySupport` Whether the model supports high ef…
Agents
Claude Developer Platform · in the page
api/beta/agents
…unchanged. - `"low"` Low effort. Favors latency over reasoning depth. - `"medium"` Medium effort. Balances latency and reasoning depth. - `"high"` High…
Archive Agent
Claude Developer Platform · in the page
api/beta/agents/archive
…nagedAgentsEffortLow object` Low effort. Favors latency over reasoning depth. - `type: "low"` - `BetaManagedAgentsEffortMedium object` Medium effort. Balances latency…
Create Agent
Claude Developer Platform · in the page
api/beta/agents/create
…unchanged. - `"low"` Low effort. Favors latency over reasoning depth. - `"medium"` Medium effort. Balances latency and reasoning depth. - `"high"` High…
List Agents
Claude Developer Platform · in the page
api/beta/agents/list
…nagedAgentsEffortLow object` Low effort. Favors latency over reasoning depth. - `type: "low"` - `BetaManagedAgentsEffortMedium object` Medium effort. Balances latency…
Get Agent
Claude Developer Platform · in the page
api/beta/agents/retrieve
…nagedAgentsEffortLow object` Low effort. Favors latency over reasoning depth. - `type: "low"` - `BetaManagedAgentsEffortMedium object` Medium effort. Balances latency…
Update Agent
Claude Developer Platform · in the page
api/beta/agents/update
…unchanged. - `"low"` Low effort. Favors latency over reasoning depth. - `"medium"` Medium effort. Balances latency and reasoning depth. - `"high"` High…
Versions
Claude Developer Platform · in the page
api/beta/agents/versions
…nagedAgentsEffortLow object` Low effort. Favors latency over reasoning depth. - `type: "low"` - `BetaManagedAgentsEffortMedium object` Medium effort. Balances latency…
List Agent Versions
Claude Developer Platform · in the page
api/beta/agents/versions/list
…nagedAgentsEffortLow object` Low effort. Favors latency over reasoning depth. - `type: "low"` - `BetaManagedAgentsEffortMedium object` Medium effort. Balances latency…
Compliance
Claude Developer Platform · in the page
api/beta/compliance
…exploitation"` - `"self_harm"` - `"adult_content"` - `"reasoning_extraction"` - `"frontier_llm"` - `"compromised_key"` - `"benign"` - `"other"` - `"undetermined…
Review
Claude Developer Platform · in the page
api/beta/compliance/review
…exploitation"` - `"self_harm"` - `"adult_content"` - `"reasoning_extraction"` - `"frontier_llm"` - `"compromised_key"` - `"benign"` - `"other"` - `"undetermined…
Cases
Claude Developer Platform · in the page
api/beta/compliance/review/cases
…exploitation"` - `"self_harm"` - `"adult_content"` - `"reasoning_extraction"` - `"frontier_llm"` - `"compromised_key"` - `"benign"` - `"other"` - `"undetermined…
List Review Cases
Claude Developer Platform · in the page
api/beta/compliance/review/cases/list
…exploitation"` - `"self_harm"` - `"adult_content"` - `"reasoning_extraction"` - `"frontier_llm"` - `"compromised_key"` - `"benign"` - `"other"` - `"undetermined…
Respond to Review Case
Claude Developer Platform · in the page
api/beta/compliance/review/cases/respond
…`surveillance`, `human_exploitation`, `self_harm`, `adult_content`, `reasoning_extraction`, `frontier_llm` (use of the model to accelerate frontier AI research and development in restricted ways), `c…
Get Review Case
Claude Developer Platform · in the page
api/beta/compliance/review/cases/retrieve
…exploitation"` - `"self_harm"` - `"adult_content"` - `"reasoning_extraction"` - `"frontier_llm"` - `"compromised_key"` - `"benign"` - `"other"` - `"undetermined…