#damenz-ACSS-confirm

1 messages ยท Page 1 of 1 (latest)

deft umbra
boreal shadow
#

I created a checkout session as "setup" type for acss (pre-authorized debit) while providing the customer associated to that checkout session.

After completing the checkout session, the bank account is now available as a payment method for that customer

But i get this error when using this payment method on a scheduled_subscription when trying to charge the payment method

deft umbra
#

What guide are you following? I'm looking at how to do this. End goal is ACSS for recurring payments right?

boreal shadow
#

correct

#

everything is working

#

but the payment method is not "confirmed"

#

or something

#

thats where I am stuck

#

what I dont understand is that there is no payment intent

#

but it asks me to confirm it

deft umbra
#

PaymentMethods and PaymentIntents are seperate things. A PaymentMethod is what will represent this bank account. A PaymentIntent is something that will be created to attempt to charge a customer. The subscription will have it but I am unsure how that lines up

#

I have to bounce to another thread for a minute. Can you read through that and see where that process difers from yours?

boreal shadow
#

I use scheduled_subscription

#

the guide does not

#

i think i got it to work

deft umbra
#

Oh nice what did you change?

boreal shadow
#

i was trying to find payment intent

#

its associated to an invoice

deft umbra
#

Oh I see

boreal shadow
#

associated to the scheduled subscription

deft umbra
#

that makes sense

boreal shadow
#

the subscription itself does not have payment intent

deft umbra
#

Right. So if you confirm that PI with that PM

#

Right

boreal shadow
#

i just hope i wont have to do that every time

#

just once

deft umbra
#

I wasn't sure if it was that. Glad to hear it was

boreal shadow
#

let me create a new subscription

deft umbra
#

The message makes it sound like once but yes

boreal shadow
#

wow... it does not work

#

I dont understand how I am supposed to work with this

deft umbra
#

So what did you just do? Same PaymentMethod, new subscription?

boreal shadow
#

correct

deft umbra
#

And is it still the same error?

boreal shadow
#

new subscription still asks for the same thing

#

Is there a way to force the system to create a second invoice

#

If i only have to do it once PER subscription, its not too bad. But If I have to do this for EVERY invoice, i just dont understand how to work with it

deft umbra
#

On the first subscription?

boreal shadow
#

yes

deft umbra
#

You can update it and create a proration

boreal shadow
#

via the UI?

#

not sure to understand

#

thats dumb, why do we have to confirm it via api

#

it doesnt make sense

deft umbra
#

I am not immediately sure. Will ask

#

You can update via the API to test this now

boreal shadow
#

to create second invoice it has to be done via api?

deft umbra
#

You can upgrade and create the proration through either

boreal shadow
#

i dont understand how to do it via the ui

#

it did not create a new invoice

#

i did a proration but there is no new invoice

deft umbra
#

What change did you make? It does for me

boreal shadow
#

i updated quantity, added new product

#

also this is weird

#

it doesnt say the payment method

deft umbra
#

That means the Customer's default payment method

boreal shadow
#

i think to create the invoice i have to reset the billing cycle

deft umbra
#

Can you send me the ID for this subscription?

#

And the customer?

boreal shadow
#

any update?

deft umbra
#

So that PaymentMethod is attached to the Customer but it is not the customer's default payment method

#

You can do that via the UI or by setting the Customer's invoice_settings.default_payment_method in the APIhttps://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method

boreal shadow
#

its not clear

#

i created the subscription with that payment method

#

why does it say "default payment method"?

#

the payment method associated to the subscription should be the acss

deft umbra
#

I see you passing in default_payment_method and getting a response back that has a default_payment_method of null

#

Not sure why that may be here. Looking in to it

#

Oh wait. That is on the subcription schedule. It looks like the payment method on the subscription may have been set

boreal shadow
#

its null on the subscription

#

x) i just want to use ACSS for subscriptions, why is it so complex ahah

deft umbra
#

Yeah I am not sure why this is happening at the moment. Looking, will get back

boreal shadow
#

In the end, i just want to be able to create subscriptions using the acss payment method and I just want it to be auto from that point

#

meaning i should not have to confirm anything past that point...

#

lets say its monthly for 1 year, i dont want to have to confirm the 12 payment intent... that doesnt make any sense

deft umbra
#

It doesn't sound like you will have to but I am still confirming that

boreal shadow
#

