#lamb-checkout-invoice

1 messages · Page 1 of 1 (latest)

verbal rapidsBOT
hollow tide
#

Do you have a Checkout Session ID you can share?

icy ermine
#

sure

#

cs_test_a1hDBBBPVUzHHpNdX9a1TMrzVf2kVFhij9xLWAiTo2rIUqEnezg0lkxDdI

hollow tide
#

I see an invoice ID on my end. Did you receive the response above after making a call to retrieve the Checkout Session or something else?

#

I also see an invoice ID in the event details for the checkout.session.completed event that was sent to a webhook endpoint

icy ermine
#

Yes

#

Stripe::Checkout::Session.retrieve(session_id)

#

weird. I see it when i manually check it

hollow tide
#

At what point did you retrieve the Session? Was the status of the Session already complete?

icy ermine
#

yes

#

I retreive after a succesful checkout

hollow tide
#

weird. I see it when i manually check it
I'm trying to understand the difference here. What do you mean by manually check it?

icy ermine
#

wait, i dont understand why it's working now

#

I have about 40 records of it not working

hollow tide
#

That tends to happen sometimes, doesn't it 😅 I'm glad it's working though!

icy ermine
#

it seems like when i retreive the session details immediately after checkout, it doesn't populate the invoice id but does after a few seconds

verbal rapidsBOT
hollow tide
#

Gotcha. Invoice creation should be relatively quick. I recommend using webhooks and listening for the checkout.session.completed events, which should include the invoice ID