Skip to main content
In this lesson we answer a practical question: which MCP (Model — Context — Protocol) primitive fits which use case? Understanding the distinction between primitives (Tool, Resource, Prompt) helps you design safe, auditable, and predictable model integrations. Consider a simple user request: ask an assistant to check your company’s calendar for
The image is a stylized diagram titled "Which Primitive Fits" showing a laptop chat window with a message "Find a free slot" and a dashed box labeled "Use case ?" beneath it. A horizontal line from that box branches to three icons labeled Tool, Resource, and Prompt.
a free slot and then book a meeting. On the surface this looks like one request, but it actually involves two distinct primitives:
  • Reading the calendar is a resource operation: the model needs view-only access to calendar data.
  • Booking the meeting is a tool operation: the model triggers an action that changes state.
These two steps are often sequenced inside the assistant workflow: first a resource read to find availability, then one or more tool calls to create the event.
A diagram titled "One Request, Two Operations" showing a chat window asking to "Find a free slot and book a meeting." It links a model icon (chip) via a message to a company calendar that lists appointments with a highlighted 14:00 "Free" slot.

Primitive mapping: Tool vs Resource vs Prompt

Use this quick reference to decide which primitive applies when architecting model integrations:

Common sample use cases and how to classify operations

  • Developer tooling
    • Resource: reading project files or type information so the model can reason about code.
    • Tool: renaming a variable, refactoring, or writing a file (these are actions that modify state).
    • Example: editing a simple function in a code editor:
  • Databases
    • Resource: exposing a schema or sample rows so the model can craft correct queries.
    • Tool: executing queries that modify data (INSERT/UPDATE/DELETE) — these are tool calls.
  • Workflow automation
    • Resource: drafting or templating a status report using prompt templates and read-only context.
    • Tool: sending the email or triggering an external job (those change state).
    • Desktop/file assistants that move or rename files are tool calls; older read-only “roots” utilities that provide directory listings are resources (note: some roots-style tooling is deprecated).
Example sequence (pseudo-commands and outputs):
  • Web interaction
    • A browser-automation assistant filling a website form will perform many tool calls (click, type, navigate).
  • Multi-agent coordination
    • One agent might research prices and perform resource reads + API lookups, while another drafts and submits the purchase order (tool calls).
    • Older server-side sampling or orchestration patterns have been deprecated; the recommended approach is for each agent to call provider APIs directly and explicitly.
Example of simple form automation steps:

Deployment patterns and trust boundaries

All of the above examples assume a server component that mediates model interactions. Where that server runs determines the trust model and security controls you must apply. There are three common deployment patterns:
  1. Local-first
    • Both the host (UI) and the server run on the user’s machine and communicate via local IPC or stdio.
    • Credentials and tokens are stored locally.
    • Nothing needs to cross the network — simplifies privacy and trust assumptions.
  2. Remote
    • The host communicates with a remote server over HTTP(S).
    • Authentication and authorization use standard protocols (for example, OAuth 2.1).
    • Network boundaries and third-party control require stricter auditing, monitoring, and trust policies.
  3. Hybrid
    • Some services run locally, others remotely.
    • Each server instance has its own trust level; design separate trust rules and data flows for local vs remote components.
When designing deployments, explicitly document where each server runs (local, remote, or both) and assign trust rules for every location. This prevents accidentally exposing credentials or sensitive data to less-trusted endpoints.

Quick checklist for architects

  • Catalog operations as resource-read vs action/tool.
  • Map each operation to a deployment location and assign trust policies.
  • Minimize the blast radius: grant minimal necessary permissions for tools and keep sensitive data on local-first components when feasible.
  • Audit every tool call that can modify state and log resource reads where privacy/regulatory concerns apply.
Next, this lesson will examine the surrounding ecosystem—primitives, protocols, and operational considerations—for safely wiring tools and resources to models and enforcing trust boundaries.

Watch Video