问题
I am using paypal gateway. I am using js sdk smart payment buttons.
Question 1) Turns out that when I make a payment through js, it returns me id and capture_id(id means order_id
and capture_id
means transaction_id
). Then I use webhooks
to catch events on my back-end. Looks like it takes me lots of parsing 'links' property in it to get order_id. Is it really necessary to have order_id stored in my db? or capture id is enough to do anything?
Question 2) when events arrive on my back-end, sometimes they arrive 2 times or 3 times. (Same events). Why is that? I acknowledge receiving them via return response('', 200);
but still, this is not enough. Any ideas?
来源:https://stackoverflow.com/questions/57381603/is-storing-order-id-via-paypal-payment-really-necessary