fix: connect routing-mcp to claude.ai as custom MCP connector (project_create gap) #31

Open
opened 2026-05-27 20:21:32 +00:00 by mathias · 0 comments
Owner

Problem

project_create via the routing pod MCP is not reachable from claude.ai web sessions. The routing pod runs on koala at http://koala:30310/mcp (internal) and https://routing-mcp.d-ma.be/mcp (external via NPM) but is not connected as a claude.ai MCP connector.

Symptoms

When trying to use project_create from a claude.ai chat session, the tool is not available. The only connected MCPs are gitea-mcp, brain-mcp, and Google services.

Root cause

The routing pod exposes an MCP server with Dex JWT auth (MCP_AUDIENCE=claude-ai). To connect it as a claude.ai custom connector, it needs:

  1. A publicly reachable HTTPS URL (already done: routing-mcp.d-ma.be)
  2. OAuth 2.0 metadata at /.well-known/oauth-protected-resource (may already exist)
  3. The connector added in claude.ai settings → Connectors → Add custom connector

Steps to fix

1. Verify OAuth discovery endpoint works

curl https://routing-mcp.d-ma.be/.well-known/oauth-protected-resource

Should return JSON with resource and authorization_servers fields pointing to https://auth.d-ma.be.

2. If missing — add to routing pod

The routing pod needs to advertise its OAuth metadata. Check cmd/routing/main.go for existing well-known handler. If missing, add:

mux.HandleFunc("/.well-known/oauth-protected-resource", func(w http.ResponseWriter, r *http.Request) {
    w.Header().Set("Content-Type", "application/json")
    json.NewEncoder(w).Encode(map[string]any{
        "resource": "https://routing-mcp.d-ma.be/mcp",
        "authorization_servers": []string{"https://auth.d-ma.be"},
    })
})

3. Add connector in claude.ai

Settings → Connectors → Add custom MCP connector:

  • URL: https://routing-mcp.d-ma.be/mcp
  • Auth: OAuth (Dex)

4. Verify project_create is callable from claude.ai

Once connected, test:

routing:project_create(name="test-connector", description="test", hypothesis="connector works", folder="AGENTS", stack="go-web", private=true)

Acceptance criteria

  • /.well-known/oauth-protected-resource returns correct JSON
  • routing-mcp connector added in claude.ai settings
  • project_create callable from claude.ai chat session
  • End-to-end: new project created from claude.ai without terminal access

Related

  • hyperguild #11 (F3 finding — routing pod not reachable from claude.ai)
  • infra: routing deployment at routing-mcp.d-ma.be
## Problem `project_create` via the routing pod MCP is not reachable from claude.ai web sessions. The routing pod runs on koala at `http://koala:30310/mcp` (internal) and `https://routing-mcp.d-ma.be/mcp` (external via NPM) but is not connected as a claude.ai MCP connector. ## Symptoms When trying to use `project_create` from a claude.ai chat session, the tool is not available. The only connected MCPs are gitea-mcp, brain-mcp, and Google services. ## Root cause The routing pod exposes an MCP server with Dex JWT auth (`MCP_AUDIENCE=claude-ai`). To connect it as a claude.ai custom connector, it needs: 1. A publicly reachable HTTPS URL (already done: `routing-mcp.d-ma.be`) 2. OAuth 2.0 metadata at `/.well-known/oauth-protected-resource` (may already exist) 3. The connector added in claude.ai settings → Connectors → Add custom connector ## Steps to fix ### 1. Verify OAuth discovery endpoint works ```bash curl https://routing-mcp.d-ma.be/.well-known/oauth-protected-resource ``` Should return JSON with `resource` and `authorization_servers` fields pointing to `https://auth.d-ma.be`. ### 2. If missing — add to routing pod The routing pod needs to advertise its OAuth metadata. Check `cmd/routing/main.go` for existing well-known handler. If missing, add: ```go mux.HandleFunc("/.well-known/oauth-protected-resource", func(w http.ResponseWriter, r *http.Request) { w.Header().Set("Content-Type", "application/json") json.NewEncoder(w).Encode(map[string]any{ "resource": "https://routing-mcp.d-ma.be/mcp", "authorization_servers": []string{"https://auth.d-ma.be"}, }) }) ``` ### 3. Add connector in claude.ai Settings → Connectors → Add custom MCP connector: - URL: `https://routing-mcp.d-ma.be/mcp` - Auth: OAuth (Dex) ### 4. Verify project_create is callable from claude.ai Once connected, test: ``` routing:project_create(name="test-connector", description="test", hypothesis="connector works", folder="AGENTS", stack="go-web", private=true) ``` ## Acceptance criteria - [ ] `/.well-known/oauth-protected-resource` returns correct JSON - [ ] routing-mcp connector added in claude.ai settings - [ ] `project_create` callable from claude.ai chat session - [ ] End-to-end: new project created from claude.ai without terminal access ## Related - hyperguild #11 (F3 finding — routing pod not reachable from claude.ai) - infra: routing deployment at `routing-mcp.d-ma.be`
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mathias/hyperguild#31