This project was created with create-xmcp-app and provides MCP (Model Context Protocol) tools for interacting with the Digiusher expense management platform.
First, install dependencies:
pnpm installThen run the development server:
pnpm devThis will start the MCP server with hot reloading enabled.
To build your project for production:
pnpm buildThis will compile your TypeScript code and output it to the dist directory.
After building the project, you can connect it to various MCP clients. The server uses STDIO transport for communication with MCP clients.
Most MCP clients require the absolute path to your Node.js executable. You can find it using:
macOS/Linux:
which nodeWindows (Command Prompt):
where nodeWindows (PowerShell):
Get-Command node | Select-Object -ExpandProperty SourceAdd this to your Claude Desktop configuration file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"digiusher": {
"command": "/absolute/path/to/node",
"args": ["/absolute/path/to/digiusher-mcp/dist/stdio.js"],
"env": {
"DIGIUSHER_TOKEN": "your_digiusher_api_token"
}
}
}
}Add this to your Cline MCP settings in VS Code:
Settings path: .vscode/cline_mcp_settings.json or Cline extension settings
{
"mcpServers": {
"digiusher": {
"command": "/absolute/path/to/node",
"args": ["/absolute/path/to/digiusher-mcp/dist/stdio.js"],
"env": {
"DIGIUSHER_TOKEN": "your_digiusher_api_token"
}
}
}
}For other MCP clients, use this general configuration format:
{
"command": "/absolute/path/to/node",
"args": ["/absolute/path/to/digiusher-mcp/dist/stdio.js"],
"env": {
"DIGIUSHER_TOKEN": "your_digiusher_api_token"
}
}- Replace
/absolute/path/to/nodewith the output from thewhich node(orwhere node) command - Replace
/absolute/path/to/digiusher-mcpwith the actual path to this project directory - Replace
your_digiusher_api_tokenwith your actual Digiusher API token - Security: Never commit your API token to version control
- You can obtain your Digiusher API token from the Digiusher platform settings
This project uses the structured approach where tools are automatically discovered from the tools directory:
src/tools- Tool definitions for MCP
Each tool is defined in its own file with the following structure:
import { z } from "zod";
import { type InferSchema, type ToolMetadata } from "xmcp";
export const schema = {
name: z.string().describe("The name of the user to greet")
};
export const metadata: ToolMetadata = {
name: "greet",
description: "Greet the user",
annotations: {
title: "Greet the user",
readOnlyHint: true,
destructiveHint: false,
idempotentHint: true
}
};
export default function greet({ name }: InferSchema<typeof schema>) {
return `Hello, ${name}!`;
}To add a new tool:
- Create a new
.tsfile in thesrc/toolsdirectory - Export a
schemaobject defining the tool parameters using Zod - Export a
metadataobject with tool information - Export a default function that implements the tool logic
The tool will be automatically discovered and registered by the xmcp framework.
Run the development server with hot reloading:
pnpm devAfter building, you can start the STDIO server:
pnpm start-stdioOr run it directly:
node dist/stdio.jsNote: For MCP client integration, you typically don't need to run this manually - the MCP client will start the server automatically using the configuration above.