post https://api.reepay.com/v1/invoice//fail
Force fail a pending or dunning invoice. If the invoice is dunning the dunning process will be cancelled. The state of potential subscription for the invoce is not affected. An invoice cannot be forced failed if it has processing transactions awaiting payment provider.
Errors
The operation can generate the following errors beside the generic HTTP error codes described here.
Error code | HTTP code | Description |
---|---|---|
31 | 404 | Invoice not found |
82 | 400 | Invoice wrong state - must be pending or dunning |
30 | 400 | Invoice has active transactions. All transactions must be failed, cancelled or pending |