Repository navigation
Refactor plugin checkout to use cart-based approach - #261
Merged
Merged
Conversation
- Pass cart_id in Stripe metadata instead of plugin_ids/bundle_ids - HandleInvoicePaidJob now looks up cart and creates licenses from cart items - Listen for invoice.paid webhook instead of checkout.session.completed - Clear cart items when cart is marked as completed - Exclude completed carts when getting cart for user - Add stripe_checkout_session_id and completed_at to carts table - Add stripe_invoice_id to plugin_licenses table
- Store Stripe checkout session ID on cart before redirect - Allow GET requests to checkout route for post-login redirects - Fix guest cart transfer to only merge into active (non-completed) carts
simonhamp
added a commit
that referenced
this pull request
Mar 24, 2026
The PluginPurchaseController and its routes were reintroduced by a stale merge in PR #261 (cart-based checkout refactor), which was based on a branch predating the tier-based pricing cleanup. The controller referenced App\Services\GrandfatheringService which was intentionally deleted, causing BindingResolutionException errors on any request to purchase routes. The purchase flow was fully replaced by the cart system — nothing in the app links to these routes. Remove the dead controller, views, and routes. Closes #44 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4 tasks done
simonhamp
added a commit
that referenced
this pull request
Mar 24, 2026
The PluginPurchaseController and its routes were reintroduced by a stale merge in PR #261 (cart-based checkout refactor), which was based on a branch predating the tier-based pricing cleanup. The controller referenced App\Services\GrandfatheringService which was intentionally deleted, causing BindingResolutionException errors on any request to purchase routes. The purchase flow was fully replaced by the cart system — nothing in the app links to these routes. Remove the dead controller, views, and routes. Closes #44 Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
simonhamp
added a commit
that referenced
this pull request
Sep 19, 2026
Nothing has dispatched it since plugin checkout moved to invoices in #261. Its payout logic had drifted from HandleInvoicePaidJob, which made it easy to misread how payouts work. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
simonhamp
added a commit
that referenced
this pull request
Sep 19, 2026
…525) * Create recipient Connect accounts where full accounts can't be paid Our Stripe platform is in the US, so it can only transfer to connected accounts on the full service agreement in the US, Canada, the UK, the EEA and Switzerland. Developers everywhere else now get a recipient account that only requests the transfers capability. Adds payouts:recreate-connect-account to move an existing developer onto a new recipient account and hold their failed payouts until they finish onboarding again. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Remove unused ProcessPluginCheckoutJob Nothing has dispatched it since plugin checkout moved to invoices in #261. Its payout logic had drifted from HandleInvoicePaidJob, which made it easy to misread how payouts work. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Check Stripe for developers we can't pay yet in the daily payout run We only refreshed a developer's Stripe status when they came back from onboarding or opened their dashboard. If they finished onboarding and closed the tab, their held payouts never went out. The daily run now refreshes anyone we can't pay yet who has held or due payouts before it decides what to send. Refreshing no longer overwrites the date onboarding was completed. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Email a daily payout summary to support payouts:send-daily-summary runs at 12:00, an hour after the payout run, and emails the support address. It covers payouts sent or failed in the last 24 hours with Stripe's error for each failure, the upcoming and pending payouts still waiting, and the total paid out to date. It only skips a day when nothing was sent and nothing is waiting. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
SimonTingle
pushed a commit
to SimonTingle/nativephp.com
that referenced
this pull request
Sep 19, 2026
* Refactor plugin checkout to use cart-based approach - Pass cart_id in Stripe metadata instead of plugin_ids/bundle_ids - HandleInvoicePaidJob now looks up cart and creates licenses from cart items - Listen for invoice.paid webhook instead of checkout.session.completed - Clear cart items when cart is marked as completed - Exclude completed carts when getting cart for user - Add stripe_checkout_session_id and completed_at to carts table - Add stripe_invoice_id to plugin_licenses table * Updates plugin ui a bit * Udates clear cart logic * Update PHP version in linting workflow to 8.4 * Update PHP version in GitHub Actions workflow * Fix cart checkout flow issues - Store Stripe checkout session ID on cart before redirect - Allow GET requests to checkout route for post-login redirects - Fix guest cart transfer to only merge into active (non-completed) carts * Parameterize PHP version in linting workflow --------- Co-authored-by: Simon Hamp <simon.hamp@me.com>
SimonTingle
pushed a commit
to SimonTingle/nativephp.com
that referenced
this pull request
Sep 19, 2026
) The PluginPurchaseController and its routes were reintroduced by a stale merge in PR NativePHP#261 (cart-based checkout refactor), which was based on a branch predating the tier-based pricing cleanup. The controller referenced App\Services\GrandfatheringService which was intentionally deleted, causing BindingResolutionException errors on any request to purchase routes. The purchase flow was fully replaced by the cart system — nothing in the app links to these routes. Remove the dead controller, views, and routes. Closes NativePHP#44 Co-authored-by: Claude Opus 4.6 <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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
cart_idin Stripe metadata instead of comma-separatedplugin_ids/bundle_idsHandleInvoicePaidJobnow looks up the cart by ID and creates licenses from cart itemscheckout.session.completedtoinvoice.paidwebhook for better reliability with delayed paymentsTest plan