and we are just trying to test / prove that last point by creating new invoices ahah

deft umbra
#

And why the default PM from the schedule didn't apply to the subscription

boreal shadow
#

Yeah I dont see the PM anywhere

deft umbra
#

Can you try manually setting that as the default for the account just to test this?

#

I can see it on the Customer

boreal shadow
#

only on the customer page

#

yeah

#

but not the on subscription, not even the invoice of that subscription

deft umbra
#

And oh, the payment method was set for the phase, not the schedule. So it was properly reflected in your response. You can set it on the schedule if you want it to apply to all phases

boreal shadow
#

yeah i did a new one and it works for that now

#

sub_1Jv79iLiVV9UQF8gL6dHw1hv

deft umbra
#

Good to hear. And can you reset the billing cycle now?

boreal shadow
#

its getting worse now

#

it detected the payment method at first

#

and then I tried updating and got the same message "Has to be confirmed at least once"

#

and now its not linked and it says "invalid"

#

where it says "Add a payment method" the bank account was there at first

#

but after trying to reset the billing cycle it shows that

#

i sent you a small video

deft umbra
#

Thank you. Will check it in a moment. Still looking in to the restrictions that this imposes. So one thing I am seeing is that the expected way to do this is by creating the subscription with a payment_behavior of default_incomplete and then using your Checkout Session to pay the PaymentIntent of the Invoice that gets generated

boreal shadow
#

The goal is to do a one time setup

#

and reuse this for further payments

#

So the client is involved only once

deft umbra
#

Right. I think this should do that.

boreal shadow
#

But what you just said require the checkout to be done for every invoices

#

unless i got it wrong

thorn zenith
#

@boreal shadow taking over, give me some time to catch up

boreal shadow
#

I need to go... but I would really like to solve this issue

#

I am stuck at the moment because of this

#

i will send you the small video i made

#

long story short, I am trying to create a subscription using a acss as a payment method

#

i sent you a dm

thorn zenith
#

Please email our support team instead for help before you go

#

this is the best way to get an answer if you have to leave!

boreal shadow
#

well i have to leave for 30 min

#

i will be back

thorn zenith
#

sounds good

boreal shadow
#

i dont know why, but the system asks me to confirm every payment intent when i use the acss payment method

#

which makes no sense at all

#

the goal of acss is for pre-authorized (the AUTHORIZED part is important lol) debit usable for future payments

thorn zenith
#

ACSS is extremely strict with debit rules in general though and we recommend using our pre-built logic and you are not since you go through your own SetupIntent separately and that's the problem. But we'll look for a solution and circle back with an update once we have one!

boreal shadow
#

I do nothing actually

#

i dont create a setup intent

#

here is what i do

#

1- Checkout session to capture ACSS informations
2- Create scheduled subscription using payment method returned on step 1

#

Thats it

thorn zenith
#

sounds good

boreal shadow
#

issue is... the payment method has to be confirmed

#

the subscription is not able to capture

#

(look at the video i recorded)

thorn zenith
#

All good I am looking into it, it will just take a while. Likely well over an hour, to get you an answer

boreal shadow
#

Sure, i will go do my stuff and I will be back later. Its gonna give you time to look into it

thorn zenith
#

Okay so I worked with someone internally and we can both create a Subscription with a flow close to yours. But we also do hit strange errors too. Overall I don't fully grasp what you are really doing and how much of what you shared in the video is your real flow. Like you seem to manually decide to go and pay the invoice in the Dashboard. Is that an absolute hard requirement of your entire flow? Or is that just trying to do it as a developer to unblock yourself?

I'm still digging into it, but the follow flow worked fine for me
1/ Create a Checkout Session with mode: 'setup' and also properly pass the following options 'payment_method_options' => [ 'acss_debit' => [ 'currency' => 'cad', 'mandate_options' => [ 'default_for' => ['subscription', 'invoice'], ], ], ],
2/ After that succeeds and you get the PaymentMethod attached, you can now create a Subscription. Pass the PaymentMethod id pm_123 in default_payment_method on Subscription creation and their first invoice will be paid as expected with the ACSS Debit PM. If you use default_incomplete then you can Pay the Invoice explicitly via the API.

What I don't yet understand is why confirming the PI itself errors, I get something similar to your error. My colleague doesn't though so I'm puzzled. But I did want to share this since it already should unblock you

