This endpoint allows you to update specific details of an order item after the order has been created. You can modify special instructions, update product descriptions, change categories, or adjust item specifications without affecting quantity or pricing.
This endpoint is designed for updating item metadata and preparation instructions. For quantity changes or item removal, use the Patch Order Cart endpoint instead.
When an order item is updated, the following occurs:
Field Validation: All provided fields are validated for format and content
Audit Log: Change is recorded with timestamp and user information
Fulfillment Update: Kitchen/fulfillment systems are notified of changes
History Tracking: Previous values are preserved for audit trail
Status Check: Order status is verified to ensure modifications are allowed
Immutable Fields: Certain fields like quantity, pricing, and core product identifiers cannot be updated through this endpoint. Use the appropriate order modification endpoints for those changes.
Best Practice: Always include the updated_by field to maintain a clear audit trail of who made changes to the order.
{ "success": false, "message": "Order cannot be modified in current status", "error_code": "ORDER_NOT_MODIFIABLE", "current_status": "completed"}
Invalid Field Value
Copy
{ "success": false, "message": "Invalid value provided for field", "error_code": "INVALID_FIELD_VALUE", "field": "store_item_category", "provided_value": "InvalidCategory"}
Validation Error
Copy
{ "success": false, "message": "Field validation failed", "error_code": "VALIDATION_ERROR", "validation_errors": [ { "field": "special_instructions", "error": "Must be less than 500 characters" } ]}
Status Restrictions: Order items can only be updated when the order is in modifiable status (pending, accepted, in_progress). Completed or canceled orders cannot be modified.
Character Limits: Special instructions and descriptions have character limits. Ensure your updates stay within these bounds to avoid validation errors.