@himorishige/hatago-server
@himorishige/hatago-server
Section titled “@himorishige/hatago-server”NPX-ready MCP Hub server for Claude Code and other AI assistants.
Quick Start
Section titled “Quick Start”# Run with npx (STDIO mode by default)npx @himorishige/hatago-server
# Run in HTTP mode for developmentnpx @himorishige/hatago-server --http
# With custom configurationnpx @himorishige/hatago-server --config ./hatago.config.json
Claude Code Integration
Section titled “Claude Code Integration”Add to your .mcp.json
:
{ "mcpServers": { "hatago": { "command": "npx", "args": ["@himorishige/hatago-server", "--stdio"] } }}
STDIO Mode (Default)
Section titled “STDIO Mode (Default)”- Designed for Claude Code and MCP-compatible clients
- Uses LSP-style framing over STDIO
- Protocol on stdout, logs on stderr
HTTP Mode
Section titled “HTTP Mode”- For development and debugging
- Provides
/mcp
,/sse
, and/health
endpoints - Provides
/metrics
when metrics are enabled (HATAGO_METRICS=1
) - Enable with
--http
flag
Options
Section titled “Options”--stdio Run in STDIO mode (default)--http Run in HTTP mode--config <path> Path to configuration file--host <string> HTTP server host (default: 127.0.0.1)--port <number> HTTP server port (default: 3535)--log-level <level> Log level (silent|error|warn|info|debug|trace)--help Show help--version Show version
Configuration
Section titled “Configuration”Create a hatago.config.json
:
{ "mcpServers": { "filesystem": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"] }, "github": { "url": "https://api.github.com/mcp", "type": "sse" } }}
Supports JSON with comments (JSONC):
{ // Local filesystem server "mcpServers": { "filesystem": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"] } }}
Environment Variables
Section titled “Environment Variables”HATAGO_CONFIG
- Configuration file pathHATAGO_HOST
- HTTP server hostHATAGO_PORT
- HTTP server portHATAGO_LOG_LEVEL
- Log levelHATAGO_LOG
- Set tojson
to enable JSON logs (stderr)HATAGO_METRICS
- Set to1
to enable in-memory metrics and expose/metrics
(HTTP mode only)
Priority Order
Section titled “Priority Order”- CLI arguments
- Environment variables
- Configuration file
- Defaults
Development
Section titled “Development”# Install dependenciespnpm install
# Buildpnpm build
# Development modepnpm dev
# Type checkpnpm typecheck
License
Section titled “License”MIT