Get the FREE Ultimate OpenClaw Setup Guide →

go -service

A JSON-RPC 2.0 compliant server implementing the Model Context Protocol (MCP) for note management (as an example)

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio andrewdonelson-go-mcp-server-service ./bin/dev/<platform>/notes-server

How to use

This MCP server is a JSON-RPC 2.0 compliant service for managing notes. It exposes a note storage system with a thread-safe API and supports command-line interface (cmd) and a background service component. Through the MCP protocol, clients can perform note CRUD-like operations, query notes via the custom note:// URI scheme, and utilize prompts such as summarize-notes to generate summaries of all stored notes. The available tools include add-note for adding new notes (name and content are required) and summarize-notes (with an optional style parameter like brief or detailed) to produce consolidated summaries. The server is designed to run in development or production (release) builds and can operate as a foreground CLI or as a system service, enabling background operation on supported platforms.

How to install

Prerequisites:

  • Go 1.21 or later
  • GNU Make (or compatible build tool)
  • Git

Installation steps:

  1. Clone the repository: git clone <repository-url> cd <repository-directory>

  2. Build for development (with debug symbols and race detection): make dev

  3. Build for a specific component if needed: make build-cmd # builds the command-line interface make build-service # builds the service component

  4. Run locally (examples):

    • Run the CLI: make run-cmd
    • Run the service: make run-service
  5. Alternative release builds (optimized and stripped): make release-all

    or for a specific platform

    make release-windows make release-linux make release-darwin

  6. When using Claude Desktop integration, configure mcpServers with the appropriate path to the binaries, as shown in the README configuration examples.

Additional notes

Notes:

  • The server supports cross-platform builds (Windows, Linux, macOS).
  • Use the MCP Inspector for debugging since the server runs over stdio. Example: npx @modelcontextprotocol/inspector ./bin/dev/<platform>/notes-server
  • Error codes follow JSON-RPC 2.0 conventions with additional custom codes (-32001, -32002).
  • For production, prefer release-build binaries placed under bin/release/<platform>/ and run the service binary (notes-service).
  • The repository structure includes cmd (CLI), service (service), and internal/server (core logic).

Related MCP Servers

Sponsor this space

Reach thousands of developers