#Tanmoy-checkout

1 messages ยท Page 1 of 1 (latest)

calm mulch
#

Hello! Is there a specific reason you need the Payment Intent ID right after creating the Checkout Session?

tidal solstice
#

Yes, I'm validating the payment after redirecting from the payment page. With payment intent ID..

calm mulch
#

Do you mind sharing both the live and test mode request IDs with me?

tidal solstice
#

Sorry I can't share ๐Ÿ˜ฆ

calm mulch
#

Is there a specific reason?

tidal solstice
#

I don't have live credentials. I'm a freelancer and my client has it. And I can't share his info.

calm mulch
#

Could you just share the test requests?

#

Without the requests it's hard to confirm, but I'm guessing the live and test mode requests are on different API versions

#

Starting with API version 2022-08-01 we no longer create the Payment Intent when the Session is created, and instead wait until it's been confirmed

tidal solstice
dense elk
#

๐Ÿ‘‹

#

Stepping in as Karbi needed to step away

#

That API reference snippet still references the old API versions

#

Where a PaymentIntent would be created on Session creation

#

As Karbi noted, this isn't the case any more

#

I'll work on getting those docs updated to reflect the current version

tidal solstice
#

How can I get the payment_intent value then? โ˜น๏ธ

#

Or validate the payment after transaction..

dense elk
#

Did you read the above?

#

The PaymentIntent is now created when the Session is confirmed

#

So it will still exist, just after the Session is completed instead of on creation

tidal solstice
#

Sorry. But I'm doing this,
Create session -> Save payment intent to my database also save a hash with that -> add that hash with the redirect url -> make payment -> after redirect, match the payment intent with the hash -> get stripe payment details with the payment intent.

How can I process this if I get the payment intent when the session is completed?

dense elk
#

Why do you need the PaymentIntent up front as opposed to after the Session is completed?

#

Webhooks is really the recommended route here.

tidal solstice
#

Right now, I can't use webhooks here.

#

Is there any alternative for PaymentIntent ?

#

In this update?

dense elk
#

So you can set your requests to using 2020-08-27 and you will see the behavior where the PaymentIntent is created upon Session creation

tidal solstice
#

OK I'll check that.

#

Thanks for your help.

#

๐Ÿ™‚