#Anuroop
1 messages · Page 1 of 1 (latest)
Thanks for testing. Can you provide the PaymentMethod ID so I can take a look?
My understanding was that we carry all relevant data down when the clone occurs
But maybe this isn't the case with skipping verification unless your Connected Account is also approved for that feature? Let me check.
Getting the ID now
Or potentially you do have to also use a SetupIntent to indicate you are skipping verification on the Connected Account. I haven't actually tested cloning + skipping verification before. My understanding is that it "just works", but maybe that was incorrect.
Sorry it's taking a bit to find the payment id, it may not have attached correctly.
No worries.
pm_1MIFzC2XRZBXnduIk4gxzKkt
Thanks, let me take a look
Here it is
Hmmm odd that bank account does show verified due to the skip
Ahhh
You are using a legacy object
Not a PaymentMethod
You are using bank account objects
One sec
Sure
Is there a reason you are creating bank account objects on your platform as opposed to us_bank_account PaymentMethods?
Hmm I'm actually not sure, it's an existing helper method that I chose to use.
You are currently mixing the legacy ACH flow (which uses the bank account object ba_xxx) with the new ACH flow (which uses us_bank_account PaymentMethod objects pm_xxxx)
So yeah that is why you are encountering the mandate issue
Because the new flow requires a mandate to be set up
Okay instead if I use the payment method objects to create a US bank account directly I should not see this
?
@safe thorn
You need to use a SetupIntent and pass mandate_data: https://stripe.com/docs/api/setup_intents/create#create_setup_intent-mandate_data
Tagging my colleague for visibility
You can technically do this with the legacy object too
We actually document this here: https://stripe.com/docs/payments/ach-debit/migrations
But overall I would recommend just using the newer PaymentMethod object
Let's walk through the flow
Are you going to be creating these objects server-side?
Yes
As-in you already have the bank account details from your customers
Yep, we collect the details and create these payment methods on Stripe
Gotcha
Okay let me type out the flow
The simplest way to do this, and what I would recommend, is to just create a SetupIntent on your platform (https://stripe.com/docs/api/setup_intents/create) and pass the following parameters:
customerconfirmpayment_method_data.us_bank_account(here you pass the account_number and routing(payment_method_options.us_bank_account.verification_method: skip
Oops
I forgot mandate_data
So and mandate_data (https://stripe.com/docs/api/setup_intents/create#create_setup_intent-mandate_data)
If you pass all of those parameters you will create a us_bank_account PaymentMethod on your platform that is verified and has a mandate.
And it will be attached to the Customer that you passed to the SetupIntent as well
Then you clone the PaymentMethod like we show here: https://stripe.com/docs/payments/payment-methods/connect#cloning-payment-methods
Then attach it to a Customer on your Connected Account using https://stripe.com/docs/api/payment_methods/attach. Then you create the Sub and use that PaymentMethod
Okay makes sense.
One more thing is that after you attach the PaymentMethod to the Customer on the Connected Account you will want to update the Customer to set the PaymentMethod as the invoice_settings.default_payment_method (https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
Then you don't have to pass the PaymentMethod when you create the Subscription, it will automatically be used for any Subs for that Customer
(Unless you do want to use separate PaymentMethods for separate Subs on the same Customer that is)
Perfect. Thanks for the write up, will try this out thanks!
Thank you!