go_mcp_server_moex
MOEX ISS через сервер Model Context Protocol (MCP), реализованный с помощью библиотеки mcp-go
claude mcp add --transport stdio hightemp-go_mcp_server_moex go run . \ --env MOEX_LANG="default lang for ISS requests when running via stdio (optional)" \ --env MOEX_BASE_URL="override base ISS URL (optional)"
How to use
This MCP server exposes selected MOEX ISS endpoints as an MCP service using the mcp-go library. It allows clients to query engine catalogs, markets, boards, securities and their history through MCP tools. The server can operate in multiple transports: stdio, HTTP, or SSE. When running in HTTP mode, the MCP endpoint is available at /mcp; in SSE mode the server publishes a streaming endpoint at /sse and a /message endpoint for sending requests. You can tailor language and base URL behavior via environment variables, and you can override per-request values with HTTP headers X-MOEX-LANG and X-MOEX-BASE-URL when using HTTP or SSE.
How to install
Prerequisites:
- Go 1.23 or newer installed on your machine
- Git (for cloning the repository) (optional if you already have the code)
Installation steps:
-
Clone the repository: git clone <repository-url> cd go_mcp_server_moex
-
Build or run directly with Go:
- Build a binary (if you prefer): go build -o go_mcp_server_moex
- Run using the Go tool (from repository root): go run .
-
Alternatively, use the provided Makefile to run with flags: make run ARGS="-transport sse -addr :8181"
Prerequisites recap: ensure Go is installed and the repository is accessible. The server uses flags to switch transport between stdio, HTTP, or SSE and to set the listening address.
Additional notes
Notes and tips:
- Transport options: -transport stdio (default), http, or sse. Address can be set with -addr, e.g., -addr :8080 or -addr :8181 for SSE.
- For HTTP and SSE, you can pass per-request overrides using headers: X-MOEX-LANG and X-MOEX-BASE-URL.
- Environment variables MOEX_LANG and MOEX_BASE_URL allow configuring default behavior when running via stdio; these can be overridden per request in HTTP/SSE.
- The MCP endpoints provided map to MOEX ISS resources, including list_engines, list_markets, list_boards, list_securities, and get_security_history. For list_securities, use MCP parameters like engine, market, and filters such as board, query, limits (first), sorting, language, etc. For get_security_history, supply engine, market, security and optional filters like from, till, limit, sort_order, and lang.
- If you encounter port conflicts, choose a different -addr, and ensure the selected transport matches your client expectations (e.g., SSE for streaming clients).
Related MCP Servers
sandbox
A Model Context Protocol (MCP) server that enables LLMs to run ANY code safely in isolated Docker containers.
github-brain
An experimental GitHub MCP server with local database.
temporal
Empowering AI with Workflow Orchestration
mcp-tts
MCP Server for Text to Speech
tasker
An MCP server for Android's Tasker automation app.
chromedp
MCP server for browser automation using chromedp