#nick_51639

1 messages · Page 1 of 1 (latest)

silk sirenBOT
remote grove
#

hello! you'll need to use Subscription Schedules to achieve what you want

kindred oar
#

Thanks @remote grove, can I also confirm for the credit card and bank forms we're using the elements api where mode = payment.

Do we still need to create the payment method and attach it to the customer we created or is this already part of the elements api that when submission it will automatically create a payment method?

The issue is we find the payment method which is created by the component holds no link back to the Customer and therefor can't be found.

remote grove
#

you would want to use setup_future_usage to automatically save the PaymentMethod to the Customer upon successful payment

#

Subsequently, you would need to set the default_payment_method for either the Subscription Schedule [0] or invoice_settings.default_payment_method [1] on the customer

[0] https://stripe.com/docs/api/subscription_schedules/create#create_subscription_schedule-default_settings-default_payment_method
[1] https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method