Boilerplate

v1.0.0Developer Toolsstable

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

aiai-integrationanthropicboilerplateclaude
Share:
70
Stars
0
Downloads
0
Weekly
0/5

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

TypeScript MCP server template for rapid development
IP lookup and external data source integration
aashari

Maintainer

LicenseMIT
Languagetypescript
Versionv1.0.0
UpdatedApr 15, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

Manual Installation

npx boilerplate

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

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)
1

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 install
2

Build the TypeScript source

Compile the TypeScript code to JavaScript. The build output is required before running the server or CLI.

npm run build
3

Configure 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=3000
4

Test 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}"
5

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"
      }
    }
  }
}
6

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:inspect

Boilerplate 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.

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.

Quick Config Preview

{ "mcpServers": { "boilerplate": { "command": "npx", "args": ["-y", "boilerplate"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

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.

33,000+ ServersFree & Open SourceStep-by-Step Guides