Is it possible to get the PayPal-Request-Id from the API call thru the webhook?
I store the data from the API call in the frontend and do not want to store the data again via the webhook. However, the webhook is needed in case the webhook is triggered by Paypal.com UI.
Currently I match the timestamp in the response header of the API call with the timestamp in the webhook body. Is there a better solution?
It depends on what the Webhook event is in regard to. When creating PayPal orders using the v2/checkout/orders API, for example, you can set a unique
invoice_idor an arbitrarycustom_idfor each purchase_unit. These values will be returned in webhooks for that order and resulting captures.