Skip to main content
Glama

Polymarket MCP Server

WEB_STRUCTURE.txt7.34 kB
Polymarket MCP Web Dashboard - File Structure ============================================== polymarket-mcp/ │ ├── src/polymarket_mcp/web/ # Web Dashboard Application │ ├── __init__.py # Package initialization (4 lines) │ ├── app.py # FastAPI application (504 lines) │ │ ├── FastAPI app initialization │ │ ├── Global state management │ │ ├── HTML page routes (/, /config, /markets, /monitoring) │ │ ├── API endpoints (11 REST + 1 WebSocket) │ │ ├── Configuration management │ │ └── Real-time updates via WebSocket │ │ │ ├── static/ # Static assets │ │ ├── css/ │ │ │ └── style.css # Dark theme styling (843 lines) │ │ │ ├── CSS variables (dark theme) │ │ │ ├── Responsive layout │ │ │ ├── Component styles │ │ │ ├── Animations │ │ │ └── Mobile-friendly │ │ │ │ │ └── js/ │ │ └── app.js # Client-side JavaScript (503 lines) │ │ ├── Notification system │ │ ├── Formatting utilities │ │ ├── API communication │ │ ├── WebSocket management │ │ ├── Local storage │ │ └── Error handling │ │ │ └── templates/ # Jinja2 HTML templates │ ├── index.html # Dashboard home (236 lines) │ │ ├── MCP status display │ │ ├── Statistics cards │ │ ├── Trending markets │ │ ├── Quick actions │ │ └── WebSocket status │ │ │ ├── config.html # Configuration (229 lines) │ │ ├── Wallet information │ │ ├── Safety limit sliders │ │ ├── Trading controls │ │ ├── Save/Reset/Test │ │ └── Live preview │ │ │ ├── markets.html # Market discovery (369 lines) │ │ ├── Search interface │ │ ├── Category filters │ │ ├── Market table │ │ ├── Details modal │ │ ├── Analysis modal │ │ └── Auto-refresh │ │ │ └── monitoring.html # System monitoring (331 lines) │ ├── System information │ ├── Performance stats │ ├── Rate limit monitoring │ ├── Activity charts │ └── Real-time updates │ ├── WEB_DASHBOARD.md # Complete documentation (680 lines) │ ├── Feature descriptions │ ├── Installation guide │ ├── API endpoint reference │ ├── WebSocket protocol │ ├── Architecture overview │ ├── Security considerations │ ├── Troubleshooting guide │ └── Performance tips │ ├── DASHBOARD_SUMMARY.md # Implementation summary │ ├── Overview │ ├── File descriptions │ ├── Quick start │ ├── Testing │ └── Statistics │ ├── WEB_STRUCTURE.txt # This file │ ├── start_web_dashboard.sh # Launch script (executable) │ ├── Virtual env activation │ ├── Dependency check │ ├── Environment validation │ └── Dashboard launcher │ ├── test_web_dashboard.py # Test suite (executable) │ ├── Dependency verification │ ├── Import testing │ ├── Directory validation │ └── Route registration checks │ ├── pyproject.toml # Updated with: │ ├── fastapi>=0.104.0 │ ├── uvicorn>=0.24.0 │ ├── jinja2>=3.1.0 │ └── polymarket-web entry point │ └── README.md # Updated with web dashboard section ============================================== Total Implementation ============================================== Code Files: - Backend: 504 lines (Python) - Frontend: 1,165 lines (HTML) - Styling: 843 lines (CSS) - JavaScript: 503 lines (JS) - Documentation: 680 lines (Markdown) ──────────────────────────── Total: 3,695 lines Files Created: 12 - Web App: 8 files - Documentation: 2 files - Scripts: 2 files Features: - Pages: 4 (home, config, markets, monitoring) - API Endpoints: 12 (11 REST + 1 WebSocket) - Charts: 2 (line chart, bar chart) - Forms: 1 (configuration) - Modals: 1 (market details/analysis) - Real-time: 3 types (stats, markets, websocket) ============================================== Quick Start ============================================== 1. Install dependencies: cd /Users/caiovicentino/Desktop/poly/polymarket-mcp pip install -e . 2. Start dashboard: polymarket-web # or ./start_web_dashboard.sh 3. Access: http://localhost:8080 4. Test: python test_web_dashboard.py ============================================== API Endpoints ============================================== HTML Pages: GET / Dashboard home GET /config Configuration management GET /markets Market discovery GET /monitoring System monitoring REST API: GET /api/status MCP connection status GET /api/test-connection Test Polymarket API GET /api/markets/trending Trending markets GET /api/markets/search Search markets GET /api/markets/{id} Market details GET /api/markets/{id}/analyze AI analysis POST /api/config Update configuration GET /api/stats Dashboard statistics WebSocket: WS /ws Real-time updates ============================================== Browser Access ============================================== Pages: Dashboard: http://localhost:8080/ Config: http://localhost:8080/config Markets: http://localhost:8080/markets Monitoring: http://localhost:8080/monitoring API Examples: Status: http://localhost:8080/api/status Trending: http://localhost:8080/api/markets/trending?limit=10 Search: http://localhost:8080/api/markets/search?q=election WebSocket: ws://localhost:8080/ws ============================================== Tech Stack ============================================== Backend: - FastAPI 0.104+ Web framework - Uvicorn 0.24+ ASGI server - Jinja2 3.1+ Template engine - Pydantic 2.0+ Data validation Frontend: - HTML5 Semantic markup - CSS3 Custom styling - JavaScript (ES6+) Client-side logic - Chart.js 4.4+ Charting library - WebSockets Real-time updates ============================================== Status: PRODUCTION READY ✅ ==============================================

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/caiovicentino/polymarket-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server