Claude Code Prompts test
Supportedall expectations observed.
Summary
- Client
- Claude Code 2.1.296
- Feature
- Prompts (
prompts.get) - Tested
- Protocol
- 2026-07-28 (modern era, observed on the wire)
- How
- Automated over stdio
- Lab version
- Not recorded (run before the lab's first commit), win32, Node v24.18.0
- Case
prompts.get.basic, definition hash71929438ab28
What was checked
- client discovered the prompt via prompts/list (seen on the wire)
- client fetched lab_greeting with the run's nonce as its argument (seen on the wire)
- the prompt's messages were sent to the model (seen in the client's output)
Protocol traffic
The opening exchange and each request the result depends on, with the lab server's reply, exactly as the server recorded them. Long payloads are truncated.
- #0 client to server: server/discover
{ "jsonrpc": "2.0", "id": "server-discover-probe-1", "method": "server/discover", "params": { "_meta": { "io.modelcontextprotocol/protocolVersion": "2026-07-28", "io.modelcontextprotocol/clientInfo": { "name": "claude-code", "title": "Claude Code", "version": "2.1.296", "description": "Anthropic's agentic coding tool", "websiteUrl": "https://claude.com/claude-code" }, "io.modelcontextprotocol/clientCapabilities": { "roots": { "listChanged": true }, "elicitation": { "form": {}, "url": {} } } } } } - #1 server to client: response
{ "result": { "supportedVersions": [ "2026-07-28" ], "capabilities": { "tools": { "listChanged": true }, "prompts": { "listChanged": true }, "resources": { "listChanged": true } }, "resultType": "complete", "ttlMs": 0, "cacheScope": "private", "_meta": { "io.modelcontextprotocol/serverInfo": { "name": "abw-mcp-lab", "version": "0.1.0" } } }, "jsonrpc": "2.0", "id": "server-discover-probe-1" } - #6 client to server: prompts/list
{ "jsonrpc": "2.0", "id": 1, "method": "prompts/list", "params": { "_meta": { "io.modelcontextprotocol/protocolVersion": "2026-07-28", "io.modelcontextprotocol/clientInfo": { "name": "claude-code", "title": "Claude Code", "version": "2.1.296", "description": "Anthropic's agentic coding tool", "websiteUrl": "https://claude.com/claude-code" }, "io.modelcontextprotocol/clientCapabilities": { "roots": { "listChanged": true }, "elicitation": { "form": {}, "url": {} } } } } } - #7 server to client: response
{ "result": { "prompts": [ { "name": "lab_greeting", "description": "MCP lab fixture: a prompt with one argument.", "arguments": [ { "name": "name", "description": "Name to include", "required": true } ] } ], "resultType": "complete", "ttlMs": 0, "cacheScope": "private", "_meta": { "io.modelcontextprotocol/serverInfo": { "name": "abw-mcp-lab", "version": "0.1.0" } } }, "jsonrpc": "2.0", "id": 1 } - #12 client to server: prompts/get
{ "jsonrpc": "2.0", "id": 4, "method": "prompts/get", "params": { "_meta": { "io.modelcontextprotocol/protocolVersion": "2026-07-28", "io.modelcontextprotocol/clientInfo": { "name": "claude-code", "title": "Claude Code", "version": "2.1.296", "description": "Anthropic's agentic coding tool", "websiteUrl": "https://claude.com/claude-code" }, "io.modelcontextprotocol/clientCapabilities": { "roots": { "listChanged": true }, "elicitation": { "form": {}, "url": {} } } }, "name": "lab_greeting", "arguments": { "name": "n639e2237978c133b" } } } - #13 server to client: response
{ "result": { "messages": [ { "role": "user", "content": { "type": "text", "text": "Reply with exactly this text and nothing else: PROMPT-OK-a1eed5e0e865 n639e2237978c133b" } } ], "resultType": "complete", "_meta": { "io.modelcontextprotocol/serverInfo": { "name": "abw-mcp-lab", "version": "0.1.0" } } }, "jsonrpc": "2.0", "id": 4 }
Client output
What the client's model said at the end of the run. Supporting evidence only; the status is decided by the traffic above.
PROMPT-OK-a1eed5e0e865 n639e2237978c133b PROMPT-OK-a1eed5e0e865 n639e2237978c133b
Test definition
id: prompts.get.basic
title: Client lists prompts and gets one with an argument
feature: prompts.get
specRevisions: [2025-11-25, 2026-07-28]
mode: automated
drive:
claude-code:
# Claude Code exposes MCP prompts as slash commands: /mcp__<server>__<prompt> <args>
prompt: /mcp__lab__lab_greeting {{nonce}}
manual:
instructions: >-
Invoke the lab_greeting prompt from the lab server with name "{{nonce}}".
Check whether the reply contains PROMPT-OK-{{marker}}.
expect:
- id: listed
kind: request
description: client discovered the prompt via prompts/list
method: prompts/list
- id: got
kind: request
description: client fetched lab_greeting with the run's nonce as its argument
method: prompts/get
match:
params.name: lab_greeting
params.arguments.name: "{{nonce}}"
- id: prompt-reached-model
kind: output
description: the prompt's messages were sent to the model
contains: PROMPT-OK-{{marker}}
{{nonce}} is replaced with a fresh random value for every run, and {{marker}} with a value derived from it that only the lab server knows. Why