0Pricing
MCP Academy · Lesson

Negotiating Capabilities

Check what features both sides support.

Negotiating Capabilities is a free MCP Academy lesson on CoddyKit — lesson 3 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the MCP Academy learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.

Not Everyone Speaks Every Feature

MCP is rich, but no client or server supports it all. So at startup both sides negotiate which features they have, like two devices agreeing on what they can do. 🤝

It Happens at Initialize

This deal is struck during the initialize handshake, the very first exchange. After it, each side knows what the other offers and what is off the table.

Two Capability Bundles

The client announces its clientCapabilities and the server announces its serverCapabilities. Each bundle is just a map of feature flags and small options.

What a Server Declares

A server lists what it provides: things like tools, resources, and prompts. If a key is absent, clients know not to expect that primitive from you.

"capabilities": { "tools": {}, "resources": {} }

What a Client Declares

A client lists features it can offer back, such as roots, sampling, and elicitation. That is how your server learns it may even ask for roots at all.

"capabilities": { "roots": {}, "sampling": {} }

Sub-flags Add Detail

A capability can hold extra options. For example, roots may carry listChanged: true, meaning the client will notify you when its root set changes.

"roots": { "listChanged": true }

Absence Means No

The rule is simple: if a capability is missing, treat the feature as unavailable. Never call something the other side never promised it could do.

Version Comes First

Alongside features, both sides send a protocolVersion. They must agree on a shared version, or the session is rejected before any real work begins.

The SDK Does the Heavy Lifting

You rarely build these maps by hand. The Python SDK fills in your server capabilities from the tools and resources you registered, then exchanges them for you.

Read the Other Side's Flags

After init, you can inspect the client capabilities your session captured. That check is exactly what guards an optional call like list_roots.

caps = ctx.session.client_params.capabilities

Negotiate Once, Trust Throughout

Capabilities are settled at startup and hold for the session. You can rely on them for the connection's life without re-negotiating on every call.

Quick Check

Recall when and how features get agreed on.

Recap: The Capability Deal

At initialize, client and server swap capability maps and a protocol version. A missing flag means unsupported, and the SDK builds and reads these for you. 🎯

Frequently asked questions

Is the “Negotiating Capabilities” lesson free?

Yes — the full text of “Negotiating Capabilities” is free to read here on the web, and the MCP Academy course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the MCP Academy course, upgrade to CoddyKit PRO.

What will I learn in “Negotiating Capabilities”?

Check what features both sides support. You practise MCP Academy with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.

Do I need any experience to start MCP Academy?

No prior experience is required. MCP Academy on CoddyKit is structured for beginners through advanced learners; this is — lesson 3 of 4, so you can start here or from the beginning and move at your own pace.

How long does the “Negotiating Capabilities” lesson take?

Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.

Can I write and run code in this MCP Academy lesson?

Yes. Every MCP Academy lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.

All lessons in this course

  1. What Roots Tell a Server
  2. Request the Client's Roots
  3. Negotiating Capabilities
  4. Respect Client Boundaries
← Back to MCP Academy