boreal shadow
#

As for my flow the video is just showing weird behaviour

#

my flow is the following

#

1- Checkout session as you mentionned
2- Create subscription with PM from step 1

#

thats it

#

no manual action whatsoever

#

Manually going in the dashboard to pay the invoice was just a test

thorn zenith
#

Do you properly pass default_for like I showed in my code?

boreal shadow
#

no let me try this

thorn zenith
#

I just paired with one of our product engineer on this becuase I was as lost as you :p

#

it's quite complex, but overall as long as you use default_for and you explicitly create your subscription and don't pass default_incomplete which you don't need, it should "just work" like you expected

boreal shadow
#

I just want to create the subscription and then let stripe handle the rest from there

thorn zenith
#

it's when you don't that it gets a bit messy

#

When we add subscription + ACSS support on Checkout it will make this way easier

boreal shadow
#

what do you mean ?

thorn zenith
#

Right now Checkout doesn't let you create a Subscription with ACSS right? You have to use mode: 'setup' to collect bank account details and then separately create a Subscription after that completes

boreal shadow
#

Oh, thats okay thats the intended behaviour

#

I want to save ACSS for future use. Its my intranet that creates the subscription using the PM

#

I don't want to do both at the same time

#

{
"error": {
"message": "The following params are not allowed when payment_method_options[acss_debit][mandate_options][default_for] is provided: ["payment_method_options[acss_debit][mandate_options][interval_description]", "payment_method_options[acss_debit][mandate_options][payment_schedule]", "payment_method_options[acss_debit][mandate_options][custom_mandate_url]"].",
"type": "invalid_request_error"
}
}

#

when adding default_for

thorn zenith
#

yeah the error is quite clear

#

you just rushed! I did the same earlier

boreal shadow
#

so I remove the interval description?

thorn zenith
#

it tells you that if you pass default_for you don't need any of the other stuff

boreal shadow
#

i thought it was mandatory

#

Oh ok

thorn zenith
#

yeah with default_for we basically generate this for you to indicate it'll be used for recurring payments

boreal shadow
#

about the "default_incomplete" where is that config?

#

what is it related to ?

#

Its better ! It now let me charge the customer (i just dont want to wait 1 hour to see the result)

#

is it normal that the payment is "Pending for bank account" since this is a test bank account in a test environment?

thorn zenith
#

yes it's normal, it mirrors what would happen in Live mode

boreal shadow
#

what is required to make it "paid"?

thorn zenith
boreal shadow
#

so there is a 3 day minimum time ?

#

YEah i was confused by that part

#

you meant this part?

thorn zenith
#

yes

#

haven't tried it yet but I can let me confirm it works with Checkout

boreal shadow
#

im not sure to understand what email i should be putting here

thorn zenith
#

for example yes

boreal shadow
#

but what is the email for

#

is it my email ? the client's email ? this part is really unclear for me

#

and I provide this during the checkout ? (when creating the PM?) if I understand correctly?

thorn zenith
#

It's the client's email, it's what you enter in Checkout when you go through the ACSS Debit setup

boreal shadow
#

so my email is

#

so that would be

#

?

#

And If I understand correctly, this is just to skip the inital "3 days delay". AFter that 3 days, everything will be much quicker anyway ?

#

I dont mind waiting 3 days for the initial setup

#

If everything is gonna be quicker after

#

And hey, thanks alot by the way

#

no other company offer the kind of dev support you guys provide us it, props

thorn zenith
#

it's really just for Test mode that this feature exists

boreal shadow
#

Oh

thorn zenith
#

ACSS is a bank debit it takes up to 7 days for the debit to succeed

#

it's never instantaneous

boreal shadow
#

Gotcha.

thorn zenith
boreal shadow
#

Thanks alot, i think that is all (finally !)

#

Will come back if I have any more questions / issues, but so far I think its working ๐Ÿ˜„

thorn zenith
#

Of course. Sorry for the long time it took to help. I had tested ACSS a few times but never that flow. I knew about default_for because I helped design it but it's pretty advanced and the other people on my team weren't aware of it

#

I'm glad we were able to find a good flow/solution for you ๐Ÿ™‚

boreal shadow
#

Hey, dont worry, I aint the only one needing help here. I really appreciate everything you did

thorn zenith
#

yay ๐Ÿ™‚

boreal shadow
#

Have a nice weekend!