In WooCommerce Subscriptions there's a setting that allows customers to purchase $0 subscription products (i.e. subscriptions that have a trial period) without entering a payment method on the checkout:
After the free trial ends, when the customer pays for the first renewal order with WooPayments, the new payment method is not set or the payment tokens on the subscription, resulting in the subscription remaining as requiring manual renewal, instead of automatically renewing with WooPayments.
In the Stripe extension we add support for this by adding the payment method meta to the subscription and making sure the payment method is set. See the code in maybe_update_source_on_subscription_order() function.
Thanks @mattallan 👍🏻 Clarifying that the bug here is that subscriptions with $0 first payment / deferred first payment don't work reliably (because auto-renew is not set up).
Describe the bug
In WooCommerce Subscriptions there's a setting that allows customers to purchase $0 subscription products (i.e. subscriptions that have a trial period) without entering a payment method on the checkout:![image](https://github.com/woocommerce/woocommerce-gateway-amazon-pay/assets/2275145/7e9b58ea-aac9-43df-97e1-b5c3e9d9c27f)
After the free trial ends, when the customer pays for the first renewal order with WooPayments, the new payment method is not set or the payment tokens on the subscription, resulting in the subscription remaining as requiring manual renewal, instead of automatically renewing with WooPayments.
In the Stripe extension we add support for this by adding the payment method meta to the subscription and making sure the payment method is set. See the code in
maybe_update_source_on_subscription_order()
function.Here's a screen recording of the issue:
https://github.com/Automattic/woocommerce-payments/assets/2275145/70539fe5-b7b3-4326-b92e-42a26a7d257e
To Reproduce
Expected behavior
It's expected that after paying for the pending renewal with WooPayments, the next renewal will automatically process with our gateway.