-
Notifications
You must be signed in to change notification settings - Fork 206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use metadata stored on the intent to fetch an order for webhook processing #3567
Use metadata stored on the intent to fetch an order for webhook processing #3567
Conversation
Hi, team; thank you for looking into this issue. Let us know when there is an ETA so we can inform the merchant for updates. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work 🎉
✅ Confirmed from logs that a signature is sent as a metadata during payment intent request. Also the signature is received as a metadata in the webhook event data.
✅ I can see the signature present in the relevant transaction in my Stripe dashboard.
✅ Checkout with regular card.
✅ Checkout with 3DS card.
✅ Checkout with GPay (PRB and ECE)
✅ Checkout with iDeal.
✅ Checkout with SEPA.
✅ Checkout with CashApp (Wallet)
✅ Checkout with Klarna (BNPL)
✅ Checkout with Multibanco (Voucher)
Co-authored-by: Mayisha <[email protected]>
Co-authored-by: Mayisha <[email protected]>
Tests passed after replaying them: https://github.com/woocommerce/woocommerce-gateway-stripe/actions/runs/11819563698?pr=3567 |
…ssing (#3567) * Use metadata stored on the intent to fetch an order for webhook processing * Tidy comments * More comment changes * Comment tweaks * Add changelog entries * Add signature to root generate_payment_request() function * Update unit test to expect signature * Make sure guest customers are accounted for * Update tests/phpunit/test-class-wc-stripe-upe-payment-gateway.php Co-authored-by: Mayisha <[email protected]> * Update tests/phpunit/test-class-wc-stripe-upe-payment-gateway.php Co-authored-by: Mayisha <[email protected]> --------- Co-authored-by: Wesley Rosa <[email protected]> Co-authored-by: Mayisha <[email protected]>
@wjrosa Believe this change was released with version 8.9.0? = 8.9.0 - 2024-11-14 =
I'm double-checking there to see if the webhook was processed for the subscription renewal order. Will the Woo subscription status be set from "On hold" back to "Active"? |
Yes, released with 8.9.0.
That's the expected behavior, yes. Are you having issues specific with this flow, related to this change? |
Changes proposed in this Pull Request:
This PR updates the webhook handler to enable it to fetch the relevant order from
payment_intent
metadata.This has two impacts:
We've seen at least 1 large store where we fire off the payment intent request to Stripe, however, we never process the response. This means we don't record the intent ID on the order and therefore cannot process the webhook when we receive it. This PR adds a way for us to fetch the order from data stored in the intent's metadata. Internal link to this case: pcJe93-4NE-p2#comment-4929
cc @geektzu
Testing instructions
The new signature stored in payment intent metadata.
Because this changes a core part of the way we process webhook payments, please scrutinize this change to make sure we root out any potential gotchas.
changelog.txt
andreadme.txt
(or does not apply)Post merge