CertSafari
    CCAR-P · Lessons

    Domain 3 · Lesson 18/38

    MCP vs Direct Tool Use: Choosing How Claude Connects to a System

    Evaluate connection protocols and select the appropriate integration mechanism

    10 min read
    2.38% of exam
    4 sources
    Published 27 Sep 2026
    Docs as of 26 Sep 2026

    What you will be able to do

    • Tell apart the parts an MCP integration is built from (host, client and server) and what the protocol standardises between them
    • Explain how direct tool use works, where your application defines and runs the tool, and when that is enough
    • Know what the Messages API MCP connector does, what it needs and what it cannot do, so you can tell when it fits

    Key concept

    Integration mechanism — The integration mechanism is your decision about who defines a capability, where its code runs and who owns the connection. The choices are your own application (direct tool use through the API), an MCP server that Claude reaches through a client such as the connector, or another agent that runs in its own context. Most exam scenarios become easy once you ask where the code executes and who has to write the client.

    1.Three ways to give Claude a capability

    The exam guide names three integration mechanisms: MCP, API/CLI, and agent-to-agent. They are not competing brands. Each one answers the same question differently: when Claude needs something it cannot do from its own weights, who provides that capability, and over what connection?

    With direct tool use, you describe a function in the API request. Claude returns a structured call, and your application runs it. That application may call a REST API or run a command-line tool. With MCP, a separate server exposes its capabilities through a shared protocol, and a client connects to that server. With agent-to-agent delegation, the capability is a whole other agent, with its own model, prompt and tools.

    This page covers the first two, because the most common exam decision is between them. The MCP specification describes three roles. The client is not the application itself. It is a connector that lives inside the application.

    The three roles defined by the MCP specification
    RoleWhat the specification says it is
    HostsLLM applications that initiate connections
    ClientsConnectors within the host application
    ServersServices that provide context and capabilities

    Sources12

    2.What MCP standardises, and what it isolates

    MCP messages use JSON-RPC. The specification defines three message types: requests that expect a response, responses that match a request ID, and one-way notifications. A connection is stateful. The host establishes one stateful session per server, and at the start of that session the two sides negotiate capabilities. A server can only offer what it has declared. For example, tool invocation requires the server to declare tool capabilities.

    A server can expose more than tools. It can also offer resources (context and data) and prompts (templated messages). A client can offer sampling. Keep this full list in mind, because some MCP clients support only part of it, and the exam tests that gap.

    The architecture also has a design goal that matters for security questions: servers are kept narrow and isolated. The full conversation history stays with the host, each server connection is isolated, and the host controls any interaction between servers. Servers are meant to be easy to build and to combine, so a new system becomes one more focused server rather than a change to the host.

    The specification pairs this with consent rules. Tools represent arbitrary code execution, and hosts must obtain explicit user consent before invoking any tool.

    Sources31

    3.Direct tool use: you define the tool, your code runs it

    Direct tool use (also called function calling) is the baseline mechanism. You pass a tool with a name, a description and an input_schema. Claude decides whether to call it from the user's request and the tool's description. If it does, the response stops with stop_reason: "tool_use" and contains a tool_use block. Your code performs the operation and sends the output back in a tool_result block, and Claude uses it to answer.

    This is the "API/CLI" route. What the tool does is up to your code. It can call an internal API, query a database, or run a shell command. The documentation calls these client tools, and they include tools with Anthropic-defined schemas such as bash and text_editor. Server tools such as web_search, web_fetch, code_execution and tool_search run on Anthropic's infrastructure, so you receive their results without running anything yourself.

    A client tool definition: the name, description and input_schema are all Claude seespython
    tools = [
        {
            "name": "get_weather",
            "description": "Get the current weather for a given location.",
            "input_schema": {
                "type": "object",
                "properties": {
                    "location": {
                        "type": "string",
                        "description": "City and state, e.g. San Francisco, CA",
                    }
                },
                "required": ["location"],
            },
        }
    ]

    The trade-off is ownership. Direct tool use needs no server and no protocol, but you write the tool loop, the execution and the result formatting. You can skip writing the loop by hand with Tool Runner, which runs your tools and sends the results back for you. Each integration still lives inside your application, though. Another host cannot reuse it the way it could reuse an MCP server.

    A fintech company wants Claude to call tools hosted on an internal Postgres query service. The service currently only exposes a local stdio-based MCP server used by developers on their laptops, but the production app needs Claude to invoke it directly from server-side Messages API calls without operating a separate MCP client process. What should the team do?

    Sources2

    4.The MCP connector: MCP from the Messages API without writing a client

    Between writing your own tools and writing your own MCP client there is a third option. The MCP connector lets a Messages API request connect directly to remote MCP servers. It has two parts. The mcp_servers array defines each connection (URL and authentication). An mcp_toolset entry in the tools array chooses which of that server's tools are enabled. You can enable all of them, allowlist specific tools or denylist unwanted ones, and one request can use several servers.

    An MCP server definition in the mcp_servers arrayjson
    {
      "type": "url",
      "url": "https://example-server.modelcontextprotocol.io/sse",
      "name": "example-mcp",
      "authorization_token": "YOUR_TOKEN"
    }
    mcp_servers properties and the constraint each one imposes
    PropertyRequiredConstraint
    typeYesCurrently only "url" is supported
    urlYesMust start with https://
    nameYesMust be referenced by exactly one MCPToolset in the tools array
    authorization_tokenNoOAuth authorization token if required by the MCP server

    Two limits decide whether the connector fits. First, the server must be publicly exposed over HTTP, using Streamable HTTP or SSE. A local STDIO server cannot be connected directly. Second, the connector supports only tool calls from the MCP feature set. Resources, prompts and sampling are not available through it. If you need either of those, you need an MCP client you build yourself, which the documentation points to separately.

    Connecting a server does not make Claude call it on every turn. Claude calls a tool when the request matches what that tool is described as doing. General questions about the connected service are answered directly. You can adjust how readily Claude uses the tools through the system prompt.

    A platform team is building an automated CI pipeline step where Claude must read repository files, run test commands, and edit code across multiple iterations until tests pass, without the team writing custom logic to parse tool_use blocks and resubmit tool results. Which integration approach best fits this need?

    Sources4

    Exam traps

    Each one states something that sounds right. Open it to see what is actually true.

    1. 1.The Messages API MCP connector can connect to any MCP server, including a stdio server running on the developer's machine.Why is that wrong?

      The connector only reaches servers exposed publicly over HTTP, using Streamable HTTP or SSE. It cannot connect directly to a local STDIO server.

      Covered in The MCP connector: MCP from the Messages API without writing a client

    2. 2.Attaching an MCP server through the connector gives Claude the server's resources and prompts as well as its tools.Why is that wrong?

      Of the MCP feature set, the connector currently supports only tool calls. Resources and prompts need a different client.

      Covered in The MCP connector: MCP from the Messages API without writing a client

    3. 3.An MCP server receives the whole conversation so it can use earlier context from other tools.Why is that wrong?

      The full conversation history stays with the host, and each server connection is isolated.

      Covered in What MCP standardises, and what it isolates

    Sources

    Every claim above is drawn from one of these pages, quoted as it was written on the date shown.

    1. 1.
      “Clients: Connectors within the host application”
      ↩︎ Three ways to give Claude a capability
      “Hosts must obtain explicit user consent before invoking any tool”
      ↩︎ What MCP standardises, and what it isolates
    2. 2.
      “Claude determines when to call a tool based on the user's request and the tool's description.”
      ↩︎ Three ways to give Claude a capability
      “Client tools (including user-defined tools and tools with Anthropic-defined schemas, such as bash and text_editor) run in your application.”
      ↩︎ Direct tool use: you define the tool, your code runs it
      “Your code executes the operation and sends back a tool_result.”
      ↩︎ Direct tool use: you define the tool, your code runs it
      “Tools differ primarily by where the code executes.”
      ↩︎ Key concept
    3. 3.
      “Establishes one stateful session per server”
      ↩︎ What MCP standardises, and what it isolates
      “Tool invocation requires the server to declare tool capabilities”
      ↩︎ What MCP standardises, and what it isolates
      “Cross-server interactions are controlled by the host”
      ↩︎ What MCP standardises, and what it isolates
      “Full conversation history stays with the host”
      ↩︎ Exam trap 3
    4. 4.
      “connect to remote MCP servers directly from the Messages API without a separate MCP client”
      ↩︎ The MCP connector: MCP from the Messages API without writing a client
      “Flexible tool configuration: Enable all tools, allowlist specific tools, or denylist unwanted tools”
      ↩︎ The MCP connector: MCP from the Messages API without writing a client
      “Claude does not call an MCP tool for general knowledge questions about a connected service.”
      ↩︎ The MCP connector: MCP from the Messages API without writing a client
      “Local STDIO servers cannot be connected directly.”
      ↩︎ Exam trap 1
      “Of the feature set of the MCP specification, only tool calls are currently supported.”
      ↩︎ Exam trap 2

    Continue to page 2 of 2

    MCP Transports, Connection Auth and Agent-to-Agent Delegation