Cancel order modifications
This endpoint cancels an order modification. It is meant for when, due to an error, a modification was not completely processed, and you do not wish to retry it. For this request, you need the order's changeRequestId, the unique identification code generated by the Create order modifications endpoint.
⚠️ Once an order modification has been successfully processed, canceling it is no longer possible. If you wish to revert the modifications made to an order, you will have to create a new order modification.
Permissions
Any user or API key must have at least one of the appropriate License Manager resources to be able to successfully run this request. Otherwise they will receive a status code 403 error. These are the applicable resources for this endpoint:
| Product | Category | Resource |
|---|---|---|
| Checkout | CheckoutResources | Orders Full Access |
| OMS | OMS access | Cancel order |
| OMS | OMS access | Change order |
You can create a custom role with that resource or use one of the following predefined roles:
| Role | Resource |
|---|---|
| Checkout Admin | Orders Full Access |
| OMS - Full access | <p>Cancel order</p><p>Change order</p> |
| IntegrationProfile - Fulfillment Oms | <p>Cancel order</p><p>Change order</p> |
| IntegrationProfile - Fulfillment Gateway | Cancel order |
| IntegrationProfile - Fulfillment Gateway Oms | <p>Cancel order</p><p>Change order</p> |
| inStore Sales Person | <p>Cancel order</p><p>Change order</p> |
❗ Assigning a predefined role to users or application keys usually grants permission to multiple License Manager resources. If some of these permissions are not necessary, consider creating a custom role instead. For more information regarding security, see Best practices for using application keys.
To learn more about machine authentication at VTEX, see Authentication overview.
Path parameters
Order ID of the order with the modifications you wish to cancel.
Once you make an order modification, you generate a requestId code that identifies the modifications made to that order. This field should be filled with that code. After cancelling an order modification, the changeRequestId will no longer be valid.
Query parameters
Name of the VTEX account that created the order.
Headers
Type of the content being sent.
HTTP Client Negotiation Accept Header. Indicates the types of responses the client can understand.
Request body
Example request
{
"reason": "I want to cancel this order modification request because it's stopped on a blocking error."
}Response
OK