#stonebanks-receipt-number

1 messages ยท Page 1 of 1 (latest)

gray crane
#

Thanks for the info. Looking in to this

#

Interesting, I see a receipt_number on the charge on that PaymentIntent

#

If you retrieve the PaymentIntent again now do you see it?

tulip sapphire
#

hmm lemme see

#

Yes I can see it now. That's unfortunate, I was expecting the receipt_number property to be filled as soon as the payment intent is confirmed, in order to store it in DB. Am I supposed to retrieve the payment intent again after the confirmation for the property to be filled or is this prone to be a race condition?

gray crane
#

I am not immediately sure. When did you first retrieve this?

tulip sapphire
#

I just confirmed the payment intent (on the server), then checked that the status is succeeded so I returned the object returned in the confirm call response. (PS: I'm using the .NET core client)

gray crane
#

Interesting. So you called confirm on the server and the object that got returned to you had a successful charge with no receipt_number?

#

Just making sure I understand, want to recreate this myself

tulip sapphire
#

Yes that's it

#

For extra information, it's an integration test. Basically, I'm doing :

  • create payment intent
  • confirm payment intent using the id returned by the creation call
  • verify status is success
  • try to store receipt_number in DB
    I have the same behavior everytime I run the code. The following screenshot shows what I have in the event logs area of the dashboard
gray crane
#

Hey, apologies for the delay. Things got a bit busy. Back here and working to recreate this

tulip sapphire
#

no pb ๐Ÿ™‚

gray crane
#

So I am seeing the same thing you are in the payment intent webhook event. Tried to retrieve the PaymentIntent in the webhook handler and am seeing the same thing. Will check in to how/when that ID is created

tulip sapphire
#

thank you for looking into this ๐Ÿ™

umbral grail
#

Hello! Sorry for the delay. The receipt_number isn't generated/available until a receipt is sent or viewed. You viewing the receipt in the Dashboard causes it to be generated, which is why it's available after that point.