📦
Gateway Lite
No description available
0 installs
Trust: 30 — Low
Devtools
Ask AI about Gateway Lite
Powered by Claude · Grounded in docs
I know everything about Gateway Lite. Ask me about installation, configuration, usage, or troubleshooting.
0/500
Loading tools...
Reviews
Documentation
MCP Gateway Lite
Lightweight open-source MCP gateway that aggregates public MCP server metadata and exposes two MCP tools:
searchto discover servers/tools across registriesexecuteto run tools on remote-capable upstream servers
The gateway keeps the agent tool surface small while preserving broad MCP ecosystem coverage.
Features
- Streamable HTTP MCP endpoint (
/mcp) - Gateway auth (API key or Bearer token)
- Encrypted credential vault (AES-256-GCM + HKDF)
- OAuth 2.1 + PKCE callback flow
- Multi-source registry sync:
- Official MCP Registry
- PulseMCP
- Smithery
- Semantic search with PostgreSQL + pgvector (HNSW)
- Docker, Railway template, and GitHub Actions CI
Architecture
- Runtime: Node.js 22+
- Framework: Hono
- MCP SDK:
@modelcontextprotocol/sdk - DB: PostgreSQL +
pgvector - ORM: Drizzle
Core flow:
- Sync jobs ingest registry metadata into local Postgres
- Embeddings are generated and indexed for semantic retrieval
- Agent calls
searchto find tools - Agent calls
executeto proxy tool calls to remote MCP servers
Quick Start
1) Install dependencies
pnpm install
2) Configure environment
cp .env.example .env
Generate a 32-byte base64 master key:
openssl rand -base64 32
Put that value in MASTER_ENCRYPTION_KEY.
3) Start Postgres with pgvector
docker compose up -d postgres
4) Generate and run migrations
pnpm db:generate
pnpm db:migrate
5) Optional seed data
pnpm db:seed
6) Run the gateway
pnpm dev
Health endpoint:
GET /health
MCP endpoint:
POST /mcp
Environment Variables
See .env.example for full list. Main variables:
DATABASE_URL: Postgres connection stringMASTER_ENCRYPTION_KEY: Base64-encoded encryption root keyGATEWAY_API_KEY: Optional API key for gateway authBEARER_JWT_SECRET: Optional HS256 secret for Bearer authOPENAI_API_KEY: Optional, used for production embeddingsSYNC_INTERVAL_CRON: Registry sync scheduleALLOWED_ORIGINS: Comma-separated allowed origins for inbound requests
Auth Endpoints
POST /auth/credentialsstores API key/Bearer credentials for upstream servicesPOST /auth/oauth/startstarts OAuth flow and returnsauthUrlGET /oauth/callbackfinalizes OAuth code exchange
Commands
pnpm lintpnpm typecheckpnpm testpnpm buildpnpm sync:runpnpm rotate-keys
Deployment
Docker
docker compose up -d
Railway
railway.jsonis included- set environment variables from
.env.example - ensure Postgres has
pgvectorenabled - use
/healthfor service health checks
Security
See SECURITY.md for vulnerability reporting and hardening notes.
License
MIT
