Skip to main content

resetOrderPayment

Corrects a payment state that was set by mistake and moves the order's primary payment back to open. Unlike the other payment mutations it records no business event: use it only to undo a wrong entry. Fails with CONFLICT when the shop's payment state machine has no direct transition from the payment's current state to open, or when the order has no payment. Does nothing when the payment is already open. Fires the flows configured for the state change. Returns the order.

Required scopes​

The token needs the orders:write access scope.

resetOrderPayment(
id: ID!
): Order!

Arguments​

resetOrderPayment.id ● ID! non-null scalar​

ID of the order whose payment to reset.

Type​

Order object​

A customer order.