- MCP Tools Usage From LangChain / Example in TypeScript
MCP Tools Usage From LangChain / Example in TypeScript
MCP Tools Usage From LangChain ReAct Agent / Example in TypeScript
Overview
What is the Simple MCP Client?
The Simple MCP Client is a straightforward implementation of a Model Context Protocol (MCP) client using LangChain and TypeScript, designed to demonstrate the use of MCP server tools.
How to use the Simple MCP Client?
To use the Simple MCP Client, follow these steps:
- Install the necessary dependencies using
npm install. - Set up your API key by copying the
.env.templateto.envand updating it with your credentials. - Run the application with
npm start.
Key features of the Simple MCP Client?
- Utilizes LangChain to interact with MCP servers.
- Supports parallel initialization of multiple MCP servers.
- Converts MCP tools into LangChain-compatible tools for easy integration.
- Includes support for both Anthropic's and OpenAI's language models.
Use cases of the Simple MCP Client?
- Building applications that require interaction with multiple language models.
- Developing tools that leverage the Model Context Protocol for enhanced functionality.
- Creating conversational agents that utilize LangChain's capabilities.
FAQ from the Simple MCP Client?
- What are the prerequisites for using the Simple MCP Client?
You need Node.js 16+, npm 7+, and an API key from either Anthropic or OpenAI.
- Is there a Python equivalent of this client?
Yes, a Python version is available at this link.
- Can I run this client without an API key?
No, an API key is required to access the language models.
Recommend Clients
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
CursorThe AI Code Editor
Cherry Studio๐ Cherry Studio is a desktop client that supports for multiple LLM providers.
HyperChatHyperChat is a Chat client that strives for openness, utilizing APIs from various LLMs to achieve the best Chat experience, as well as implementing productivity tools through the MCP protocol.
ChatWiseThe second fastest AI chatbotโข
MCP PlaygroundCall MCP Server Tools Online
Refact.aiOpen-source AI Agent for VS Code and JetBrains that autonomously solves coding tasks end-to-end.
Continueโฉ Create, share, and use custom AI code assistants with our open-source IDE extensions and hub of models, rules, prompts, docs, and other building blocks
Roo Code (prev. Roo Cline)Roo Code (prev. Roo Cline) gives you a whole dev team of AI agents in your code editor.
Y GuiA web-based graphical interface for AI chat interactions with support for multiple AI models and MCP (Model Context Protocol) servers.
A Sleek AI Assistant & MCP Client5ire is a cross-platform desktop AI assistant, MCP client. It compatible with major service providers, supports local knowledge base and tools via model context protocol servers .
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
chatmcpChatMCP is an AI chat client implementing the Model Context Protocol (MCP).
y-cli ๐A Tiny Terminal Chat App for AI Models with MCP Client Support
Cline โ #1 on OpenRouterAutonomous coding agent right in your IDE, capable of creating/editing files, executing commands, using the browser, and more with your permission every step of the way.
LutraLutra is the first MCP compatible client built for everyone
DeepChatYour AI Partner on Desktop
WindsurfThe new purpose-built IDE to harness magic
ZedCode at the speed of thought โ Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
MCP ConnectEnables cloud-based AI services to access local Stdio based MCP servers via HTTP requests
BACHAI-TWITTER-API45Twitter็ไธไบapi mcp