#AdamTheDeveloper - checkout events

1 messages · Page 1 of 1 (latest)

fringe solar
#

HI there. Can you share the event id?

misty abyss
#

evt_1L2cW1JAXBXnoJdlOXwILvT5

#

NO wait, sorry, use evt_1L2cTfJAXBXnoJdlM3dNOWr3

fringe solar
#

Ok thanks. Looking

#

Ah it's because you added the webhook endpoint as a connect webhook endpoint

#

But the checkout session was created on your platform account

misty abyss
#

Sorry for not understanding here, but we are using Connect?

fringe solar
#

The webhook endpoint you created was a connect webhook

#

If you didn't mean to do that, then create a new one that's not in connect mode

#

But that checkout session was only created on your platform (so not connect)

misty abyss
#

Right, I don't fully get the "why" it's not Connect, because it's showing in Connect. But I do understand the concept of adding another webhook without ticking that box to use for "connect mode". I'll try that 🙂 Thanks

fringe solar
#

No problem!

misty abyss
#

Is there a chance that the "success_url" is called before the checkout.session.completed completes?

#

I.e. is it safe to put the "order success" and fulfillment logic in the webhook script, or should it be on the success_url script?

fringe solar
#

You shouldn't ever rely on the success_url being reached

#

The client's browser could crash, etc.

#

The fulfillment logic should be in the webhook handler code

misty abyss
#

That's great. But will it be quick enough? or is it async?

#

Like will a user potentially get to the success_url before the webhook fires?

fringe solar
#

yeah that's possible

#

Timing isn't guaranteed

#

And it depends on network latency

#

success_url is just meant to display a success message though

#

You don't want to have too much logic revolving around it

misty abyss
#

Ok, thanks for the info. I've got it from here.

fringe solar
#

No problem