breaking2000/universal-connection-mcp
If you are the rightful owner of universal-connection-mcp 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.
The Universal Connection Platform with MCP Server is a comprehensive system designed to facilitate seamless connections between users across various services and tasks, accessible through any MCP-compatible client.
Universal Connection Platform with MCP Server
A complete end-to-end system for connecting users across any service or task, accessible through any MCP-compatible client (Claude.ai, OpenAI Playground, Cline, Continue, etc.).
System Architecture
┌─────────────────────────────────────────────────────────────────┐
│ RENDER.IO CLOUD PLATFORM │
└─────────────────────────────────────────────────────────────────┘
│
┌──────────────────┐ HTTPS/WSS │ HTTPS/WSS ┌──────────────────┐
│ MCP CLIENT A │◄─────────────────────────────►│◄─────────────────────────────►│ MCP CLIENT B │
│ │ │ │ │
│ • Claude.ai │ │ │ • OpenAI GPT │
│ • Cline │ ┌─────────────────────▼─────────────────────┐ │ • Continue │
│ • Continue │ │ MCP SERVER (Port 8001) │ │ • Custom Client │
│ • Custom Tools │ │ │ │ • Cursor │
└──────────────────┘ │ ┌─────────────────────────────────────┐ │ └──────────────────┘
│ │ SESSION MANAGER │ │
┌──────────────────┐ │ │ │ │ ┌──────────────────┐
│ MCP CLIENT C │◄─┼──┤ • Client-1: User-123 (Active) │ ├──►│ MCP CLIENT D │
│ │ │ │ • Client-2: User-456 (Active) │ │ │ │
│ • Claude Desktop│ │ │ • Client-3: User-789 (Active) │ │ │ • Windsurf │
│ • GitHub Copilot│ │ │ • Isolated token management │ │ │ • Zed Editor │
└──────────────────┘ │ └─────────────────────────────────────┘ │ └──────────────────┘
└─────────────────┬──────────────────────────┘
│ HTTP API Calls
▼
┌─────────────────────────────────────────────────────────────────┐
│ FASTAPI BACKEND (Port 8000) │
│ │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ │
│ │ AUTH │ │ SERVICES │ │ CONNECTIONS │ │
│ │ │ │ │ │ │ │
│ │ • OAuth │ │ • Discovery │ │ • Matching │ │
│ │ • JWT │ │ • Categories │ │ • Messaging │ │
│ └──────┬───────┘ └──────┬───────┘ └──────┬───────┘ │
│ │ │ │ │
│ ┌──────▼───────┐ ┌──────▼───────┐ ┌──────▼───────┐ │
│ │ PROFILES │ │ REVIEWS │ │ REALTIME │ │
│ │ │ │ │ │ │ │
│ │ • Skills │ │ • Ratings │ │ • WebSockets │ │
│ │ • Rates │ │ • Feedback │ │ • Pub/Sub │ │
│ └──────────────┘ └──────────────┘ └──────────────┘ │
└─────────────────────┬───────┬───────────────────────────────────┘
│ │
┌────────────────────▼─┐ ┌─▼─────────────────────┐
│ POSTGRESQL DB │ │ REDIS CACHE │
│ │ │ │
│ • Users & Profiles │ │ • Sessions │
│ • Services & Cats │ │ • Rate Limiting │
│ • Connections │ │ • Pub/Sub Messages │
│ • Messages │ │ • Temporary Data │
│ • Reviews │ │ • WebSocket State │
└──────────────────────┘ └───────────────────────┘
┌─────────────────────────────────────────────────────────────────────────────────────┐
│ DATA FLOW LEGEND │
├─────────────────────────────────────────────────────────────────────────────────────┤
│ 1. Client connects to MCP Server via HTTPS │
│ 2. MCP Server authenticates via OAuth (Google/GitHub/Discord) │
│ 3. Session created and stored in Redis with unique token │
│ 4. MCP tools proxy requests to FastAPI backend │
│ 5. FastAPI processes business logic and updates PostgreSQL │
│ 6. Real-time events published via Redis to WebSocket clients │
│ 7. Responses flow back through MCP Server to original client │
│ 8. Multiple clients can interact simultaneously with isolated sessions │
└─────────────────────────────────────────────────────────────────────────────────────┘
USER INTERACTION FLOW:
┌─────────────┐ ┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ User Login │───►│ Create │───►│ Search & │───►│ Connect & │
│ via OAuth │ │ Profile │ │ Discover │ │ Message │
└─────────────┘ └─────────────┘ └─────────────┘ └─────────────┘
│ │ │ │
▼ ▼ ▼ ▼
┌─────────────┐ ┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Session │ │ Skills & │ │ Service │ │ Real-time │
│ Management │ │ Availability│ │ Matching │ │ Collaboration│
└─────────────┘ └─────────────┘ └─────────────┘ └─────────────┘
Features
Core Platform Features
- OAuth Authentication: Support for Google, GitHub, and Discord
- User Profiles: Skills, availability, rates, and preferences
- Service Discovery: Browse and search services by category, tags, price
- Real-time Messaging: WebSocket-based messaging between users
- Connection Management: Request, accept, and track service connections
- Review System: Rate and review completed connections
- Multi-category Support: Technology, Education, Business, Creative, etc.
MCP Server Features
- Remote Access: HTTPS-based MCP server for universal access
- Multi-client Support: Unlimited concurrent connections from any MCP client
- Session Management: Isolated sessions for each connected client
- Full API Coverage: All platform features exposed as MCP tools
- Authentication: Secure OAuth-based authentication through MCP
Technology Stack
- Backend: FastAPI + PostgreSQL + Redis
- MCP Server: fastmcp 2.4.0
- Authentication: OAuth 2.0 (Google, GitHub, Discord)
- Real-time: WebSockets + Redis Pub/Sub
- Deployment: Docker + Render.io
Project Structure
universal-connection-mcp/
├── api/ # FastAPI backend
│ ├── app/
│ │ ├── auth/ # Authentication logic
│ │ ├── models/ # SQLAlchemy models
│ │ ├── routes/ # API endpoints
│ │ ├── services/ # Business logic
│ │ ├── utils/ # Utilities
│ │ ├── config.py # Configuration
│ │ ├── database.py # Database setup
│ │ └── main.py # FastAPI app
│ └── migrations/ # Alembic migrations
├── mcp-server/ # MCP server
│ └── src/
│ └── server.py # FastMCP server
├── database/ # Database schema
│ └── schema.sql
├── tests/ # Test suites
├── scripts/ # Utility scripts
├── docs/ # Documentation
├── docker-compose.yml # Local development
├── Dockerfile # Production image
├── pyproject.toml # Python dependencies
├── render.yaml # Render deployment
└── README.md
Quick Start
Prerequisites
- Python 3.11+
- PostgreSQL 14+
- Redis 6+
- Poetry (for dependency management)
Local Development Setup
-
Clone the repository
git clone https://github.com/yourusername/universal-connection-mcp.git cd universal-connection-mcp -
Install dependencies
poetry install -
Set up environment variables
cp .env.example .env # Edit .env with your configuration -
Start PostgreSQL and Redis
docker-compose up -d postgres redis -
Initialize the database
poetry run python -m scripts.init_db -
Run the API server
poetry run uvicorn api.app.main:app --reload --port 8000 -
Run the MCP server
poetry run python mcp-server/src/server.py
MCP Client Configuration
Claude Desktop
Add to your Claude Desktop configuration:
{
"mcpServers": {
"universal-connection": {
"url": "https://your-app.onrender.com/mcp",
"apiKey": "your-api-key"
}
}
}
Cline
Add to your Cline settings:
{
"mcp": {
"servers": [
{
"name": "universal-connection",
"url": "https://your-app.onrender.com/mcp"
}
]
}
}
OpenAI Playground
Use the MCP plugin with:
- Server URL:
https://your-app.onrender.com/mcp - Authentication: OAuth token from supported provider
Available MCP Tools
Authentication
auth_login- Authenticate with OAuth providerauth_logout- End current sessionget_current_user- Get authenticated user info
User Profiles
update_profile- Update user profileget_user_profile- Get profile by user ID
Services
list_categories- Get service categoriescreate_service- Create service offering/requestsearch_services- Search and filter servicesget_service- Get service details
Connections
create_connection- Request connectionlist_connections- List user connectionsupdate_connection_status- Accept/reject connections
Messaging
send_message- Send message in connectionget_messages- Get connection messages
Reviews
create_review- Review completed connectionget_user_reviews- Get user reviews
Deployment to Render.io
-
Create Render account at https://render.com
-
Create PostgreSQL database
- New > PostgreSQL
- Note the connection string
-
Create Redis instance
- New > Redis
- Note the connection URL
-
Deploy the application
# Push to GitHub git push origin main # Connect GitHub repo to Render # Use render.yaml for automatic configuration -
Set environment variables in Render dashboard
-
Access your MCP server
- URL:
https://your-app.onrender.com/mcp - Configure in your MCP client
- URL:
Testing
Run unit tests
poetry run pytest tests/
Test MCP server locally
poetry run python scripts/test_mcp_client.py
Test with multiple clients
# Terminal 1: Start servers
docker-compose up
# Terminal 2: Client 1
poetry run python scripts/simulate_client.py --client-id 1
# Terminal 3: Client 2
poetry run python scripts/simulate_client.py --client-id 2
Security Considerations
- All MCP connections require authentication
- OAuth tokens are never stored permanently
- Session tokens expire after 24 hours
- Rate limiting prevents abuse
- CORS configured for known MCP clients
- SQL injection protection via SQLAlchemy
- Input validation on all endpoints
Monitoring
- Prometheus metrics at
/metrics - Health check at
/api/v1/health - OpenTelemetry support (optional)
- Structured logging with correlation IDs
Contributing
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open Pull Request
License
MIT License - see LICENSE file for details
Support
- Documentation:
/docs - API Reference:
/api/v1/docs - Issues: GitHub Issues
- Discord: Join our server