TypeScript SDK¶
Build distributed MCP agents with TypeScript and zero boilerplate
Overview¶
The MCP Mesh TypeScript SDK provides a function-based API for building distributed agent systems:
mesh()- Wrap FastMCP with mesh capabilitiesagent.addTool()- Register tools with capabilities and tagsmesh.llm()- Create LLM-powered toolsagent.addLlmProvider()- Zero-code LLM providers
Installation¶
# Install the SDK
npm install @mcpmesh/sdk
# Install the CLI (if not already installed)
npm install -g @mcpmesh/cli
Quick Start¶
# View the quick start guide
meshctl man quickstart --typescript
# Or scaffold a new agent
meshctl scaffold --name my-agent --lang typescript
Documentation¶
For comprehensive documentation, use the built-in man pages:
meshctl man --list # List all topics
meshctl man <topic> --typescript # View TypeScript version
meshctl man <topic> --typescript --raw # Get markdown output
Key Topics¶
| Topic | Command | Description |
|---|---|---|
| Quick Start | meshctl man quickstart --typescript | Get started in minutes |
| Mesh Functions | meshctl man decorators --typescript | mesh(), addTool(), mesh.llm() |
| Dependency Injection | meshctl man di --typescript | How DI works |
| LLM Integration | meshctl man llm --typescript | Build AI-powered agents |
| Deployment | meshctl man deployment --typescript | Local, Docker, Kubernetes |