Skip to content

refactor(billing): organize Stripe Connect client operations - #1048

Closed
Gajesh2007 wants to merge 5 commits into
refactor/coordinator-subsystems-integratedfrom
refactor/coordinator-stripe-connect
Closed

Gajesh2007 wants to merge 5 commits into
refactor/coordinator-subsystems-integratedfrom
refactor/coordinator-stripe-connect

Conversation

@Gajesh2007

@Gajesh2007 Gajesh2007 commented Sep 14, 2026 •

Copy link
Copy Markdown
Member

The Stripe Connect client mixed account onboarding, payout scheduling, transfers, event parsing, fees and HTTP error handling in one 930-line file. The operations now live in nine named files in the existing billing package. stripe_connect.go keeps the shared client state and constructor and maps the files. Stacked on #1038.

All 45 Connect declarations preserve their executable code and declaration comments; 41 move. Transport credentials, supplied idempotency keys, account headers, signature verification, mock responses, fee arithmetic and uncertain-failure classification stay the same. The obsolete introductory lifecycle description is replaced with the current source map. Maintained billing and pricing references point to the actual operation files.

flowchart TB
  subgraph Before
    B1[Billing HTTP controller] --> B2[stripe_connect.go: accounts, links, transfers, payouts and fees]
    B2 --> B3[Same file: authenticated HTTP and APIError classification]
    B3 --> B4[Stripe API]
    B4 --> B5[Same file: signature verification and event projection]
    B5 --> B1
  end
  subgraph After
    A1[Same billing HTTP controller] --> A2[stripe_connect_accounts / links / transfers / payouts / fees]
    A2 --> A3[stripe_connect_transport.go: do and supplied headers]
    A3 --> A4[Same Stripe API calls]
    A3 --> A5[stripe_connect_errors.go: same failure classification]
    A4 --> A6[stripe_connect_webhooks.go: same signature checks and event fields]
    A6 --> A1
  end
Loading

Validation: all 210 billing declarations compare identically after file relocation, including semicolon-preserving tokens and declaration comments. All seven existing billing test files retain their exact bytes. Billing and billing-controller race suites pass 152 top-level tests / 181 including subtests, with no skips. Command build, pinned lint (zero issues) and all 281 documentation checks pass. Tests use local HTTP fixtures; no live payment or production action was performed.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

@vercel

vercel Bot commented Sep 14, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
d-inference Ready Ready Preview Sep 14, 2026 6:56pm UTC
d-inference-console-ui-dev Ready Ready Preview Sep 14, 2026 6:56pm UTC
d-inference-landing Ready Ready Preview Sep 14, 2026 6:56pm UTC

Request Review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 14, 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-09-14T18:59:28.960556Z 65bc358 Manual request
ℹ️ 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.

@Gajesh2007

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: ed3ca51f27

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

@Gajesh2007

Copy link
Copy Markdown
Member Author

@codex review

Refreshed the parent branch and resolved documentation/source-map conflicts. Existing subsystem implementations and regression tests are preserved. Exact parent composition and independent review pass; all coordinator test packages compile and documentation checks pass. The account-deletion fixture also carries the previously reviewed asynchronous-registration race fix; all seven deletion tests pass under the race detector.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Can't wait for the next one!

Reviewed commit: 65bc3580ab

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

@Gajesh2007

Copy link
Copy Markdown
Member Author

Consolidated into #1056 for review and merge after #1094, #1095 and #1096. #1056 contains this branch's exact head (65bc3580ab9a505120cb2125af4e187f2229a68d), including its reviewed fixes, with implementations and regressions reconciled into the coordinator subsystem owners. Closing the component PR to collapse the stack; its branch, commits and review history are retained. Follow #1056 for combined validation and merge status.

@Gajesh2007 Gajesh2007 closed this Sep 16, 2026

This branch had an error being deployed

1 failed and 3 active deployments
Preview – d-inference — 65bc3580 Deployed Sep 14, 2026 by vercel[bot]
Preview – d-inference-console-ui-dev — 65bc3580 Deployed Sep 14, 2026 by vercel[bot]
Preview – d-inference-landing — 65bc3580 Deployed Sep 14, 2026 by vercel[bot]
benchmarks — 65bc3580 Deployed Sep 14, 2026 by Gajesh2007 via E2E Benchmarks #1292
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