UpdateOrderInput

Version 2024-11-01

📘

Important

The Buy with Prime API is offered as a preview and might change as we receive feedback and iterate on the interfaces. We are sharing this early documentation to help you learn about the Buy with Prime API as we write and iterate on the content.

Overview

Specifies the input fields required to update an Order or trigger execution of an Order, 'updateOrder' mutation.

Arguments

ArgumentDescription
aliases ([AliasInput])

A list of aliases that we want to associate with this Buy with Prime Order. This could include unique identifier of the order in merchant's store or display Id in the order of the merchant store. These aliases will be appended to any existing aliases provided during order creation.

Please note that we cannot update an existing alias using the specified API. We can only extend the list of aliases associated with an order.

The total number of aliases associated with an order are limited to 5.

The size should be greater than or equal to 0 and less than or equal to 5.

desiredExecutionState (OrderExecutionStateInput)

Denotes desired order execution state which will trigger the fulfillment flow following order updates if set to 'STARTED'. This is an optional field which will leave the order state as it is if not provided.

discounts (DiscountAllocationInput)

Promotional discounts allocated at the order level. Please note that this is not the total discount of the order. Any discount allocated to line items it should be set in the correspondingly at line item level. Similarly discount allocated to shipping should be set in the at delivery offer.

NOTE: For accurate refund estimations or Prime Fee calculations its preferable to set discounts at line-item level that Order level.

lineItems ([UpdateLineItemInput])

A list of the order's line items.

orderLinks ([OrderLinkInput])

Contains list of URLs to manage the order from shopper/merchant experiences. If external storefront URLs are provided, these will be surfaced on any Buy with Prime experiences for discoverability. These orderLinks will be appended to any existing orderLinks provided during order creation.

The total number of orderLinks associated with an order are limited to 5.

The size should be greater than or equal to 0 and less than or equal to 5.

packageInformation (UpdatePackageInformationInput)

Specifies the input fields required to update a package information in the Order.

payments (PaymentsInput)

Contains either a summary or the details of payments for the order that don't apply to any specific line items. Payments that apply to specific line items should be included in the appropriate line item input.

refunds (RefundInput)

Contains either a summary or details of refunds that have been issued on an order.

returns (ReturnsInput)

Represents an input for a return

taxes (TaxInput)

The tax(es) applied on the order level; not total tax for the order. These tax(es) does not apply to or override tax(es) applied at individual entities in the order.

totalPrice (OrderTotalSummaryInput)

Indicates total price on the Order that was computed on the existing order out side of Buy with Prime. If provided this will be used to ensure the provided monetary inputs to Buy with Prime on the order entities are in line with the expected OrderTotal we have.

This allows as a reinforcement signal for ensuring data around prices is consistent with the data provided by clients to minimize ambiguity for Buy with Prime Order API clients.