bun
template for Bun + MCP server project
claude mcp add --transport stdio dotneet-bun-mcp-server bun run build
How to use
This MCP server template uses Bun as the runtime to scaffold and build an MCP server. It provides a minimal workflow for creating a Bun-based MCP server, building the server, and testing with the included tooling. The server can be extended by editing the generated project files (e.g., spec.txt and related MCP server code) and using Bun to run or build as needed. The typical cycle is to create the project, implement the MCP behavior, build the server, and then test or deploy the built artifacts. Tools mentioned here include Bun for project scaffolding and building, and the Inspector tool for testing and debugging the resulting distribution. After building, you can copy or install the built executable to a desired location and run it in your environment.
How to install
Prerequisites:
- Install Bun: follow instructions at https://bun.sh/ to install Bun on your system.
Step-by-step:
- Create a new Bun MCP server project bun create github.com/dotneet/bun-mcp-server new_project_name
- Navigate into the project directory cd new_project_name
- Implement your MCP server specifications
- Edit spec.txt to describe the MCP server behavior.
- Use Claude Code or other tools to implement the server according to the specifications.
- Build the server bun run build
- (Optional) Test and debug
- You can use the Inspector tool for testing and debugging: package_name=$(bun run show-package-name) npx @modelcontextprotocol/inspector dist/$package_name
- Install the built command cp dist/$package_name $HOME/bin/ Ensure $HOME/bin is in your PATH, or install to another location and reference that path when running.
Prerequisites recap:
- A working Bun installation
- Basic familiarity with editing spec.txt and implementing MCP server logic
- Node-like tooling (for testing with Inspector) if you choose to use npx inspector
Additional notes
Tips:
- The Bun-based workflow mirrors Node-like project setups; the key difference is Bun's fast bundling and execution. Use bun run build to produce the distributable you may copy to your PATH.
- If you encounter permission issues when copying to $HOME/bin, ensure the destination is writable and that your PATH includes it.
- When testing with Inspector, ensure the dist directory path and package name are correctly resolved from your Bun project configuration.
- Keep an eye on Bun’s compatibility with any native modules or dependencies your MCP server might rely on; some Node.js-only modules may require adjustments.
- If you later migrate to a different runtime, you can adapt the mcp_config to the appropriate command and args format for that runtime.
Related MCP Servers
iterm
A Model Context Protocol server that executes commands in the current iTerm session - useful for REPL and CLI assistance
mcp
Octopus Deploy Official MCP Server
furi
CLI & API for MCP management
editor
MCP Server for Phaser Editor
DoorDash
MCP server from JordanDalton/DoorDash-MCP-Server
mcp
MCP сервер для автоматического создания и развертывания приложений в Timeweb Cloud