ZOQL: Query for Payment Error Message in Payment Collection
We have a payment ID we are querying for and the status is set to 'Error'. In the GUI we can see that the error message is '502 - Bad Gateway'. We are trying to find/display the payment error reason and cannot seem to find where we can get this information. We have been attempting to use ZOQL and looked through the Payment and InvoicePayment collections with no success. Is there another collection we need to be looking at? Or some other method entirely we should be using?