Payment resource create error(souce id not chargeable) in the webhook on receiving source.chargeable event
over 2 years ago by Shashi Kant(edited)
- Once the customer authorizes the gcash payment, I am receiving the event in my webhook.
- In the webhook I am trying to create a payment resource if the status is chargeable
- I am getting the error that the source id is not chargeable
- But if I check the status of the sourceID it already shows paid(from https://developers.paymongo.com/reference#create-a-source)
Moreover, I am getting all earlier events with sourceId whose status is already paid
Flow in webhook:
- check status of event
- if status is chargeable the attempt payment resource creation
- if payment response has status paid, send statusCode 200 res back
A bit confused here pls provide the necessary help...