mcp-durable-object-client

MCP.Pizza Chef: Dhravya

The mcp-durable-object-client is an MCP client implementation leveraging durable objects to maintain persistent and stateful interactions with MCP servers. It demonstrates a practical pattern for using durable objects to manage client-server communication, enabling reliable, long-lived context handling for LLM workflows. This client facilitates real-time calls to MCP servers and processes responses, ideal for scenarios requiring durable state and consistent model context.

Use This MCP client To

Maintain persistent LLM context across sessions using durable objects Implement stateful MCP client-server communication patterns Test and develop MCP client workflows with durable object support Handle real-time model queries with durable state management Build reliable, long-lived AI agent interactions in web environments

README

🤖 MCP Client as a durable object

This example shows a working pattern using durable objects as an MCP client.

To start, install depdencies in / and /server

npm i

To start the server, run npm run start in server/

To start the client, run npm run start in /

Ask Can you add 5 and 6?

The client will make a call to the server, get the response and show it to the client.

License

MIT

mcp-durable-object-client FAQ

How do I start the mcp-durable-object-client?
Install dependencies with 'npm i' in both root and server directories, then run 'npm run start' in the root to start the client.
What is the role of durable objects in this MCP client?
Durable objects provide persistent, stateful storage and coordination, enabling the client to maintain context across requests.
Can this client communicate with any MCP server?
Yes, it can interact with MCP servers that follow the protocol, facilitating flexible client-server workflows.
Is this client suitable for production use?
This example demonstrates a working pattern; further customization and testing are recommended for production deployments.
What programming environment is required?
Node.js environment with npm package management is required to install dependencies and run the client and server.
How does the client handle model queries?
The client sends requests to the MCP server and displays the server's response, enabling interactive model-driven workflows.
What license governs this MCP client?
The mcp-durable-object-client is licensed under the MIT License.