GitHub Stars
863
User Rating
Not Rated
Favorites
0
Views
39
Forks
41
Issues
19
Installation
Difficulty
IntermediateEstimated Time
10-20 minutes
Requirements
Node.js: 18.0.0 or highernpm: 8.0.0 or higherInstallation
Installation
Prerequisites
Node.js: 18.0.0 or higher
npm: 8.0.0 or higher
Installation Steps
1. Clone Repository
bash
git clone https://github.com/basementstudio/xmcp.git
cd xmcp
2. Install Dependencies
bash
npm install
3. Create Application
To bootstrap a new application, run:bash
npx create-xmcp-app@latest
bash
npx init-xmcp@latest
Troubleshooting
Common Issues
Issue: Server won't start Solution: Check Node.js version and reinstall dependencies.Configuration
Configuration
Basic Configuration
Claude Desktop Setup
Edit~/.config/claude-desktop/claude_desktop_config.json (macOS/Linux) or
%APPDATA%\Claude\claude_desktop_config.json (Windows):
json
{
"mcpServers": {
"tool-name": {
"command": "npx",
"args": ["-y", "package-name"],
"env": {
"API_KEY": "your-api-key"
}
}
}
}
Configuration Example
Basic Configuration
json
{
"mcpServers": {
"example-mcp": {
"command": "node",
"args": ["server.js"],
"env": {
"PORT": "3000",
"LOG_LEVEL": "info"
}
}
}
}
Examples
Examples
Basic Usage
Programmatic Usage
javascript
// JavaScript example (Node.js)
const { MCPClient } = require('@modelcontextprotocol/client');
const client = new MCPClient();
await client.connect();
// Execute tool
const result = await client.callTool('toolName', {
parameter1: 'value1',
parameter2: 'value2'
});
console.log(result);
Use Cases
Rapid prototyping of new MCP applications
Integration of MCP features into existing Next.js or Express projects
Streamlining development with automatic tool registration using the file system
Building a real-time development environment utilizing hot reloading