mcp-server-python-boilerplate

mcp-server-python-boilerplate

3.2

If you are the rightful owner of mcp-server-python-boilerplate and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

Python MCP Server Boilerplate is a template repository for creating Python servers compliant with the Model Context Protocol (MCP).

The Python MCP Server Boilerplate provides a foundational implementation for building MCP servers, facilitating the integration of custom tools. The Model Context Protocol (MCP) is a communication protocol between Language Model Machines (LLMs) and servers, enabling LLMs to access external APIs, retrieve real-time data, and control applications or local systems. This project aims to simplify the development of MCP servers by offering a basic structure and sample tools, allowing developers to focus on extending functionality with their own tools. The server operates on a JSON-RPC over stdio basis, ensuring a standardized communication method. It also includes mechanisms for tool registration and execution, error handling, and logging, making it a robust starting point for MCP server development.

Features

  • Basic implementation of an MCP server using JSON-RPC over stdio.
  • Mechanisms for tool registration and execution.
  • Error handling and logging capabilities.
  • Sample tools for system information retrieval, current date and time, and echo functionality.
  • Extensibility for adding custom tools and supporting external module tool registration.

Tools

  1. get_system_info

    Retrieves system information.

  2. get_current_time

    Fetches the current date and time.

  3. echo

    Returns the input text as is.