#Piercy-checkout

1 messages · Page 1 of 1 (latest)

mellow brook
#

as far as I know, no, it's not possible. You'd find out the final amount after the customer has paid(since for example the amount of tax is going to depend on what the customer ends up entering during the session etc)

lofty bear
#

What about if I already know the relevent location information? For example, I already know the billing address. Is it possible to pass that into the create checkout session to have it calculate.

mellow brook
#

it's not

lofty bear
#

so based on that, theres no way to preview a checkout session?

mellow brook
#

nope!

lofty bear
#

well bad news I guess. Ill go back to managers... thats not an ideal scenario though. Its surprising to me stripe doesnt offer this. It makes those properties I mentioned above next to useless

mellow brook
#

they're there so you can read them after the payment

lofty bear
#

I mean still seemingly pointless because after the payment I can use the invoice and other endpoints.

#

No problem, ill have to find a workaround

#

What about using tax rates instead of automatic, does that change the above scenario to a point where we can get the tax information?

mellow brook
#

well if you do it that way then you would have to write code to choose the tax rate to apply based on information you collect from the user

#

and then I suppose you can write some code to calculate the final amount based on the line items you intend to pass and the tax_rate you intend to pass, it would all be a lot of code

lofty bear
#

Yeah, i mean in our example, we are essentially signing up a club, which will be in a specific canadian province. So it will always be the same

mellow brook
#

about the only thing I can think of using the upcoming invoice endpoint, but that is not the same thing and I'm sure there's some edge case I'm not aware of, so my answer would be that it's not possible to preview this

mellow brook