Study notes · 10% of the exam

Elicitation, Multi Round-Trip Requests, Subscriptions and Tasks

In revision 2026-07-28 servers never send JSON-RPC requests. When a tool, prompt or resource read needs user input, a model completion or roots, the server returns an InputRequiredResult and the client retries the original request with the answers. Know the multi round-trip request (MRTR) rules and requestState security, the elicitation modes and their safety rules, the deprecated Sampling and Roots features, subscriptions/listen, the Tasks extension and how extensions are negotiated.

Key points

  1. 1

    MRTR: a server MAY answer tools/call, prompts/get or resources/read (and no other request) with resultType: "input_required", plus inputRequests (a map of elicitation/create, sampling/createMessage or roots/list requests) and/or an opaque requestState. It MUST include at least one of the two. Every ordinary result carries resultType: "complete".

  2. 2

    The retry is an independent request: it MUST use a new JSON-RPC id, MUST echo requestState exactly (and MUST NOT include one if none was given), and carries inputResponses keyed by the server's inputRequests keys. Neither field may be reused on other requests, including parallel ones. Because the server holds no pending state, any replica can handle the retry.

  3. 3

    requestState is attacker-controlled. If it affects authorization, resource access or business logic it MUST be integrity-protected (HMAC or AEAD) and rejected when verification fails. Servers SHOULD bind the authenticated principal, a short expiry and the originating request (method plus a digest of its parameters). At-most-once use (for example coupon redemption) MUST still be enforced server-side. Use AEAD when the contents must stay secret.

  4. 4

    MRTR edge cases: if needed input is missing, the server SHOULD re-ask with a new InputRequiredResult rather than error. Unknown extra keys SHOULD be ignored. Servers MUST NOT assume the client will fulfil the request or retry, and MUST NOT ask for features the client did not declare in that request's clientCapabilities.

  5. 5

    Elicitation form mode uses a flat object schema with primitive properties only: string (formats email, uri, date, date-time), number or integer, boolean, and single- or multi-select enums. No nested objects and no arrays of objects. An empty elicitation: {} capability means form mode only.

  6. 6

    Servers MUST NOT use form mode for passwords, API keys, access tokens or payment credentials. They MUST use URL mode, where the data never passes through the client. accept in URL mode means only consent to open the URL. The server learns the outcome on the retry, from requestState or its own stored state, because notifications/elicitation/complete and elicitationId were removed.

  7. 7

    URL-mode client rules: never pre-fetch the URL or its metadata, never open it without consent, show the full URL first, and open it so that neither client nor LLM can see the page (a system browser sheet, not an embedded web view). Servers MUST NOT put credentials or PII in the URL or use pre-authenticated URLs, and MUST check that the user who opens the URL is the one who triggered it (phishing defence).

  8. 8

    Third-party OAuth through URL mode makes the server an OAuth client. Third-party tokens MUST NOT transit the MCP client (not even encrypted inside requestState), so the server must store them bound to the user's identity. It must never pass through the client's MCP token. Response actions are accept, decline (an explicit no) and cancel (dismissed).

  9. 9

    Sampling (deprecated in 2026-07-28; migrate to direct LLM-provider APIs) lets a server borrow the client's model. modelPreferences holds cost, speed and intelligence priorities (0 to 1) plus advisory substring hints, and the client makes the final choice. maxTokens is required and MUST be respected. Tool loops need sampling.tools, tool-result-only user messages and a result for every tool use. toolChoice is auto, required or none. The includeContext values thisServer and allServers are deprecated.

  10. 10

    Roots (deprecated; migrate to tool parameters, resource URIs or server configuration) are file:// URIs that are informational only and never enforced. notifications/roots/list_changed was removed. While roots last, they travel inside an InputRequiredResult as roots/list.

  11. 11

    subscriptions/listen replaced resources/subscribe/unsubscribe and the HTTP GET stream. The client opts in to toolsListChanged, promptsListChanged, resourcesListChanged or resourceSubscriptions. The first message MUST be notifications/subscriptions/acknowledged, listing the honoured subset. Every notification carries io.modelcontextprotocol/subscriptionId, which equals the listen request's JSON-RPC id. A graceful end is a complete response to the listen request. Progress and log notifications stay on their own request's stream.

  12. 12

    The Tasks extension (io.modelcontextprotocol/tasks) is negotiated per request. The server returns resultType: "task" with taskId, ttlMs and pollIntervalMs, durably created first. The client polls tasks/get, answers input_required with tasks/update, and may send tasks/cancel (cooperative). There is no tasks/list or tasks/result. completed, failed and cancelled are terminal. Extensions are opt-in: clients declare them in clientCapabilities.extensions, servers in server/discover, and the supporting side falls back gracefully (MCP Apps tools still return text).

Common traps

  • Saying a 2026-07-28 server sends elicitation/create or sampling/createMessage as its own JSON-RPC request. Servers MUST NOT initiate requests; everything rides inside an InputRequiredResult.

  • Retrying with the same JSON-RPC id, or reusing an old requestState on a round that did not send one.

  • Trusting requestState because clients MUST NOT modify it. A malicious client can, so integrity protection is required, and base64 is not confidentiality.

  • Collecting an API key or password with a form-mode field, or putting a clickable link in a form message to dodge URL-mode consent.

  • Reading URL-mode accept as proof that the out-of-band flow succeeded.

  • Treating roots as a sandbox, or claiming Sampling and Roots were removed. They are deprecated and still work during the window (earliest removal: the first revision on or after 2027-07-28).

  • Expecting Last-Event-ID replay after a dropped listen stream. Resumability is gone, so re-subscribe and re-fetch.

  • Assuming tasks/cancel guarantees a cancelled status. Cancellation is cooperative, and a task may still complete.

Further reading

Suggest a resource

No extra reading for Elicitation, Multi Round-Trip Requests, Subscriptions and Tasks yet. Found a guide, video or cheat sheet that made it click? Share it and help the next learner.

Test yourself on Elicitation, Multi Round-Trip Requests, Subscriptions and Tasks

Ten questions, with the answer and explanation after each one.