Repository navigation
fix(mcp): review findings: billing annotations, signing on create, hosted targetUrl, mcp 2.4.1 - #726
Merged
Merged
Conversation
…sted targetUrl, mcp 2.4.1 - Billing tools (change_plan, set_seats, change_addons, cancel_subscription, resume_subscription, set_agent_budget) and delete_team are annotated destructive and open-world: each can charge or end a Polar subscription, some without asking once an agent budget is set. A test keeps every tool that asks for a billing approval in that set. - create_endpoint needs signingSecret for every signing provider (Discord's application public key too) and returns the endpoint as the update saved it. - The hosted server leaves targetUrl out of render_email and test_webhook_flow (schema and descriptions); its z.object drops one sent anyway, so the refusal that could no longer be reached is gone. - Tool results leave statusText out when the response carried none; the hosted send_webhook says it sends from webhooks.cc's network. - The hosted server reports MCP_VERSION and its instructions explain ?tools=; the local server's instructions say that without enable_tools every group is already loaded. - Receiver: OWN_WORKER_ZONES (empty by default) drops CF-Worker and CF-EW-Via from captures and live relays when the Worker is our own. - Release: MCP 2.4.1 with its changelog entry, and a web changelog file. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
Owner
Author
|
@coderabbitai review |
Action not completed
|
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Seven fixes to the MCP servers from an independent review, with the MCP 2.4.1 release.
Findings and fixes
change_plan,set_seats,change_addons,cancel_subscriptionandresume_subscriptioncan charge the card or end a subscription through Polar, and once an agent budget is set some of them do it without asking. They now use abillingbehaviour (destructive,openWorld);set_agent_budgetisbillingplusidempotent, anddelete_teamisremoveplusopenWorld(it ends the team's Polar subscription at once).catalog.test.tspins the seven names, and a guard checks that every tool whose description carriesBILLING_APPROVAL(now exported fromtools.ts) is in that set.create_endpointlet Discord through without a key and returned the endpoint as it was before signing.signingSecretis now required wheneversigningProvideris set (Discord's credential is the application's public key; the PATCH route refuses a provider without one), and the tool returns the PATCH result, which is the full endpoint withsigningProviderandhasSigningSecret. If the update fails, the endpoint comes back with the warning as before. Both shapes describe the Discord key.INSTRUCTIONSnow explains?tools=alland?tools=core,teams. Tests check the text and that every name inTOOL_GROUP_NAMESparses throughtoolSelection. The MCP docs already had the?tools=line.statusTextwas made up. The receiver reads a newOWN_WORKER_ZONES(comma separated, empty by default, documented in.env.exampleandconfig.rs). When a request'sCF-Workernames one of those zones,CF-WorkerandCF-EW-Viaare dropped from the stored headers and from live relays (relay_headers). Rust tests cover a matching zone, a different zone and an empty list. In the MCP package, one helper (summarizeResponse) builds{ status, statusText, body }for every tool that reports a response, and it leavesstatusTextout when the response had none. The hostedsend_webhookdescription says it is sent from webhooks.cc's network, so the capture shows a Cloudflare address.targetUrland then refused it. On the hosted server,render_emailandtest_webhook_floware now registered withouttargetUrl, and their descriptions no longer mention it. A test inhosted-app.test.tssendstargetUrlanyway: the adapter'sz.object(shape)drops it, and nothing is posted there. The refusal could no longer be reached, so it is deleted. The local server still liststargetUrl(tools.test.ts). The docs, README and skill now say "notargetUrl" instead of "refused", and the bundled skill copy is regenerated.enable_toolseven for clients that never get it. They now say that whenenable_toolsis not listed, every group is already loaded.groups.test.tsasserts this.MCP_VERSION. The web version stays in its User-Agent. A test reads the server identity fromserver/discover.The server-level hosted tests (version, schemas, the dropped
targetUrl) are inhosted-app.test.ts, next to the existing harness that builds a hosted server. The pure ones are inhosted.test.ts.Release
packages/mcp/package.json, both version fields inpackages/mcp/server.json, andMCP_VERSIONwith an MCP-track changelog entry.apps/web/changelog/web/mcp-review-fixes.json.Ops step
Set
OWN_WORKER_ZONESon the production receiver to the notify proxy Worker's zone. Keep the value in the ops repository, not here. Until it is set, nothing changes: the default list is empty.Checks
pnpm typecheck,pnpm lintandpnpm test(SDK, MCP and web unit suites, including the hosted MCP tests) all pass.cargo fmt,cargo clippy --all-targets -- -D warningsandcargo testinapps/receiver-rspass (373 tests). Prettier was run on the changed files.🤖 Generated with Claude Code