dgmulei/oauth-mcp-server
3.1
If you are the rightful owner of oauth-mcp-server 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.
A minimal OAuth-compliant MCP server designed to work with Claude Web's 'Connect' button.
Tools
2
Resources
0
Prompts
0
OAuth MCP Server
A minimal OAuth-compliant MCP (Model Context Protocol) server designed to work with Claude Web's "Connect" button.
Goal
Get Claude Web to connect via the "Connect" button and show "Connected" status.
Architecture
- Platform: Cloudflare Workers
- Transport: Server-Sent Events (SSE)
- Authentication: OAuth 2.0 with PKCE
- Protocol: MCP (Model Context Protocol)
Project Structure
oauth-mcp-server/
├── src/
│ ├── index.ts # Main worker entry point
│ ├── oauth/ # OAuth implementation
│ │ ├── endpoints.ts # OAuth endpoints (/authorize, /token, etc.)
│ │ └── utils.ts # JWT utilities, crypto functions
│ ├── mcp/ # MCP protocol implementation
│ │ ├── protocol.ts # MCP message handling
│ │ ├── tools.ts # Minimal tools (echo, ping)
│ │ └── transport.ts # SSE transport layer
│ └── types.ts # TypeScript type definitions
├── wrangler.toml # Cloudflare Workers configuration
├── package.json # Dependencies and scripts
├── tsconfig.json # TypeScript configuration
└── deployment.md # Deployment instructions for Windsurf
Development Setup
-
Install dependencies:
npm install -
Set up Cloudflare environment:
npx wrangler login -
Set secrets:
npx wrangler secret put JWT_SECRET -
Run locally:
npm run dev -
Deploy:
npm run deploy
Testing with Claude Web
- Deploy the worker to get your URL
- In Claude Web, click "Connect"
- Use your worker URL as the server endpoint
- Complete OAuth flow
- Verify "Connected" status appears
Next Steps for Windsurf
See deployment.md for detailed deployment and testing instructions.