DraftOrderInput
The input fields used to create or update a draft order.
Anchor to FieldsFields
- Anchor to acceptAutomaticDiscountsaccept•
Automatic Discounts Whether or not to accept automatic discounts on the draft order during calculation. If false, only discount codes and custom draft order discounts (see
) will be applied. If true, eligible automatic discounts will be applied in addition to discount codes and custom draft order discounts.
- Anchor to allowDiscountCodesInCheckoutallow•
Discount Codes In Checkout Whether discount codes are allowed during checkout of this draft order.
- Anchor to appliedDiscountapplied•
Discount The discount that will be applied to the draft order. A draft order line item can have one discount. A draft order can also have one order-level discount.
- Anchor to billingAddressbilling•
Address The mailing address associated with the payment method.
- Anchor to customAttributescustom•
Attributes The extra information added to the draft order on behalf of the customer.
- Anchor to discountCodesdiscount•
Codes The list of discount codes that will be attempted to be applied to the draft order. If the draft isn't eligible for any given discount code it will be skipped during calculation.
- Anchor to emailemail•
The customer's email address.
- Anchor to lineItemsline•
Items The list of product variant or custom line item. Each draft order must include at least one line item.
NOTE: Draft orders don't currently support subscriptions.
- Anchor to localizedFieldslocalized•
Fields The localized fields attached to the draft order. For example, Tax IDs.
- Anchor to metafieldsmetafields•
The list of metafields attached to the draft order. An existing metafield can not be used when creating a draft order.
- Anchor to notenote•
The text of an optional note that a shop owner can attach to the draft order.
- Anchor to paymentTermspayment•
Terms The fields used to create payment terms.
- Anchor to phonephone•
The customer's phone number.
- Anchor to poNumberpo•
Number The purchase order number.
- Anchor to presentmentCurrencyCodepresentment•
Currency Code The payment currency of the customer for this draft order.
- Anchor to purchasingEntitypurchasing•
Entity The purchasing entity for the draft order.
- Anchor to reserveInventoryUntilreserve•
Inventory Until The time after which inventory reservation will expire.
- Anchor to sessionTokensession•
Token The unique token identifying the draft order.
- Anchor to shippingAddressshipping•
Address The mailing address to where the order will be shipped.
- Anchor to shippingLineshipping•
Line The shipping line object, which details the shipping method used.
- Anchor to sourceNamesource•
Name The source of the checkout. To use this field for sales attribution, you must register the channels that your app is managing. You can register the channels that your app is managing by completing this Google Form. After you've submitted your request, you need to wait for your request to be processed by Shopify. You can find a list of your channels in the Partner Dashboard, in your app's Marketplace extension. You need to specify the handle as the
value in your request. The handle is the channel that the order was placed from.
- Anchor to tagstags•
A comma separated list of tags that have been added to the draft order.
- Anchor to taxExempttax•
Exempt Whether or not taxes are exempt for the draft order. If false, then Shopify will refer to the taxable field for each line item. If a customer is applied to the draft order, then Shopify will use the customer's tax exempt field instead.
- Anchor to transformerFingerprinttransformer•
Fingerprint Fingerprint to guarantee bundles are handled correctly.
- Anchor to useCustomerDefaultAddressuse•
Customer Default Address Whether to use the customer's default address.
- Anchor to visibleToCustomervisible•
To Customer Whether the draft order will be visible to the customer on the self-serve portal.