Skip to content
{mcpdesc}

Use MCP shapes in interaction requests and responses

Interaction steps carry MCP values: elicitation requests and results, sampling requests, messages, and results, and roots lists. Each has the members its MCP type requires and defines.

Elicitation, sampling, and roots requests and responses in interaction steps have the members and member types of their MCP types.

Rule ID: mcp.interaction-message.members
Owner: mcp
Surface: ElicitRequest, ElicitResult, CreateMessageRequest, CreateMessageResult, ListRootsResult, Root
Kind: structural
Requirement level: must
Protocol versions: independent of the MCP protocol version
Document schema locations: #/$defs/elicitationInteractionRequest, #/$defs/elicitationInteractionFormRequest, #/$defs/elicitationInteractionUrlRequest, #/$defs/elicitationInteractionResponse, #/$defs/elicitationInteractionAcceptedResponse, #/$defs/elicitationInteractionDeclinedResponse, #/$defs/samplingCreateMessageRequest, #/$defs/samplingCreateMessageResult, #/$defs/samplingMessage, #/$defs/samplingMessageContent, #/$defs/samplingContentBlock, #/$defs/samplingModelHint, #/$defs/samplingModelPreferences, #/$defs/samplingRequestTool, #/$defs/samplingToolChoice, #/$defs/samplingToolResultContent, #/$defs/samplingToolUseContent, #/$defs/rootsListRequest, #/$defs/rootsListResult, #/$defs/rootDeclaration
Status: internal · Enforcement: internal

Source: expected-invalid/malformed-sampling-step.json · Selected: /tools/0/interactionExamples/summary/steps/0/request

{
"messages": [
{
"role": "user",
"content": {
"type": "text",
"text": "Summarize the release plan."
}
}
]
}

Source: expected-invalid/elicitation-response-unknown-member.json · Selected: /tools/0/interactionExamples/approval/steps/0/response

{
"action": "accept",
"content": {
"approved": true
},
"unexpected": true
}

Source: expected-invalid/discriminated-union-members.json · Selected: /tools/0/interactionExamples/invalid/steps/0

{
"type": "elicitation",
"request": {
"mode": "url",
"message": "Authorize",
"ur": "https://example.test/auth"
},
"response": {
"action": "accepted"
}
}

interaction.yaml at immutable tag v0.9.0-rc.3.