Void an unsettled payment
Cancel an eligible payment before settlement.
Use the right reversal
Only an unsettled payment can be voided. Inspect current state before acting because settlement can change eligibility between a screen being opened and an operator confirming the action.
Basic void request
Send a JSON object even when there is no reason field. An empty request body is not the documented alternative. POST /api/v5/payments/<payment-id>/void HTTP/1.1 Host: sandbox.nmi.com Authorization: <sandbox-private-key> Content-Type: application/json {} Sandbox verified 2026-10-16: voids of approved sales, authorizations and captures passed.
EMV reason values
For EMV, void_reason is conditionally required. Use the reason that matches the actual device outcome. Parameter Documented values void_reason fraud; user_cancel; icc_rejected; icc_card_removed; icc_no_confirmation; pos_timeout
Application workflow
Recommended controls: Load the original payment and current order state. Check operator permission and whether a reversal already exists. Choose the relevant reason for EMV when required. Submit the void and store the result with the order history. If settlement prevents a void, evaluate the refund path instead of repeatedly issuing voids.
Acceptance tests
Test an eligible unsettled payment, an already settled payment, a repeated operator action and an interrupted response. Keep customer messaging neutral while the final reversal outcome is unknown; do not show a completed reversal before the outcome is confirmed.