sampling support in MCP clients

Which MCP clients support sampling, and how each claim is known. The protocol introduced it in 2024-11-05. It was deprecated in 2026-07-28.

Has sampling.context, sampling.tools.

Support

Client Kind Status Known from Revisions Notes
goose host ○ unsupported read, declared 2025-03-26, 2026-07-28 Removed in 7b68b47ff (2026-09-22, #12193). GooseClient has no create_message and declares no sampling capability, so rmcp 3.11.0's default handler answers method not found.
Codex CLI host ○ unsupported read 2025-06-18 Not in the declared capabilities and no create_message handler. The word appears in the codebase only for Codex's own model calls.
opencode host ○ unsupported read 2025-11-25 Not declared, and no sampling/createMessage handler is registered. The commented-out key from the old client is gone.
Cline * host ○ unsupported read 2024-11-05, 2025-11-25 Both surfaces initialize with an empty capabilities object by default, and no CreateMessageRequestSchema handler exists.
fast-agent framework ● full read 2026-07-28 Declared and served by default: auto_sampling is on, so a server gets a sampling capability unless the config turns it off. The model is the server entry's sampling.model, else the agent's model, else the global default; with none of those the request fails with an internal error rather than falling back. A failure is returned as ErrorData, so a sampling problem does not break the connection.
OpenClaw * host ○ unsupported read 2025-11-25 Not declared and not implemented for configured servers. A sampling/createMessage handler exists only on the native projection bridge, registered when a borrowing caller supplies a sampling capability, and nothing in production acquires that view.
Hermes Agent host ● full read, declared 2025-11-25 Declared and served by default: sampling.enabled defaults to true on the server entry. Requests are rate-limited, ten a minute by default, audited to the log with model and token counts, and a failure is returned as ErrorData. A docstring records sampling as deprecated upstream under SEP-2577 and freezes the handler.
Kilo Code * host ○ unsupported read 2025-11-25 Commented out in the capability object, against opencode issue 11948. Kilo kept opencode's comments and links.
Mastra framework ○ unsupported read, declared 2026-07-28 Not declared, and no sampling/createMessage handler is registered. MCPClientCapabilities admits only elicitation and extensions, and its comment calls sampling deprecated and unsupported. 1.x had it; the 2.0.0 changelog lists it as removed.
fx (native engine) host ○ unsupported read 2025-11-25, 2026-07-28 Never declared. A 2026 input_required round that asks for sampling ends the call as unsupported input. A 2025 sampling/createMessage request gets -32601.
libfx (fx JavaScript adapter) * framework ○ unsupported read 2025-11-25 libfx registers no sampling handler and does not touch the client's capabilities. A Client constructed without options declares none: the probe's initialize capture shows "capabilities": {}. An application can register its own handler on its client. libfx offers its model to no such handler.
eve framework ○ unsupported read 2026-07-28 Not declared: the capabilities object is {}. The SDK answers sampling/createMessage with -32601. On 2026-07-28 an input request other than form elicitation fails the call.
pi * host ○ unsupported read 2025-11-25 Not declared. The client registers handlers for ping and roots/list only, so sampling/createMessage is answered with -32601 Method not found. The pi-mcp README lists sampling as outside the initial core.
Strands Agents framework ○ unsupported read, declared 2026-07-28 ClientSession is built with no sampling callback and MCPClient has no parameter for one, so the capability is not declared and the SDK answers a request with an error. TypeScript: the capability object has no sampling key, and a task input request for sampling throws CapabilityNotSupported.
crewAI * framework ○ unsupported read 2025-11-25 Not declared. No sampling_callback is passed, so the SDK leaves sampling out of the capabilities and answers a sampling/createMessage request with an Invalid Request error, "Sampling not supported".
deepagents * framework ○ unsupported read, declared 2025-11-25 Declared to every server and not served. FastMCP's ProxyClient installs a forwarding handler by default, and the handler relays sampling/createMessage to the in-process router session, whose client deepagents-code builds with no handler. On deepagents-code 0.2.5 with fastmcp 4.1.2 and mcp 2.2.0 a server that sent sampling/createMessage got a JSON-RPC error: "Cannot send 'sampling/createMessage': this transport context has no back-channel for server-initiated requests." The loader code is the same at 87f6080d.
Google ADK (Python) framework ○ unsupported read 2026-07-28 On this path a server asks for sampling inside an InputRequiredResult. ADK calls call_tool without allow_input_required, the SDK raises, and the model receives an error dict. An application sampling_callback is still advertised in each request and is not called for tool calls. Read from source, not run.
Microsoft Agent Framework framework ◐ partial read 2026-07-28 Every framework-owned connection declares sampling, because MCPTool always passes its sampling_callback and the SDK declares the capability for any callback that is not its default. A default construction has no chat client, and the callback answers -32603 'No chat client available'. With a chat client and no sampling_approval_callback it answers -32600 and logs a warning. With both, the request goes to the chat client with maxTokens capped at 4096 and at most 25 requests per session. The framework marks its own sampling support deprecated. The probe's wire capture at 1.25.0 shows clientCapabilities {"sampling":{}} on every request. .NET: the clients the framework builds register no SamplingHandler and declare none.
Google Antigravity host ○ unsupported declared 2025-06-18
Claude Code host ○ unsupported declared 2025-06-18
Claude.ai host ○ unsupported declared 2025-06-18
ChatGPT host ○ unsupported declared 2025-06-18
Hugging Face Chat UI host ○ unsupported read 2026-07-28 Not declared and no handler. On a 2026-07-28 connection an input_required round that asks for sampling/createMessage is refused as an unsupported input request.
Cursor * host ○ unsupported declared 2025-06-18
Visual Studio Code * host ◐ partial read, declared 2025-06-18, 2025-11-25 Declared as a bare sampling: {} on every connection. The first request from a server asks the user, separately for requests made during a tool call and outside one, and chat.mcp.serverSampling can pre-approve servers and pick allowed models. Text, image and audio parts go to the chosen chat model. maxTokens, temperature and stopSequences are not passed, and the reply is text only.
n8n * host ○ unsupported read 2025-11-25 Every client is constructed with capabilities: {}.
Langflow * host ○ unsupported read 2025-11-25 Not declared. No sampling_callback is passed, so the SDK leaves sampling out of the capabilities and answers sampling/createMessage with an Invalid Request error.
mcp-use framework ◇ opt-in read 2026-07-28 Declared only when onSampling is passed to MCPClient, to a config root or to a server entry. The callback answers sampling/createMessage, and on a 2026-07-28 connection the SDK uses the same handler for input_required rounds. MCPAgent passes no callback. The option is marked deprecated in the source. Python: sampling_callback on MCPClient.
Zed * host ○ unsupported read 2025-11-25 ClientCapabilities is built with sampling: None. Server-to-client requests have no handlers.
TypeScript SDK Client sdk ◇ opt-in read 2025-11-25 Not declared by default. The application passes capabilities.sampling and registers setRequestHandler('sampling/createMessage'). The SDK validates the request and the handler result against the negotiated era, including the tool-use result shape when the request carries tools. The class comment marks sampling deprecated as of 2026-07-28 (SEP-2577).
Warp host ○ unsupported read 2026-07-28 Not declared. A sampling request reaches rmcp's default create_message, which returns method not found.
Reachy Mini conversation app host ○ unsupported read 2026-07-28 The SDK Client is built from the transport alone, with no sampling_callback, so the SDK declares no sampling capability.

Not recorded for Codex Desktop. A missing record is not the same as unsupported.

Rows describe each client on 2026-07-28. A row marked * is for the newest revision the client speaks, because it cannot negotiate 2026-07-28: 2025-11-25 for 12 clients.

Tiers are not ranked. read is a source read at a pinned commit, verified is a probe run, observed is telemetry, and declared is what the client or a curated list says. "Through" names the parent capability whose evidence a row rests on when it has none of its own.

By protocol revision

On 2025-11-25 these clients record a different row. The other clients' rows above hold on 2025-11-25 as well.

Client On 2026-07-28 On 2025-11-25 Notes on 2025-11-25
Google ADK (Python) ○ unsupported ○ unsupported Not declared by a default construction, and ADK ships no handler. McpToolset takes an optional sampling_callback and sampling_capabilities and passes them to ClientSession, and the SDK declares sampling when the callback is present. The handler and the model it calls are the application's.

goose, Hermes Agent, Google Antigravity, Claude Code, Claude.ai, ChatGPT, Warp, Reachy Mini conversation app have one set of rows for every revision they speak, not yet split by revision.

The matrix on 2025-11-25 shows every capability on that revision.

Where the tiers disagree

Evidence

goose:

Codex CLI:

opencode:

Cline:

fast-agent:

OpenClaw:

Hermes Agent:

Kilo Code:

Mastra:

fx (native engine):

libfx (fx JavaScript adapter):

eve:

pi:

Strands Agents:

crewAI:

deepagents:

Google ADK (Python):

Microsoft Agent Framework:

Google Antigravity:

Claude Code:

Claude.ai:

ChatGPT:

Hugging Face Chat UI:

Cursor:

Visual Studio Code:

n8n:

Langflow:

mcp-use:

Zed:

TypeScript SDK Client:

Warp:

Reachy Mini conversation app:

Google ADK (Python) on 2025-11-25:

Lifecycle

Revision Change
2024-11-05 Introduced.
2026-07-28 Server-initiated sampling/createMessage replaced by the Multi Round-Trip Requests (MRTR) inputRequests pattern (SEP-2322). Feature deprecated (SEP-2577)
2026-07-28 Deprecated. Earliest removal First revision released on or after 2027-07-28.

Integrate directly with LLM provider APIs.

SEP-2577.

Research notes

Kinds

Data

This page as JSON: /data/capabilities/sampling.json. All capabilities: /data/capabilities/index.json, and the matrix.