import type { CreateOrderProductItems } from './CreateOrderProductItems'; import type { Address } from './Address'; import type { CreateOrderPaymentInstrument } from './CreateOrderPaymentInstrument'; import type { CreateOrderShipment } from './CreateOrderShipment'; import type { CreateOrderPriceAdjustment } from './CreateOrderPriceAdjustment'; /** * @type CreateOrderRequest: Document representing the order create request. * * @property billingAddress: The billing address. The name from the billing address is required and is used as the customer\'s name (for guest customer). * * @property businessType: The business type. * * @property channelType: The sales channel. * * @property currency: A three letter uppercase currency code conforming to the [ISO 4217](https://www.iso.org/iso-4217-currency-codes.html) standard, or the string `N/A` indicating that a currency is not applicable. * - **Pattern:** /^([A-Z][A-Z][A-Z]|N\/A)$/ * * @property customerLocale: The locale of the customer who created the order. * - **Max Length:** 256 * * @property orderNo: The order number. This must be unique in the site and is generated if no orderNo is passed in payload. * - **Min Length:** 1 * - **Max Length:** 50 * * @property orderPriceAdjustments: The order-level price adjustments. * * @property orderTotal: The total price, including products, shipping, and tax. If this value does not match the calculated value (sum of all grossPrices minus PriceAdjustments), an InvalidOrderTotalException is thrown. * * @property paymentInstruments: The payment instruments list. * * @property paymentStatus: The payment status from the order. * * @property productItems: The product items. * * @property shipments: The shipments. * * @property taxTotal: The total tax amount. * */ export type CreateOrderRequest = { billingAddress: Address; businessType?: CreateOrderRequestBusinessTypeEnum; channelType?: CreateOrderRequestChannelTypeEnum; currency: string; customerLocale?: string; orderNo?: string; orderPriceAdjustments?: Array; orderTotal: number; paymentInstruments: Array; paymentStatus?: CreateOrderRequestPaymentStatusEnum; productItems: Array; shipments: Array; taxTotal: number; } & { [key: string]: any; }; export type CreateOrderRequestBusinessTypeEnum = 'b2c' | 'b2b'; export type CreateOrderRequestChannelTypeEnum = 'storefront' | 'callcenter' | 'marketplace' | 'dss' | 'store' | 'pinterest' | 'twitter' | 'facebookads' | 'subscriptions' | 'onlinereservation' | 'customerservicecenter' | 'instagramcommerce' | 'tiktok' | 'snapchat' | 'google' | 'whatsapp' | 'youtube'; export type CreateOrderRequestPaymentStatusEnum = 'paid' | 'not_paid';