Repository navigation
Consolidate console account and Stripe route adapters - #899
Gajesh2007 wants to merge 1 commit into
Conversation
|
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. |
|
Final validation for
Individual validation details and limitations are in each PR description, including the dedicated-M5 provider/live GPT-OSS checks and the unchanged baseline TypeScript diagnostics in #899. No merge or deployment was performed. |
db4d0c1 to
7e4d4e5
Compare
|
@codex review |
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
Twelve console route files repeated the same account and Stripe request orchestration. This change puts those two contracts in focused server adapters and leaves 15 endpoint handlers declaring their coordinator path, method, and body/query requirements. It removes 135 production lines while preserving the current browser API.
proxyAccountauthenticates before resolving dynamic resource IDs or reading bodies, keeps account GETs uncached, forwards request text without JSON rewriting, and preserves upstream status/content type/response text, including once-only key secrets.proxyStriperetains cookie fallback and upstream authorization, wraps failure text with its original status, and normalizes successful JSON responses to 200 with the existing empty-response fallback. Paths remain server-defined; IDs stay encoded. Quote, public reads, model transformations, and encrypted chat streaming retain their own distinct adapters.Three existing payout-hook tests were already failing on the base branch because they attempted withdrawals with
enabled: false, before recovery status was loaded. Their setup now enables withdrawals and waits for status, so they exercise success/error/recovery instead of the guard. No payout behavior changed.Before
After
Validation on Node 22.23.2, committed dependency lock, Next 16.2.11:
npm run build: passed.npm run lint: passed; existing warnings remain. Focused lint for new helpers/contracts and updated payout tests has no warnings.tsc --noEmitreports 13 existing errors, byte-for-byte identical before and after this refactor; the existing Next configuration skips type validation. No new type diagnostic was introduced.This PR is based on the GPT-OSS prefix-cache branch and changes only the console. It does not require a coordinator/provider change or dependency update.
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.