Repository navigation
docs: WebMCP connection tool on docs; advertise WorkOS scopes in PRM - #495
Conversation
|
Preview deployment for your docs. Learn more about Mintlify Previews.
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Shadow risk calibration
Calibration result: agreement. Shadow risk never blocks or enables merge. Keep it in observation mode until roughly 50 pull requests have human-reviewed labels, then calibrate before considering any policy use. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 72003047a2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| | `T49_CONNECTED_CLIENTS_RESOLVE_SECRET` | the resolve shared secret | Required to call `/connected-clients/resolve` | | ||
| | `T49_MCP_ALLOWED_HOSTS` | include `mcp.terminal49.com` (if set at all) | Host allowlist; missing host → 403 | | ||
| | `T49_MCP_SCOPES_SUPPORTED` | **leave unset** | WorkOS only issues `openid/profile/email/offline_access`; advertising `mcp:tools` etc. causes `invalid_scope` | | ||
| | `T49_MCP_SCOPES_SUPPORTED` | `openid,profile,email,offline_access` | Advertised as `scopes_supported` in the PRM document. Must match what WorkOS issues (the AS metadata's `scopes_supported`); advertising scopes it doesn't issue, such as `mcp:tools`, causes `invalid_scope` | |
There was a problem hiding this comment.
Do not advertise
offline_access as a resource scope
When production is configured with this value, the Protected Resource Metadata makes clients treat offline_access as required for basic MCP access. The MCP 2026-07-28 authorization specification explicitly says protected resources SHOULD NOT include offline_access in scopes_supported, because clients that want refresh tokens add it independently after finding it in the authorization-server metadata; remove it from this PRM value and the smoke assertion. MCP authorization specification
AGENTS.md reference: AGENTS.md:L76-L79
Useful? React with 👍 / 👎.
Why
This is the Terminal49/API part of the isitagentready.com fixes. The website part is Terminal49/website#461, which adds the OAuth discovery redirects on terminal49.com and the site WebMCP tools.
What changed
docs/webmcp.js: registers one WebMCP tool,get_terminal49_mcp_connection, on the docs pages. Mintlify loads every.jsfile indocs/(likesegment.js). The tool returns the MCP URL, the transport, how to sign in (OAuth through auth.terminal49.com, or an API key), the protected-resource metadata URL, and the setup guide for each client.Mintlify already registers
search_docs,read_page,navigate_page,get_site_overview, andread_skillon our docs, so this adds only what those don't cover. The name is chosen not to collide with theirs. The script:document.modelContext(it also checksnavigator.modelContext)packages/mcp/WORKOS_MCP_SETUP.md:T49_MCP_SCOPES_SUPPORTEDchanges from "leave unset" toopenid,profile,email,offline_access, which is exactly what WorkOS issues. The real risk was always advertising scopes WorkOS doesn't issue (mcp:tools), and the row now says that. RFC 9728 and the auth.md check both expectscopes_supportedin the protected-resource metadata. The PRM smoke command now checks the value.Needs a Vercel change (not in this PR)
Set
T49_MCP_SCOPES_SUPPORTED=openid,profile,email,offline_accesson the MCP Vercel project (Production) and redeploy. The handler already supports it, and the existing tests inpackages/mcp/tests/oauth-metadata.test.tscover it. I don't have Vercel credentials in this environment.Checked
npm run checkandnpm testpass.terminal49.com/docs/mcp/home. It listed 6 tools (Mintlify's 5 plus this one), invoking it returned the connection details, and after re-running the script and callingnavigate_pagethere was still exactly 1 copy.Need help on this PR? Tag
@codesmith-botwith what you need.The PR appears safe to merge, with a non-blocking fix recommended for registration error cleanup.
Fix with agent prompt
Summary
Adds
get_terminal49_mcp_connectionto docs pages so browser agents can get the MCP URL, sign-in instructions, and client setup guides.dodeja explicitly leaves the production Vercel setting and redeploy outside this PR because they lack Vercel credentials.
Reviews (1) · Last reviewed commit: "docs(mcp): advertise the WorkOS scopes i..." · Reviewed by Greptile