Void Overpayment through xero api

229 Views Asked by At

I am trying to void overpayments through the xero api.

What I do is create an overpayment through the Bank Transactions end point with type RECIVE-OVERPAYMENT.

It creates the overpayment and then I save the OverpaymentID, but I can't seem to find any documentation on voiding the Overpayment again.

I have tried doing a post to the Overpayments end point with the OverpaymentID and the Status as VOIDED but I get a 500 error each time.

I have also tried to delete the bank transaction I used to create the overpayment but it just deletes the bank transaction and does nothing to the actual overpayment.

Does any one know what end point I should use?

I am not using a gem, I wrote the integration myself and everything is working except the voiding of overpayments.

1

There are 1 best solutions below

0
On BEST ANSWER

You cannot delete or void spend/receive-pre or over payments via the Xero API. However you can manually 'remove and redo" the bank transaction via the Xero UI.