Show HN: MCP Boilerplate – A rock-solid Model Context Protocol server

2 truly_sn 0 5/10/2025, 6:15:11 PM github.com ↗
I created an open-source MCP (Model Context Protocol) server boilerplate after encountering numerous issues with SSE connections timing out when connecting AI models to tools.

The Model Context Protocol enables AI models to interact with external tools through a standardized interface. While implementing MCP servers, I frequently ran into the "SSE error: terminated Body timeout" which led me to develop this boilerplate with: • Robust keepalive mechanisms (30-second intervals) • Proper SSE headers including Connection: keep-alive • Socket and response timeout disabling • Comprehensive error handling with retries • Heartbeat notifications

I've also included a centralized configuration system to make adjustments simple without modifying multiple files, proper session management, and example tools with TypeScript interfaces to help you extend the server.

My goal was to create a foundation that others could build upon without having to solve the same connection issues I faced.

I'd appreciate any feedback, suggestions, or contributions to make this even better.

Comments (0)

No comments yet