Boilerplate
TypeScript Model Context Protocol (MCP) server boilerplate providing IP lookup tools/resources. Includes CLI support and extensible structure for connecting AI systems (LLMs) to external data sources like ip-api.com. Ideal template for creating new M
What is Boilerplate?
Boilerplate is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to typescript model context protocol (mcp) server boilerplate providing ip lookup tools/resources. includes cli support and extensible structure for connecting ai systems (llms) to external data sources ...
TypeScript Model Context Protocol (MCP) server boilerplate providing IP lookup tools/resources. Includes CLI support and extensible structure for connecting AI systems (LLMs) to external data sources like ip-api.com. Ideal template for creating new M
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- TypeScript Model Context Protocol (MCP) server boilerplate p
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx boilerplateConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Boilerplate
The Boilerplate MCP Server is a production-ready TypeScript starter template for building MCP servers, shipping with a fully functional IP geolocation tool powered by ip-api.com as a working reference implementation. It demonstrates best practices including dual transport modes (stdio and HTTP with Server-Sent Events), token-efficient TOON output format, JMESPath filtering, optional CLI usage, and parameterized resource URI templates. Developers use it as a foundation to build their own MCP servers with external data source integrations, removing the scaffolding overhead and letting them focus on domain-specific tool logic.
Prerequisites
- Node.js 18+ and npm
- Git to clone the repository
- An MCP-compatible client such as Claude Desktop, Cursor, or VS Code
- Optional: an ip-api.com API token for extended geolocation data (ASN, organization details)
Clone and install dependencies
Clone the boilerplate repository and install Node.js dependencies. This is the starting point for both using the IP lookup tools and customizing the server for your own use case.
git clone https://github.com/aashari/boilerplate-mcp-server.git
cd boilerplate-mcp-server
npm installBuild the TypeScript source
Compile the TypeScript code to JavaScript. The build output is required before running the server or CLI.
npm run buildConfigure environment variables
Set optional environment variables to customize behavior. IPAPI_API_TOKEN enables extended geolocation features; DEBUG enables verbose logging. These can be set in your shell or in the MCP client config's env block.
# Optional: extend ip-api.com capabilities
export IPAPI_API_TOKEN=your_token_here
export DEBUG=false
export TRANSPORT_MODE=stdio # or 'http'
export PORT=3000Test the CLI tools
Before connecting an MCP client, verify the server works by running the built-in CLI commands to look up IP addresses.
npm run cli -- get-ip-details 8.8.8.8
npm run cli -- get-ip-details 8.8.8.8 --include-extended-data
npm run cli -- get-ip-details 8.8.8.8 --jq "{ip: query, country: country}"Configure your MCP client
Add the boilerplate server to your Claude Desktop configuration. Use the absolute path to the built server entry point.
{
"mcpServers": {
"boilerplate": {
"command": "node",
"args": ["/absolute/path/to/boilerplate-mcp-server/dist/index.js"],
"env": {
"TRANSPORT_MODE": "stdio",
"DEBUG": "false",
"IPAPI_API_TOKEN": "optional_token"
}
}
}
}Customize and extend for your use case
Replace or extend the IP lookup tools with your own domain logic. The `src/tools/` directory contains the tool definitions and `src/resources/` contains the URI template implementations — follow the same patterns to add new tools.
# Run in development with hot-reload inspection:
npm run mcp:inspectBoilerplate Examples
Client configuration
Claude Desktop configuration for the boilerplate MCP server running in stdio mode.
{
"mcpServers": {
"boilerplate": {
"command": "node",
"args": ["/Users/yourname/boilerplate-mcp-server/dist/index.js"],
"env": {
"TRANSPORT_MODE": "stdio",
"DEBUG": "false",
"IPAPI_API_TOKEN": ""
}
}
}
}Prompts to try
Use the built-in IP geolocation tools to test your MCP server connection and demonstrate what a complete MCP tool interaction looks like.
- "What is the geolocation of the IP address 8.8.8.8?"
- "Look up my current public IP address and tell me what country I'm in"
- "Get extended details for IP 1.1.1.1 including the ASN and organization"
- "Look up IP 192.0.2.1 and return only the country and city fields"Troubleshooting Boilerplate
Extended data fields are missing from IP lookup results
Extended data (ASN, organization) requires an ip-api.com Pro API token. Set the IPAPI_API_TOKEN environment variable in your MCP config. Without it, the free tier returns only basic geolocation fields.
HTTP transport mode returns CORS or DNS rebinding errors
The HTTP server binds to localhost only and enforces origin validation to prevent DNS rebinding attacks. Ensure your MCP client connects to `http://localhost:3000` (or your configured PORT) and not via a domain name or external IP.
TypeScript compilation errors when modifying the source
Run `npm run build` after every source change. If you see type errors, check that you are using Node.js 18+ (`node --version`) and that your custom tool follows the same interface as the existing `ip_get_details` tool in `src/tools/`.
Frequently Asked Questions about Boilerplate
What is Boilerplate?
Boilerplate is a Model Context Protocol (MCP) server that typescript model context protocol (mcp) server boilerplate providing ip lookup tools/resources. includes cli support and extensible structure for connecting ai systems (llms) to external data sources like ip-api.com. ideal template for creating new m It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Boilerplate?
Follow the installation instructions on the Boilerplate GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Boilerplate?
Boilerplate works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Boilerplate free to use?
Yes, Boilerplate is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Boilerplate Alternatives — Similar Developer Tools Servers
Looking for alternatives to Boilerplate? Here are other popular developer tools servers you can use with Claude, Cursor, and VS Code.
Ecc
★ 188.2kThe agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Javaguide
★ 155.8kJava 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发
Gemini CLI
★ 104.5kA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command in
Awesome MCP Servers
★ 87.3k⭐ Curated list of Model Context Protocol (MCP) servers - tools that extend Claude Desktop, Cursor, Windsurf, and other MCP clients with custom capabilities.
MCP Servers
★ 86.0kModel Context Protocol Servers
CC Switch
★ 77.5kA cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io
Browse More Developer Tools MCP Servers
Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Boilerplate in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Boilerplate?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.