Courseiva
Agents and the Agent SDK →mediumMultiple Choice

CCDV-F Agents and the Agent SDK Practice Question

Exhibit

{
  "type": "tool_result",
  "tool_use_id": "toolu_01A2B3C4",
  "content": "Error: Connection timeout after 5000ms",
  "is_error": true
}

Refer to the exhibit. An agent receives this response after attempting to use a 'fetch_url' tool. How will this specific block affect the agent's next reasoning step?

⚠ Common exam trap

Candidates mistakenly believe an error response terminates the agent's session. In reality, the SDK treats the 'is_error' flag as a cue for the model to initiate recovery or retry logic.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

The model will interpret this as a signal to retry or handle the failure.

The 'is_error' flag is a critical signal to the model that the requested action did not succeed. By explicitly marking the result as an error, the SDK helps Claude understand that it needs to perform error recovery—such as retrying the request, checking the URL for typos, or reporting the failure to the user—rather than proceeding as if the data was retrieved.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    The model will ignore the result and repeat the exact same tool call.

    Why it's wrong here

    Claude is designed to learn from the conversation history. If it sees an error message, it typically tries to diagnose the problem. Simply repeating the exact same call without changes is a sign of a poorly prompted agent; a well-functioning agent will recognize the timeout and either retry with a different parameter or explain the issue.

  • ✗

    The model will treat the error message as the successful content of the URL.

    Why it's wrong here

    Because 'is_error' is set to true, the model is explicitly told that this content is a failure notification, not the actual data it sought. This prevents the model from hallucinating that the string 'Error: Connection timeout' is the actual text content of the website it was trying to fetch and analyze.

  • ✓

    The model will interpret this as a signal to retry or handle the failure.

    Why this is correct

    The 'is_error' field provides semantic context that the tool execution failed. This prompts Claude's reasoning engine to shift from 'processing data' to 'troubleshooting.' It might suggest checking the internet connection, trying a different URL, or informing the user that the resource is currently unavailable.

  • ✗

    The SDK will automatically terminate the session to prevent further errors.

    Why it's wrong here

    The Agent SDK does not terminate sessions automatically upon a tool error unless the developer has specifically programmed that behavior. The goal of agentic design is often resilience, so the SDK simply passes the error back to the model to allow it to attempt a graceful recovery or provide a helpful error message.

About these practice questions

This CCDV-F question is part of Courseiva's 257-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official Anthropic exam blueprint

This CCDV-F practice question is part of Courseiva's free Anthropic certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CCDV-F exam.