- Explore MCP Servers
- monorail-mcp-py
Monorail Mcp Py
What is Monorail Mcp Py
Monorail MCP is a self-hosted Model Context Protocol server designed for Monorail’s on-chain quote and trade APIs. It includes a Streamlit dashboard for real-time visualization and tracking of failed trades.
Use cases
Use cases include monitoring and analyzing trade failures, providing real-time quotes for token swaps, and integrating with trading bots or applications that require reliable transaction data.
How to use
To use monorail-mcp-py, clone the repository, configure the environment variables, build and run the API and dashboard using Docker. Access the API documentation and dashboard via the provided local URLs.
Key features
Key features include fetching swap quotes across multiple exchanges, requesting transaction data, automatic retries and failure logging, Slack alerts for failures, browsing persisted failed trades, and a Streamlit dashboard for visualizing trade failures.
Where to use
Monorail MCP can be used in the cryptocurrency trading sector, particularly for applications that require real-time trading data and failure tracking in decentralized finance (DeFi) environments.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is Monorail Mcp Py
Monorail MCP is a self-hosted Model Context Protocol server designed for Monorail’s on-chain quote and trade APIs. It includes a Streamlit dashboard for real-time visualization and tracking of failed trades.
Use cases
Use cases include monitoring and analyzing trade failures, providing real-time quotes for token swaps, and integrating with trading bots or applications that require reliable transaction data.
How to use
To use monorail-mcp-py, clone the repository, configure the environment variables, build and run the API and dashboard using Docker. Access the API documentation and dashboard via the provided local URLs.
Key features
Key features include fetching swap quotes across multiple exchanges, requesting transaction data, automatic retries and failure logging, Slack alerts for failures, browsing persisted failed trades, and a Streamlit dashboard for visualizing trade failures.
Where to use
Monorail MCP can be used in the cryptocurrency trading sector, particularly for applications that require real-time trading data and failure tracking in decentralized finance (DeFi) environments.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
Monorail MCP Server & Dashboard
A self-hosted Model Context Protocol (MCP) server for Monorail’s on-chain quote & trade APIs, plus a Streamlit dashboard to visualize and track failed trades in real time.
🚀 Features
- /quote: Fetch swap quotes across 11 exchanges (7k+ tokens).
- /trade/{token_pair}: Request ready-to-send transaction data.
- Automatic retries & failure capture:
- Failed calls get logged to SQLite.
- Slack alerts on each failure.
- Webhook callbacks support custom listeners.
- /failed-trades: Browse persisted failures via API.
- Streamlit Dashboard:
- Bar chart of failures by token pair
- Detailed trade-by-trade view
🛠️ Tech Stack
- FastAPI — MCP server
- Pydantic — request validation
- HTTPX — async HTTP client with retry logic
- SQLModel (SQLite) — lightweight persistence
- Slack SDK — real-time alerts
- Streamlit — dashboard UI
- Docker & Docker Compose — containerized deployment
- Railway.app — hosting
📦 Getting Started
-
Clone & configure
git clone https://github.com/life-agrees/monorail-mcp-py cd monorail-mcp-py cp .env.example .env # Edit .env with your BASE_URL, SLACK_BOT_TOKEN, SLACK_CHANNEL… -
Build & run API
docker build -t monorail-app . docker run -d -p 8000:8000 --env-file .env monorail-app -
Build & run Dashboard
docker build -f Dockerfile.dashboard -t monorail-dashboard . docker run -d -p 8501:8501 monorail-dashboard -
Visit
API docs: http://localhost:8000/docs
Dashboard: http://localhost:8501
☁️ Deploy
- Pushed to Docker Hub
docker tag monorail-app lifeagrees/monorail-app:latest docker push lifeagrees/monorail-app:latest - Deployed on Railway
API:https://monorail-mcp-py-production.up.railway.app/docs
DASHBOARD:https://monorail-mcp-py-production-ffd0.up.railway.app
What This Solves
- Speeds up AI agents’ access to aggregated on-chain swap quotes & trades
- Reliability: automatic retry/catch + failure logging & alerting
- Visibility: real-time dashboard & API for audit & debugging
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.










