Skip to content

feat(mcp): retarget csoai.org/mcp routes to csoai-gspc-mcp worker - #38

Merged
CSOAI-ORG merged 1 commit into
mainfrom
cursor/mcp-route-retarget-2b84
Aug 23, 2026
Merged

feat(mcp): retarget csoai.org/mcp routes to csoai-gspc-mcp worker#38
CSOAI-ORG merged 1 commit into
mainfrom
cursor/mcp-route-retarget-2b84

Conversation

@CSOAI-ORG

Copy link
Copy Markdown
Owner

Problem

POST https://csoai.org/mcp returns 500 kind=no-token from sov-mcp-gateway.
The good worker already exists and is LIVE at https://csoai-gspc-mcp.nicholastempleman.workers.dev/mcp (returns 200, no auth required).

Smithery cannot scan csoai.org/mcp because the gateway demands auth that should not exist on public tools.

Solution

Retarget csoai.org/mcp* and www.csoai.org/mcp* routes onto the public-friendly csoai-gspc-mcp worker by declaring routes in wrangler.toml.

Changes

File Purpose
workers/csoai-gspc-mcp/wrangler.toml Worker config with routes for csoai.org/mcp*
workers/csoai-gspc-mcp/src/index.js MCP server (public initialize, tools/list, measure, verify, jail-probe)
.well-known/mcp.json References live server for MCP discovery
.well-known/mcp/server-card.json Smithery/MCP registry discovery card

What stays free/public (no Authorization)

  • initialize — no auth
  • tools/list — no auth
  • verify — free, loginless, no trust
  • measure / jail-probe — returns contract (metered issuance on keystone)

No key in Smithery. No SOV* branding in public chrome.

GHA Deployment Steps (REQUIRED FOR ROUTE FLIP)

After merge, a GHA workflow must run:

cd workers/csoai-gspc-mcp
npx wrangler deploy

Requirements:

  • CF_ACCOUNT_ID and CF_API_TOKEN secrets in GHA
  • The CF account must own the csoai.org zone
  • Worker routes beat Pages Functions for the same path — once deployed, the route flip is automatic

Route Conflict Note

The current sov-mcp-gateway worker owns csoai.org/mcp*. The new routes in this worker will take over that path once deployed (Cloudflare prioritizes the most recently deployed worker routes). No need to patch or redeploy sov-mcp-gateway.

Related

  • Supersedes PR #29 (DRAFT) which added the worker stub without routes
  • councilof.ai/mcp* route is handled by the councilof-ai repo (flagship Pages project), not this repo

Verification

After deploy, confirm:

curl -X POST https://csoai.org/mcp \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","method":"initialize","id":1}'
# Expected: 200 with serverInfo.name = "csoai-gspc-mcp"
Open in Web Open in Cursor 

Retarget csoai.org/mcp* and www.csoai.org/mcp* from sov-mcp-gateway
(500 kind=no-token) to the public-friendly csoai-gspc-mcp worker.

Changes:
- workers/csoai-gspc-mcp: worker with routes for csoai.org/mcp*
- .well-known/mcp.json: reference live MCP server
- .well-known/mcp/server-card.json: Smithery/MCP discovery card

The worker handles public initialize + tools/list without Authorization.
Free verify stays loginless. No key required in Smithery. No SOV* branding.

Deploy requires: cd workers/csoai-gspc-mcp && npx wrangler deploy
GHA workflow needs CF_ACCOUNT_ID + CF_API_TOKEN secrets.

Supersedes PR #29 (HOLD) which added the worker stub without routes.

Co-authored-by: Nicholas Templeman <nicholas@csoai.org>
@CSOAI-ORG
CSOAI-ORG marked this pull request as ready for review August 23, 2026 18:57
@CSOAI-ORG
CSOAI-ORG merged commit e9ccb31 into main Aug 23, 2026
11 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants