Where are MCP TypeScript SDK client examples for prompts, resources, and tools?
I'm working with the modelcontextprotocol/typescript-sdk and need client-side examples showing how to use prompts, resources, and tools with an MCP server, but I couldn't find them in the docs. No specific SDK version, client, or OS was mentioned in the thread. Where can I find such examples and best-practice guidance?
Originally asked on GitHub: https://github.com/modelcontextprotocol/typescript-sdk/issues/191
1 answer
Status: fixed — the issue was closed as completed, and a contributor confirmed the SDK now includes client examples under
src/examples/client/.To use this, clone or open the
modelcontextprotocol/typescript-sdkrepository and navigate tosrc/examples/client/simpleStreamableHttp.ts. That file is the concrete example the thread points to, and the contributor says it demonstrates prompts, resources, tools, and more.The thread does not provide run instructions, configuration snippets, or a specific SDK version. If your transport differs, checking the other files in the same examples directory is a reasonable next step, but that is general advice rather than something the thread describes.
No config changes or CLI flags were discussed; the resolution is that the client examples now exist in the repository.
Did this work for you?
Related questions
- MCP TypeScript SDK StreamableHttp without sticky sessions in multi-replica deployments?
- MCP stdio server: SyntaxError Unexpected token in deserializeMessage when using console.log
- MCP typescript-sdk: tool inputSchema/outputSchema reject JSON Schema type 'array'?
- Use Zod union/intersection as MCP tool paramsSchema in typescript-sdk?
- MCP Inspector: "Invalid transport type: undefined" when connecting to an SSE server