BXUP Track progress & test yourself — free
Common Core · Playbook · Core · ~5 min read
COMMON CORE · PLAYBOOK · CORE

Connect an AI Assistant to a Tool with MCP

Model Context Protocol (MCP) is the emerging standard plug for giving AI assistants access to tools and data — filesystems, databases, ticketing systems, internal APIs — through small "MCP servers" that any MCP-capable assistant can use. It's the difference between pasting context into a chat and the assistant fetching context itself.

Tier: Core · Hands-on time: ~50 minutes

This playbook is the safe first connection: a read-only server, scoped narrowly, with you approving every action.

When to use

  • You repeatedly paste the same kind of context (files, records, docs) into an AI assistant and want it to read the source directly.
  • Your team is evaluating agentic workflows and you need hands-on MCP literacy before opinions.
  • You want to understand what your IDE/assistant means when it lists "MCP servers" in settings.

Prerequisites

  • An MCP-capable client: current desktop AI assistants, agentic CLI tools, and major AI-enabled IDEs all support MCP server configuration.
  • Node.js installed (node --version ≥ 18) — most reference MCP servers run via npx.
  • A test folder of non-sensitive files to expose, e.g. ~/mcp-sandbox with a few Markdown notes copied in.
  • Rule for this playbook: read-only capability, non-sensitive data, human approval on. Write access is a later, deliberate step.

The workflow

  1. Create the sandbox.

    mkdir -p ~/mcp-sandbox
    cp <a few harmless .md/.txt files> ~/mcp-sandbox/
    

    The server you're about to add will be able to read only this path — scoping by directory is your first MCP safety habit.

  2. Register the filesystem MCP server. In your client's MCP settings (a JSON config file or a settings UI — every client documents its location), add the reference filesystem server pointed at the sandbox:

    {
      "mcpServers": {
        "sandbox-files": {
          "command": "npx",
          "args": ["-y", "@modelcontextprotocol/server-filesystem",
                   "/Users/<you>/mcp-sandbox"]
        }
      }
    }
    

    CLI-style clients often accept the same thing as one command, e.g. mcp add sandbox-files -- npx -y @modelcontextprotocol/server-filesystem ~/mcp-sandbox under the client's own binary. Restart the client if it caches config.

  3. Verify the connection before trusting it. In a new chat, ask:

    What MCP tools do you currently have available? List each tool's name
    and what it does, and which server provides it.
    

    You should see the filesystem tools (list/read, and possibly write variants). Note which write-capable tools exist even though you don't intend to use them — knowing the exposed surface is the security habit.

  4. Run the first grounded task.

    Using the sandbox-files tools, list the files you can see, then read
    <one filename> and summarize it in 3 bullets. Tell me which tool calls
    you made.
    

    Your client will ask you to approve each tool call — read the approval dialogs instead of clicking through; each names the tool and arguments. Confirm the summary matches the file's real content.

  5. Probe the boundary. Ask it to read a file outside the sandbox (~/.ssh/config is a good canary). Correct behavior: the server refuses (path outside allowed root). If it succeeds, your scoping is wrong — fix the config before going further.

  6. Do one real (still read-only) task. Point the config at a real non-sensitive folder — meeting notes, a docs repo — and run a genuine workflow from this track against it, e.g. pb-02's action-item extraction with the assistant reading the transcript file itself. This is where MCP's value lands: context arrives without paste.

Warning

MCP tool descriptions and file contents both enter the model's context — a malicious or compromised server, or a document containing adversarial instructions, can steer the assistant ("prompt injection"). Read-only scope, trusted servers, per-call approval, and non-sensitive data are the four controls this playbook installs; keep all four until you have explicit reasons to relax one.

Tool variants

  • Desktop AI assistants (major vendors): JSON config or a connectors/extensions UI; friendliest approval prompts; best first client for this playbook.
  • Agentic CLI tools:mcp add-style registration; approvals in the terminal; naturally scriptable, and config lives in versionable dotfiles.
  • AI-enabled IDEs: MCP servers configured per-workspace or globally in settings; strongest fit when the tool being exposed is your codebase or dev tooling.

Verification

  • The tool-listing question (step 3) shows your server and its tools, and the assistant correctly attributes them to sandbox-files.
  • A file summary matches the actual file content — open it and check; a grounded read must beat memory.
  • The boundary probe failed correctly: out-of-scope path refused, and you saw the refusal in the tool output, not just the assistant's claim.
  • Every tool call in your session produced an approval prompt you saw — if calls execute silently, find and disable the client's auto-approve setting before continuing.

Pitfalls

  • Scoping wide "to be convenient." Pointing the filesystem server at ~ or / exposes SSH keys, browser profiles, and every client file you have. Narrow roots, always; add paths deliberately.
  • Auto-approving tool calls. One session of clicking "always allow" builds the habit that later approves a destructive write. Keep per-call approval through your entire learning phase.
  • Running unvetted community servers. An MCP server is arbitrary code with the access you granted. Prefer reference servers and official vendor servers; treat random registry finds like unaudited npm packages, because that's what they are.
  • Confusing the assistant's claims with tool output. "I read the file and it says…" — verify against the visible tool-call results the client displays, especially early on.
  • Skipping the boundary probe. A connection that's never been tested for refusal is a connection whose scope you're only assuming.

Restricted-environment variant

  • Client data changes the calculus: an MCP server reading client files sends their content into a hosted model's context — that's data egress, same as pasting. For restricted engagements, run the MCP client against a local model backend (several agentic CLI and IDE clients can target an Ollama endpoint from pb-07), keeping files, tools, and inference on-machine.
  • Expose curated copies, not live trees: mirror the minimum needed files into a scoped folder (the sandbox pattern is the compliance pattern too), pseudonymize per pb-03 where the identities aren't needed.
  • No stdio/local install allowed? Some organizations offer approved internal MCP servers over HTTP with SSO — use only those, and confirm with security whether MCP connections are covered by existing tool-approval policy before connecting anything to client systems.

Success criteria

  • A read-only MCP server registered, connected, and enumerated by your assistant, scoped to a directory you chose.
  • One real task completed where the assistant fetched its own context via approved tool calls — no pasting.
  • The boundary probe refused correctly, and you can show the refusal.
  • You can explain to a colleague what MCP is, what the approval prompts protect against, and why this connection was safe — in under two minutes, from your own session.
This is the free reading view. Open BXUP to track your progress, run the hands-on labs, and prove it with original, exam-pattern assessments.
© Anvi Innovate · BXUP — Be Exponentially Upskilled · BXUP is an independent learning platform, not affiliated with or endorsed by AWS, Microsoft, Google, NVIDIA, IBM, Salesforce, Databricks, Oracle or Anthropic. All trademarks belong to their respective owners. · bxup.in