{"_id":"@caikengren-cli/create-mcp","_rev":"3-6faeb69241cff5216786679f6cdea3ea","name":"@caikengren-cli/create-mcp","dist-tags":{"latest":"0.0.6"},"versions":{"0.0.4":{"name":"@caikengren-cli/create-mcp","version":"0.0.4","keywords":["MCP Server cli","mcp cli","cli tools"],"author":{"name":"Gavin Tang"},"license":"MIT","_id":"@caikengren-cli/create-mcp@0.0.4","maintainers":[{"name":"fkcaikengren","email":"fkcaikengren@163.com"}],"homepage":"https://github.com/fkcaikengren/create-mcp#readme","bugs":{"url":"https://github.com/fkcaikengren/create-mcp/issues"},"bin":{"create-mcp":"dist/index.js"},"dist":{"shasum":"00c9ffea357551b92318a924ddd194d591dab431","tarball":"https://registry.npmjs.org/@caikengren-cli/create-mcp/-/create-mcp-0.0.4.tgz","fileCount":4,"integrity":"sha512-307mBpv1gbgmTdTrNXiiqlfwK2nqAdtdJ0Lqa3DqvyoIPDezXRBtNnqENnzZTTuZAANBy3jbfGu+r0xSyC+HMA==","signatures":[{"sig":"MEUCIQCUOAjxt4r8dbxxh6O6qN6FOEGqo6FcCJrCD/mgOOOQIAIgF1hII2ZkvSgw9wqL5iCob1qokeIU2J0YwVH77tnysq8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":4894},"main":"dist/index.js","type":"module","module":"dist/index.js","engines":{"node":">=18"},"gitHead":"4402f8f84aa2ecf3ddabada9184d71cb605adb01","private":false,"scripts":{"dev":"tsdown --watch","build":"tsdown","start":"tsx src/index.ts","release":"tsx scripts/release.ts","typecheck":"tsc -p tsconfig.json"},"_npmUser":{"name":"fkcaikengren","email":"fkcaikengren@163.com"},"repository":{"url":"git+https://github.com/fkcaikengren/create-mcp.git","type":"git"},"_npmVersion":"10.9.2","description":"创建MCP服务器脚手架的工具","directories":{},"_nodeVersion":"22.13.1","dependencies":{"chalk":"^5.6.2","prompts":"^2.4.2","fs-extra":"^11.3.2","minimist":"^1.2.8"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"packageManager":"pnpm@10.6.2","devDependencies":{"tsx":"^4.20.6","tsdown":"^0.16.8","typescript":"^5.9.3","@types/node":"^24.10.1","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","@types/minimist":"^1.2.5","semantic-release":"^25.0.2","standard-version":"^9.5.0"},"_npmOperationalInternal":{"tmp":"tmp/create-mcp_0.0.4_1764300748781_0.3028227289557295","host":"s3://npm-registry-packages-npm-production"}},"0.0.5":{"name":"@caikengren-cli/create-mcp","version":"0.0.5","keywords":["MCP Server cli","mcp cli","cli tools"],"author":{"name":"Gavin Tang"},"license":"MIT","_id":"@caikengren-cli/create-mcp@0.0.5","maintainers":[{"name":"fkcaikengren","email":"fkcaikengren@163.com"}],"homepage":"https://github.com/fkcaikengren/create-mcp#readme","bugs":{"url":"https://github.com/fkcaikengren/create-mcp/issues"},"bin":{"create-mcp":"dist/index.js"},"dist":{"shasum":"f7139ee6563e5e99d9346a3a24f38f3a5e0577ef","tarball":"https://registry.npmjs.org/@caikengren-cli/create-mcp/-/create-mcp-0.0.5.tgz","fileCount":17,"integrity":"sha512-KKtFMNWO7jWo8MD2pp/qgzNEdUhYB+clmxqE18ZeuMLFoHUNlhpgfKYGA6qyr/DJJ+6k2bgWlNWzCRA+zBLGdQ==","signatures":[{"sig":"MEUCIQDg4TzuYwFq3FJnTH8acgbRWB0JJwAawTTFvQ3CheebWgIgXyqDy4bz23y0n7cahUylkhgntxnqnlSAGPwOZywJRds=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":16283},"main":"dist/index.js","type":"module","module":"dist/index.js","engines":{"node":">=18"},"gitHead":"b3955baf9217b1fd3e23ee8e0ea962ef22d615c3","private":false,"scripts":{"dev":"tsdown --watch","build":"tsdown","start":"tsx src/index.ts","release":"tsx scripts/release.ts","typecheck":"tsc -p tsconfig.json"},"_npmUser":{"name":"fkcaikengren","email":"fkcaikengren@163.com"},"repository":{"url":"git+https://github.com/fkcaikengren/create-mcp.git","type":"git"},"_npmVersion":"10.9.2","description":"创建MCP服务器脚手架的工具","directories":{},"_nodeVersion":"22.13.1","dependencies":{"chalk":"^5.6.2","prompts":"^2.4.2","fs-extra":"^11.3.2","minimist":"^1.2.8"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"packageManager":"pnpm@10.6.2","devDependencies":{"tsx":"^4.20.6","tsdown":"^0.16.8","typescript":"^5.9.3","@types/node":"^24.10.1","@types/prompts":"^2.4.9","@types/fs-extra":"^11.0.4","@types/minimist":"^1.2.5","semantic-release":"^25.0.2","standard-version":"^9.5.0"},"_npmOperationalInternal":{"tmp":"tmp/create-mcp_0.0.5_1764302937665_0.511337049160824","host":"s3://npm-registry-packages-npm-production"}},"0.0.6":{"name":"@caikengren-cli/create-mcp","version":"0.0.6","description":"创建MCP服务器脚手架的工具","private":false,"publishConfig":{"registry":"https://registry.npmjs.org/","access":"public"},"type":"module","main":"dist/index.js","module":"dist/index.js","bin":{"create-mcp":"dist/index.js"},"packageManager":"pnpm@10.6.2","scripts":{"dev":"tsdown --watch","start":"tsx src/index.ts","build":"tsdown","typecheck":"tsc -p tsconfig.json","release":"tsx scripts/release.ts"},"repository":{"type":"git","url":"git+https://github.com/fkcaikengren/create-mcp.git"},"bugs":{"url":"https://github.com/fkcaikengren/create-mcp/issues"},"homepage":"https://github.com/fkcaikengren/create-mcp#readme","keywords":["MCP Server cli","mcp cli","cli tools"],"author":{"name":"Gavin Tang"},"license":"MIT","dependencies":{"chalk":"^5.6.2","fs-extra":"^11.3.2","minimist":"^1.2.8","prompts":"^2.4.2"},"devDependencies":{"@types/fs-extra":"^11.0.4","@types/minimist":"^1.2.5","@types/node":"^24.10.1","@types/prompts":"^2.4.9","semantic-release":"^25.0.2","standard-version":"^9.5.0","tsdown":"^0.16.8","tsx":"^4.20.6","typescript":"^5.9.3"},"engines":{"node":">=20"},"_id":"@caikengren-cli/create-mcp@0.0.6","gitHead":"014a93aacba1790936d7773908b142cce46cbac5","_nodeVersion":"22.13.1","_npmVersion":"10.9.2","dist":{"integrity":"sha512-ftyvHsmeBG1Paq+xyL0socMUhtTNBD2l8KX7jaH7k7TxaF2KEp76ik5xE/3JuBB7z75bmMdkafsgC4lwuW3MUQ==","shasum":"09101a610875258856a69908c00e864d34371efd","tarball":"https://registry.npmjs.org/@caikengren-cli/create-mcp/-/create-mcp-0.0.6.tgz","fileCount":18,"unpackedSize":19489,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQDHihI4kqHCcS/o5KkCuBuvvPm7KtDn8oRpJC5MbB0h+wIhAPd2Ujo+U3JwyDkcj/HA5YjBQHEIfGQNqaauqR2JRh7l"}]},"_npmUser":{"name":"fkcaikengren","email":"fkcaikengren@163.com"},"directories":{},"maintainers":[{"name":"fkcaikengren","email":"fkcaikengren@163.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/create-mcp_0.0.6_1764313583678_0.3097891549441172"},"_hasShrinkwrap":false}},"time":{"created":"2025-11-28T03:32:28.721Z","modified":"2025-11-28T07:06:24.123Z","0.0.4":"2025-11-28T03:32:28.965Z","0.0.5":"2025-11-28T04:08:57.859Z","0.0.6":"2025-11-28T07:06:23.881Z"},"bugs":{"url":"https://github.com/fkcaikengren/create-mcp/issues"},"author":{"name":"Gavin Tang"},"license":"MIT","homepage":"https://github.com/fkcaikengren/create-mcp#readme","keywords":["MCP Server cli","mcp cli","cli tools"],"repository":{"type":"git","url":"git+https://github.com/fkcaikengren/create-mcp.git"},"description":"创建MCP服务器脚手架的工具","maintainers":[{"name":"fkcaikengren","email":"fkcaikengren@163.com"}],"readme":"# create-mcp ⚡\n[![npm](https://img.shields.io/npm/v/@caikengren-cli/create-mcp?label=@caikengren-cli%2Fcreate-mcp)](https://www.npmjs.com/package/@caikengren-cli/create-mcp) [![node](https://img.shields.io/node/v/@caikengren-cli/create-mcp?label=node)](https://www.npmjs.com/package/@caikengren-cli/create-mcp)\n\n下一代 MCP 服务器脚手架，一键生成可运行的示例项目。\n\n## 特性\n- 即刻开始：通过 `pnpm dlx` 或 `npx` 无需全局安装\n- 模板齐全：`template-stdio`（标准输入输出）与 `template-streamable`（HTTP Stream）\n- 开箱可用：演示工具覆盖文件统计与实时天气查询\n- 极简交互：最少问题、自动更新模板项目 `package.json`\n- 现代构建：TypeScript、ESM、`tsdown` 构建与严格 `typecheck`\n- 许可证：MIT\n\n## 快速开始\n- 使用 `pnpm`：`pnpm dlx @caikengren-cli/create-mcp`\n- 使用 `npx`：`npx @caikengren-cli/create-mcp`\n\n随后按照提示选择模板并填写项目名。\n\n## CLI 用法\n```\nUsage: create-mcp [project-name] [options]\n\nCreate a new MCP server project from a template\n\nOptions:\n  -v, --version          output the version number\n  -t, --template <name>  Template to use\n  -h, --help             display help for command\n```\n\n示例：\n- 指定模板并创建：`npx @caikengren-cli/create-mcp my-server -t template-stdio`\n\n## 模板一览\n\n### template-stdio\n- 传输方式：`stdio`\n- 提供工具：`count_files`（统计指定目录下文件数量）\n- 主要文件：\n  - `src/server.ts` 注册工具与连接 `StdioServerTransport`\n  - `src/main.ts` CLI 入口（子命令 `run-server`）\n\n运行步骤：\n- 安装依赖：`pnpm install`\n- 构建代码：`pnpm build`\n- 运行并调试：\n  - 直接运行：`node dist/main.js run-server`\n  - 使用 Inspector：`pnpm inspect`\n\n工具输入：\n- `path` 目录路径，默认 `.`\n- `ignore` 忽略列表，默认 `['node_modules', '.git', 'dist']`\n\n### template-streamable\n- 传输方式：`HTTP Stream`（`/mcp` 路由）\n- 提供工具：`get_weather_now`（查询当前城市天气）\n- 主要文件：\n  - `src/server.ts` 注册工具与连接 `StreamableHTTPServerTransport`\n  - `src/core/seniverse.ts` 天气接口封装（心知天气）\n  - `src/core/index.ts` 从环境变量读取密钥\n\n项目根目录创建`.env`文件，添加环境变量：\n```\nSENIVERSE_PUBLIC_KEY=你的PublicKey\nSENIVERSE_SECRET_KEY=你的SecretKey\nPORT=3000\n```\n\n运行步骤：\n- 安装依赖：`pnpm install`\n- 构建代码：`pnpm build`\n- 启动服务：`node dist/main.js`\n- 访问接口：`http://localhost:3000/mcp`\n\n\n\n## 开发与构建\n- Node 要求：`>=20`\n- 安装依赖：`pnpm install`\n- 开发调试：`pnpm start`（运行本仓库 CLI 源码）或 `pnpm dev`（监视构建）\n- 生产构建：`pnpm build`\n- 类型检查：`pnpm typecheck`\n\n\n## 发布\n\n切换到 `release` 分支\n```\ngit checkout -b release\n```\n执行 `pnpm release` 发布。 \n```bash\npnpm release\n```\n然后就会自动，打包，发布npm包，打tag推送release，切回main分支并合并release分支.\n\n\n## 兼容性\n- 引擎：`node >= 20`\n\n\n## 变更日志\n- 请查阅 `CHANGELOG.md`\n\n## 许可证\n- MIT，详见 `LICENSE`\n","readmeFilename":"README.md"}