Mcpinnit
Init your MCP server in 60 seconds.
Ask AI about Mcpinnit
Powered by Claude Β· Grounded in docs
I know everything about Mcpinnit. Ask me about installation, configuration, usage, or troubleshooting.
0/500
Reviews
Documentation
mcpinnit
Init your MCP server in 60 seconds.
mcpinnit is a scaffolding CLI for building custom MCP (Model Context Protocol) servers β for your own product, internal API, or any system that doesn't have an MCP server yet.
npx mcpinnit
MCP lets AI assistants like Claude, Cursor, and others call your tools directly. mcpinnit handles all the infrastructure so you can focus on writing your actual tool logic.
Not what you need? If you're looking to connect Claude to GitHub, Stripe, Slack, Notion etc. β those platforms already publish official MCP servers. mcpinnit is for when you're building your own.
What it does
- Scaffold β
npx mcpinnitgenerates a complete, working MCP server with tool definitions, Zod schemas, tests, Dockerfile, and README - Extend β
npx mcpinnit add-tooladds a new tool to an existing server and wires it up automatically - Test β
npx mcpinnit testlets you test tools locally without opening Claude Desktop - Connect β
npx mcpinnit install-claudewrites your Claude Desktop config automatically
Quick Start
npx mcpinnit
Answer a few questions, get a production-ready MCP server:
? What is your server name? βΊ weather-tools
? Short description? βΊ Fetch weather data for any location
? Choose transport layer: βΊ stdio (recommended)
? Choose language: βΊ TypeScript
? Add authentication? βΊ None
? Which tool templates to include? βΊ fetch, search
# If fetch is selected, two follow-up questions appear:
? API base URL? (optional) βΊ https://api.openweathermap.org
? Default HTTP method? βΊ GET
# For all servers:
? Environment variables your server needs? βΊ WEATHER_API_KEY
Then:
cd weather-tools
npm run build
npx mcpinnit test --tool fetch --input '{"url": "https://example.com"}'
Commands
| Command | Description |
|---|---|
npx mcpinnit | Scaffold a new MCP server interactively |
npx mcpinnit add-tool | Add a new tool to an existing MCP server |
npx mcpinnit test --tool <name> --input '<json>' | Test a specific tool |
npx mcpinnit test --all | Test all tools |
npx mcpinnit test --watch | Watch mode |
npx mcpinnit install-claude | Write Claude Desktop config |
Adding Tools to an Existing Server
Run this inside a scaffolded project to add another tool without starting from scratch:
cd my-server
npx mcpinnit add-tool
You'll be prompted for a name, description, and template pattern. mcpinnit will:
- Create
src/tools/<name>.tswith the chosen template - Create
tests/<name>.test.ts - Wire the tool into
src/server.tsandsrc/tools/index.tsautomatically - Add the tool entry to
.mcp/manifest.json
Then build and test:
npm run build
npx mcpinnit test --tool <name> --input '{}'
Tool Templates
These are pattern starters β not finished integrations. Each gives you a working skeleton with the right Zod schema shape and handler structure. You fill in your own logic.
| Template | Pattern | Example use case |
|---|---|---|
fetch | HTTP request/response | Call your internal REST API |
search | Query and return a list | Search your product's database |
crud | Create, read, update, delete | Manage resources in your system |
notify | Trigger a notification | Send alerts via your own service |
transform | Input β processed output | Run a calculation or data pipeline |
blank | Empty starting point | Anything that doesn't fit above |
Generated Project Structure
weather-tools/
βββ src/
β βββ index.ts β entry point
β βββ server.ts β MCP server + tool registration
β βββ tools/
β β βββ fetch.ts
β β βββ index.ts
β βββ types.ts
βββ tests/
β βββ fetch.test.ts
β βββ server.test.ts
βββ .mcp/
β βββ manifest.json β discovery manifest
βββ .env.example
βββ Dockerfile
βββ package.json
βββ tsconfig.json
βββ README.md
Tech Stack
- CLI: commander, @inquirer/prompts, chalk, ora, handlebars
- Generated servers: @modelcontextprotocol/sdk, zod, dotenv, vitest
Local Development
Prerequisites
- Node.js >= 18
- npm
Setup
git clone https://github.com/rizwan-rizu/mcpinnit.git
cd mcpinnit
npm install
Build
npm run build # compile TypeScript β dist/
npm run lint # type-check only (no emit)
Run the CLI locally
# Option A β run directly via tsx (no build needed)
npm run dev
# Option B β run the compiled output
node dist/cli/index.js
# Option C β link globally so `mcpinnit` works anywhere
npm link
mcpinnit --help
End-to-end test
The best way to verify everything works is to scaffold a server and test a tool:
# 1. Scaffold a test server
node dist/cli/index.js
# β answer prompts: name=my-test-server, stdio, TypeScript, None, fetch
# 2. Build the generated server
cd my-test-server
npm run build
# 3. Test a tool
node ../dist/cli/index.js test --tool fetch --input '{"url": "https://example.com"}'
# 4. Test all tools
node ../dist/cli/index.js test --all
# 5. Generate Claude Desktop config (optional)
node ../dist/cli/index.js install-claude
Expected output from step 3:
β
Tool: fetch
β± Latency: 312ms
π€ Input: {"url":"https://example.com"}
π₯ Output: {"status":200,"statusText":"OK",...}
β
Schema valid
β
Response within size limit (4.2kb / 25kb max)
Run unit tests
npm test # run vitest once
npm run test:watch # watch mode
Project structure
mcpinnit/
βββ src/
β βββ cli/
β β βββ index.ts β commander entry point + subcommands
β β βββ scaffold.ts β 5-question interactive flow
β β βββ install-claude.ts β Claude Desktop config writer
β βββ generator/
β β βββ typescript/
β β βββ index.ts β orchestrates file generation
β β βββ templates/ β Handlebars .hbs templates
β β βββ tools/ β one template per tool type
β βββ tester/
β β βββ runner.ts β spawns MCP server, sends tool calls via stdio
β β βββ validator.ts β schema + size + latency checks
β β βββ reporter.ts β formatted terminal output
β βββ utils/
β β βββ logger.ts β chalk + ora helpers
β β βββ files.ts β fs-extra + Handlebars render
β β βββ detect.ts β detect MCP project root / language
β βββ types.ts β shared TypeScript interfaces
βββ package.json
βββ tsconfig.json
Contributing
- Fork the repo
- Create a feature branch:
git checkout -b feat/my-feature - Keep each feature in its own commit
- Open a pull request against
main
Roadmap
- v0.1 β TypeScript scaffold + 6 tool templates + test runner + Claude Desktop config
- v0.1.1 β
add-toolcommand β extend existing servers without starting over - v0.2 Python support,
lintcommand, MCP Inspector integration (--inspectflag) - v0.3 Registry at mcpinnit.com β publish & discover community MCP servers
License
MIT
