Skip to main content

orderRevisionRestore

Restore an order to a specific revision state.

Reverts the order to the state it was in at the specified revision number, effectively undoing changes made after that revision. This creates a new revision with the restored data.

Possible errors:

  • ORDER_NOT_FOUND: Order with the specified ID does not exist
  • ORDER_REVISION_NOT_FOUND_ERROR: Order revision with specified parameters does not exist
  • ORDER_REVISION_INVALID_RESTORE_ERROR: Cannot restore the specified revision (invalid state, already current)
  • ORDER_UPDATE_ERROR: Failed to restore order due to system error
  • VALIDATION_ERROR: Invalid order ID or revision number provided
  • FORBIDDEN: Insufficient permissions to restore order revisions

AUTH: Role=[order.OWNER,order.EDITOR] OR ('user is authenticated')

orderRevisionRestore(
orderId: Int!
revisionNumber: Int!
): Order!

Arguments

orderRevisionRestore.orderId ● Int! non-null scalar

Unique identifier of the order to restore

orderRevisionRestore.revisionNumber ● Int! non-null scalar

Revision number to restore the order to

Type

Order object