Skip to main content

Delete Sales Order Payment

DELETE 

/api/sales-orders/:salesOrderId/payments/:payment

Delete a payment from a sales order. Recalculates the order's payment_status afterward.

Guard: When the payment was created by applying a store credit (Credit-type payment) and a matching SalesCreditAllocation row exists (same sales_order_id and amount), this endpoint returns 422. Use the Unallocate Sales Credit endpoint under Customers instead — it reverses both the allocation and the corresponding payment atomically.

Authentication: Requires Bearer token.

Request

Responses

Successful response