Layerchart Docs
FreeNot checkedModel Context Protocol (MCP) server that provides structured access to LayerChart documentation and source code. This server enables AI agents to easily retriev
About
Model Context Protocol (MCP) server that provides structured access to LayerChart documentation and source code. This server enables AI agents to easily retrieve, search, and understand LayerChart components and examples.
README
A Mastra-powered Model Context Protocol (MCP) server that provides structured access to LayerChart documentation and source code. This server enables AI agents to easily retrieve, search, and understand LayerChart components and examples.
Production Deployment
| Mastra Cloud | https://layerchart.mastra.cloud |
Primary choice - Zero cold start, maximum responsiveness. |
|---|
- Append
/api/mcp/layerChart/ssefor the SSE transport (best for editors that keep long-lived connections). - Append
/api/mcp/layerChart/mcpfor the HTTP transport (handy for CLIs and quick one-off calls).
🚀 Features
- Route Discovery: List all available documentation and component routes.
- Hybrid Retrieval: Get documentation text from the website combined with raw source code from GitHub.
- Source Access: Fetch raw Svelte source code for both documentation pages (usage) and component implementations.
- Semantic Search: Search across the LayerChart repository to find relevant components and documentation.
Editor Setup
Mastra Cloud is the recommended deployment for all editors. It offers zero cold start and maximum responsiveness. SSE works best for editors that keep a persistent connection, while HTTP is handy for one-off requests and scripts.
Cursor / Windsurf / VS Code / Claude Desktop
Configure your editor to use the SSE endpoint:
{
"mcpServers": {
"layerchart-docs": {
"url": "https://layerchart.mastra.cloud/api/mcp/layerChart/sse"
}
}
}
Verification & Quick Tests
Test the MCP connection using mcp-remote or curl:
# Test MCP connection
npx mcp-remote https://layerchart.mastra.cloud/api/mcp/layerChart/mcp
# Check HTTP endpoint
curl -I https://layerchart.mastra.cloud/api/mcp/layerChart/mcp
Available Tools
Once installed, your AI assistant will have access to these tools:
list_docs- List all available documentation pages and component routes from LayerChart.get_doc- Get the documentation content for a specific route. Returns both rendered text and raw source code.get_source- Fetch raw source code for a documentation page (usage) or component implementation (implementation) directly from GitHub.search_docs- Search for documentation and components in the LayerChart repository.
Example Usage
After installing the MCP server in your editor, you can ask your AI assistant:
- "How do I use the BarChart component in LayerChart?"
- "Show me examples of using tooltips in LayerChart"
- "What are the props for the Axis component?"
- "Find documentation for the PieChart component"
📖 Programmatic Usage
import { MCPClient } from "@mastra/mcp";
const mcp = new MCPClient({
servers: {
layerchart: {
url: "https://layerchart.mastra.cloud/api/mcp/layerChart/sse",
},
},
});
// Get available tools
const tools = await mcp.getTools();
// Call a tool directly
const result = await mcp.callTool("layerchart", "search_docs", {
query: "BarChart",
});
🚀 Quick Start (Local Development)
- Install dependencies:
npm install
# or
bun install
- Run in development mode:
npm run dev
# or
bun run dev
- Build and run production:
npm run build
npm run start
📦 Scripts
| Script | Description |
|---|---|
dev |
Start Mastra in development mode |
build |
Build the Mastra project for production |
start |
Start the built Mastra server |
🗂️ Project Structure
src/
├─ mastra/
│ ├─ tools/
│ │ ├─ getDoc.ts # Hybrid text/code retrieval
│ │ ├─ getSource.ts # GitHub mapping and fetching logic
│ │ ├─ listDocs.ts # Sidebar scraping logic
│ │ └─ searchDocs.ts # GitHub Search API integration
│ └─ index.ts # Mastra configuration
Contributing
Contributions are welcome! Please follow these guidelines:
- Fork the repo and create a feature branch
- Follow Conventional Commits for commit messages
- Submit a PR describing your change
License
MIT
References
Installing Layerchart Docs
This server has no published package — it is built from source. Open the repository and follow its README.
▸ github.com/Michael-Obele/layerchart-docsFAQ
Is Layerchart Docs MCP free?
Yes, Layerchart Docs MCP is free — one-click install via Unyly at no cost.
Does Layerchart Docs need an API key?
No, Layerchart Docs runs without API keys or environment variables.
Is Layerchart Docs hosted or self-hosted?
Self-hosted: the server runs locally on your machine via the install command above.
How do I install Layerchart Docs in Claude Desktop, Claude Code or Cursor?
Open Layerchart Docs on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
GitHub
PRs, issues, code search, CI status
by GitHubFilesystem
Secure file operations with configurable access controls.
Memory
Knowledge graph-based persistent memory system.
Template MCP Server
A CLI tool to create a new Model Context Protocol server project with TypeScript support, dual transport options, and an extensible structure
by mcpdotdirectCompare Layerchart Docs with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All development MCPs
