Skip to content

Delete the broker client and the curated APIs that could only fail - #193

Merged
claude[bot] merged 3 commits into
mainfrom
wp/omni/delete-undeployed-paths-2
Nov 3, 2026
Merged

claude[bot] merged 3 commits into
mainfrom
wp/omni/delete-undeployed-paths-2

Conversation

@sdcarlson

@sdcarlson sdcarlson commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Objective. Continue #190 under the same rule: delete what no live deployed app can reach. Main point: stop visitors' keys going to a stub. Net −763 lines.

What changed.

  • Broker client: executeBroker, the brokerOrigins option and the "via server" UI are gone. Before this, a key entered for a brokered API was POSTed to /api/capability-broker, which returned 503.
  • FRED, NewsAPI, Metaculus: removed as curated APIs. They refuse browser calls, so without a broker they can only fail. Their specs, key guides and quality rows go, and the nightly job drops their secrets.
  • Provider attribution: only FRED used it.
  • Key-format warning: no remaining curated API documents a format.
  • Smaller paths: cited-block highlighting (its only writer was the provenance chips), the always-empty keyed-provider check, the envVar field, four type-only fields, and the dev:vinext and build:vinext scripts.

What did not change.

  • wrangler.jsonc, .env.example, deploy-preview.yml and .mcp.json are untouched.
  • The five 503 stubs stay. No client calls them now; they exist only for the deploy gate.
  • transport.access stays on every manifest as browser_direct, because it is part of the digest and removing it would invalidate every installed capability.
  • SECRET_ENV_VARS stays broad on purpose.

Visible differences once deployed.

  • The three APIs no longer appear as curated results. Any directory listing for them is unaffected.
  • A visitor who already installed one has a server_broker manifest, which validation now rejects, so it is dropped on restore. Those blocks could never return data.
  • Account backup restore no longer rejects the whole canvas over one invalid manifest (Codex finding, fixed in a542114). restoreSnapshot still validates each manifest and drops the bad one, and a non-object entry is still refused. This also covers old backups holding MCP or async manifests, which Delete every path no live deployment reaches #190 would have refused.
  • The FRED notice goes with FRED.

Tests run (clean build):

  • typecheck passes. lint has 0 errors.
  • npm test: 840 passed, 92 files.
  • build, wrangler dry run and scan:bundle with canaries pass.
  • test:e2e on next start: 7 of 7.
  • The real Worker under wrangler dev answers as expected on /, the five stubs, /api/polymarket and /api-index.json.

Known failures. None. Coverage note: nothing now exercises a key sent in an X-Api-Key header compiled from a curated spec; the Metaculus and NewsAPI cases were that coverage.

Claim ceiling. Tested locally. Not deployed.

Architectural decisions introduced. None.

Evidence that could falsify it. A deployment with a working broker, which the Cloudflare account does not show.

Next permissible package. The owner deploys, and removes the stubs together with their deploy-preview.yml checks.

🤖 Generated with Claude Code

FRED, NewsAPI and Metaculus refuse browser calls, so without a broker they can
never return data on any deployment. Installing one only collected a visitor's
key, POSTed it to a 503 stub and showed an error. Removes them with the broker
client, provider attribution, the key-format warning no remaining API can
trigger, cited-block highlighting and the always-empty keyed-provider check.
transport.access stays on the manifest because it is part of the digest.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-03T05:37:19.815614Z a1625ab PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a1625ab630

ℹ️ 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".

Comment thread src/core/capabilities/manifest.ts Resolved
…jects them on rehydrate

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@claude
claude Bot enabled auto-merge (squash) November 3, 2026 05:39
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Codex feedback round 1 answered 1 of 1 Codex finding(s).

A backup can hold a FRED, NewsAPI or Metaculus manifest, or an older MCP or async
one. Restore must keep the canvas and drop only that capability, and a malformed
entry must still be refused.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@claude
claude Bot merged commit d1d82d1 into main Nov 3, 2026
4 checks passed
@claude
claude Bot deleted the wp/omni/delete-undeployed-paths-2 branch November 3, 2026 05:44
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.

1 participant