/** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.html#) */ declare module 'wix-ecom-backend' { /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.html#cart) */ const cart: Cart; /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.html#checkout) */ const checkout: Checkout; /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.html#currentCart) */ const currentCart: CurrentCart; /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.html#orders) */ const orders: Orders; /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#) */ interface Cart { /** * Adds catalog line items and/or custom line items to a cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#addToCart) */ addToCart(_id: string, options: Cart.AddToCartOptions): Promise; /** * Creates a new cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#createCart) */ createCart(options: Cart.CreateCartOptions): Promise; /** * Creates a checkout from the current site visitor’s cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#createCheckout) */ createCheckout(_id: string, options: Cart.CreateCheckoutOptions): Promise; /** * Deletes a cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#deleteCart) */ deleteCart(_id: string): Promise; /** * Estimates the subtotal and total for current site visitor’s cart. Totals include tax and are based on the selected carrier service, shipping address, and billing information. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#estimateTotals) */ estimateTotals(_id: string, options: Cart.EstimateTotalsOptions): Promise; /** * Retrieves a cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#getCart) */ getCart(_id: string): Promise; /** * Removes the coupon from a specified cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#removeCoupon) */ removeCoupon(_id: string): Promise; /** * Removes line items from the specified cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#removeLineItems) */ removeLineItems(_id: string, lineItemIds: Array): Promise; /** * Updates a specified cart's properties. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#updateCart) */ updateCart(_id: string, options: Cart.UpdateCartOptions): Promise; /** * Updates the quantity of one or more line items in a specified cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#updateLineItemsQuantity) */ updateLineItemsQuantity(_id: string, lineItems: Array): Promise; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Checkout.html#) */ interface Checkout { /** * Creates a checkout. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Checkout.html#createCheckout) */ createCheckout(options: Checkout.CreateCheckoutOptions): Promise; /** * Retrieves a checkout. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Checkout.html#getCheckout) */ getCheckout(_id: string): Promise; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#) */ interface CurrentCart { /** * Adds line items to the current site visitor's cart. Both catalog line items and custom line items are supported. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#addToCurrentCart) */ addToCurrentCart(options: CurrentCart.AddToCurrentCartOptions): Promise; /** * Creates a checkout from the current cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#createCheckoutFromCurrentCart) */ createCheckoutFromCurrentCart(options: CurrentCart.CreateCheckoutFromCurrentCartOptions): Promise; /** * Deletes the current site visitor's cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#deleteCurrentCart) */ deleteCurrentCart(): Promise; /** * Estimates the current cart's price totals (including tax), based on a selected carrier service, shipping address, and billing information. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#estimateCurrentCartTotals) */ estimateCurrentCartTotals(options: CurrentCart.EstimateCurrentCartTotalsOptions): Promise; /** * Retrieves the current site visitor's cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#getCurrentCart) */ getCurrentCart(): Promise; /** * Removes the coupon from the current site visitor's cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#removeCouponFromCurrentCart) */ removeCouponFromCurrentCart(): Promise; /** * Removes line items from the current site visitor's cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#removeLineItemsFromCurrentCart) */ removeLineItemsFromCurrentCart(lineItemIds: Array): Promise; /** * Updates the current site visitor's cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#updateCurrentCart) */ updateCurrentCart(options: CurrentCart.UpdateCurrentCartOptions): Promise; /** * Updates the quantity of one or more line items in the current site visitor's cart. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#updateCurrentCartLineItemQuantity) */ updateCurrentCartLineItemQuantity(lineItems: Array): Promise; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Events.html#) */ interface Events { /** * An event that triggers when a new cart is created. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Events.html#onCartCreated) */ onCartCreated(event: Events.ecomV1CartCartCreated): void; /** * An event that triggers when a cart is deleted. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Events.html#onCartDeleted) */ onCartDeleted(event: Events.ecomV1CartCartDeleted): void; /** * An event that triggers when a cart is updated. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Events.html#onCartUpdated) */ onCartUpdated(event: Events.ecomV1CartCartUpdated): void; /** * An event that triggers when an order is approved. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Events.html#onOrderApproved) */ onOrderApproved(event: Events.ecomV1OrderOrderApprovedEvent): void; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Orders.html#) */ interface Orders { /** * Retrieves an order. * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Orders.html#getOrder) */ getOrder(_id: string): Promise; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Cart.html#) */ namespace Cart { type ActionEvent = { bodyAsJson?: string; }; type AddToCartOptions = { /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type AddToCartRequest = { /** * Cart ID. */ _id: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type AddToCartResponse = { /** * Updated cart. */ cart?: Cart.Cart; }; type AddToCurrentCartRequest = { /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type AdditionalFee = { /** * Additional fee's unique code (or ID) for future processing */ code?: string; /** * Translated additional fee's name */ name?: string; /** * Additional fee's price */ price?: Cart.MultiCurrencyPrice; /** * Provider's app id */ providerAppId?: string; /** * Tax details */ taxDetails?: Cart.ItemTaxFullDetails; }; type Address = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Cart.StreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type AddressLocation = { /** * Address latitude. */ latitude?: number; /** * Address longitude. */ longitude?: number; }; type AddressWithContact = { /** * Address. */ address?: Cart.Address; /** * Contact details. */ contactDetails?: Cart.ApiFullAddressContactDetails; }; type ApiFullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: Cart.VatId; }; type ApplicationError = { code?: string; data?: Object; description?: string; }; type AppliedCoupon = { /** * Coupon code */ code?: string; /** * Converted discount value */ convertedDiscountValue?: string; /** * Coupon internal ID */ couponId?: string; /** * Type (e.g., moneyOff, percentOff) */ couponType?: string; /** * Discount value */ discountValue?: string; /** * Coupon name */ name?: string; }; type AppliedDiscount = { /** * Coupon details. */ coupon?: Cart.V1Coupon; /** * Discount rule */ discountRule?: Cart.DiscountRule; /** * Discount type. */ discountType?: string; /** * IDs of the line items the discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: Cart.V1MerchantDiscount; }; type AppliedDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: Cart.V1Coupon; /** * Discount rule */ discountRule?: Cart.DiscountRule; /** * Merchant discount. */ merchantDiscount?: Cart.V1MerchantDiscount; }; type AutoTaxFallbackCalculationDetails = { /** * invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */ error?: Cart.ApplicationError; /** * Reason for fallback. Supported values: * + `"AUTO_TAX_FAILED"` * + `"AUTO_TAX_DEACTIVATED"` */ fallbackReason?: string; }; type BuyerDetails = { /** * Email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; /** * Phone number */ phone?: string; }; type BuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see the [Contacts API](https://www.wix.com/velo/reference/wix-crm-backend/contacts/introduction). */ contactId?: string; /** * Member ID - if the buyer is a site member. */ memberId?: string; /** * User ID - if the cart owner is a Wix user. */ userId?: string; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type BuyerInfoIdOneOf = { /** * Member ID - if the buyer is a site member. */ memberId?: string; /** * User ID - if the cart owner is a Wix user. */ userId?: string; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type CalculatedLineItem = { /** * Line item ID. */ lineItemId?: string; /** * Type of selected payment option for current item. Defaults to `"FULL_PAYMENT_ONLINE"`. * + `"FULL_PAYMENT_ONLINE"` - The entire payment for this item happens as part of the checkout. * + `"FULL_PAYMENT_OFFLINE"` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `"MEMBERSHIP"` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` will be 0. */ paymentOption?: string; /** * Price breakdown for this line item. */ pricesBreakdown?: Cart.LineItemPricesData; }; type CalculationErrors = { /** * Carrier errors. */ carrierErrors?: Cart.CarrierErrors; /** * Coupon calculation error. */ couponCalculationError?: Cart.Details; /** * Discount Rule calculation error. */ discountsCalculationError?: Cart.Details; /** * General shipping calculation error. */ generalShippingCalculationError?: Cart.Details; /** * Gift card calculation error. */ giftCardCalculationError?: Cart.Details; /** * Membership payment methods calculation errors * For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid */ membershipError?: Cart.Details; /** * Order validation errors. */ orderValidationErrors?: Array; /** * Tax calculation error. */ taxCalculationError?: Cart.Details; }; type CalculationErrorsShippingCalculationErrorOneOf = { /** * Carrier errors. */ carrierErrors?: Cart.CarrierErrors; /** * General shipping calculation error. */ generalShippingCalculationError?: Cart.Details; }; type CarrierError = { /** * Carrier ID. */ carrierId?: string; /** * Error details. */ error?: Cart.Details; }; type CarrierErrors = { /** * Carrier errors. */ errors?: Array; }; type CarrierServiceOption = { /** * Carrier ID. */ carrierId?: string; /** * Shipping options offered by this carrier for this request. */ shippingOptions?: Array; }; type Cart = { /** * Date and time the cart was created. */ _createdDate?: Date; /** * Cart ID. */ _id?: string; /** * Date and time the cart was updated. */ _updatedDate?: Date; /** * Cart discounts. */ appliedDiscounts?: Array; /** * Buyer information. */ buyerInfo?: Cart.BuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * ID of the checkout related to this cart. */ checkoutId?: string; /** * Contact info. */ contactInfo?: Cart.AddressWithContact; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * Currency used for pricing. */ currency?: string; /** * Line items. */ lineItems?: Array; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrices?: boolean; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type CartAddress = { /** * Address */ address?: Cart.CommonAddress; /** * Contact details */ contactDetails?: Cart.FullAddressContactDetails; }; type CartCompletedEvent = { /** * Coupon applied to this cart */ appliedCoupon?: Cart.AppliedCoupon; /** * Customer's billing address */ billingAddress?: Cart.CartAddress; /** * Customer's Wix ID */ buyerInfo?: Cart.V1BuyerInfo; /** * Message from the customer */ buyerNote?: string; cartId?: string; /** * Time the cart was created */ completedTime?: Date; /** * Currency used for pricing in this store */ currency?: Cart.Currency; /** * Cart shipping information */ shippingInfo?: Cart.ShippingInfo; /** * Totals for order's line items */ totals?: Cart.Totals; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type CartDiscount = { /** * Coupon details. */ coupon?: Cart.Coupon; /** * Merchant discount. */ merchantDiscount?: Cart.MerchantDiscount; }; type CartDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: Cart.Coupon; /** * Merchant discount. */ merchantDiscount?: Cart.MerchantDiscount; }; type CatalogReference = { /** * App ID of the catalog the item comes from. For example, the Wix Stores `appId` is `"1380b703-ce81-ff05-f115-39571d94dfcd"`. */ appId?: string; /** * ID of the item within its catalog. For example, `productId` for Wix Stores. */ catalogItemId?: string; /** * Additional info in key:value form. For example, for a product variant from Wix Stores Catalog, `options` field would hold something like one of the following: * + `{"Size": "M", "Color": "Red"}` * + `{"variantId": ""}`. */ options?: Object; }; type Color = { /** * HEX or RGB color code for display. */ code?: string; /** * Description line color name in site's default language. */ original?: string; /** * Description line color name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type CommonAddress = { /** * Main address line, usually street and number as free text. */ addressLine?: string; /** * Main address line, usually street and number as free text. */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains Apt, Suite, and Floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Country code. */ country?: string; /** * Zip/postal code. */ postalCode?: string; /** * Street name and number. */ streetAddress?: Cart.StreetAddress; /** * Subdivision. Usually a state, region, prefecture, or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */ subdivision?: string; }; type CommonAddressStreetOneOf = { /** * Main address line, usually street and number as free text. */ addressLine?: string; /** * Street name and number. */ streetAddress?: Cart.StreetAddress; }; type Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon code. */ code?: string; }; type CreateCartOptions = { /** * Cart info. */ cartInfo?: Cart.Cart; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart. */ merchantDiscounts?: Array; }; type CreateCartRequest = { /** * Cart info. */ cartInfo?: Cart.Cart; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart. */ merchantDiscounts?: Array; }; type CreateCartResponse = { /** * Cart. */ cart?: Cart.Cart; }; type CreateCheckoutFromCurrentCartRequest = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Cart.Address; /** * Sales channel type. Supported values: * + `"AMAZON"` * + `"BACKOFFICE_MERCHANT"` * + `"EBAY"` * + `"OTHER_PLATFORM"` * + `"POS"` * + `"WEB"` * + `"WISH"` * + `"WIX_APP_STORE"` * + `"WIX_INVOICES"` */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: Cart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Cart.Address; }; type CreateCheckoutOptions = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Cart.Address; /** * Sales channel type. Supported values: * + `"AMAZON"` * + `"BACKOFFICE_MERCHANT"` * + `"EBAY"` * + `"OTHER_PLATFORM"` * + `"POS"` * + `"WEB"` * + `"WISH"` * + `"WIX_APP_STORE"` * + `"WIX_INVOICES"` */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: Cart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Cart.Address; }; type CreateCheckoutRequest = { /** * Cart ID. */ _id: string; /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Cart.Address; /** * Sales channel type. Supported values: * + `"AMAZON"` * + `"BACKOFFICE_MERCHANT"` * + `"EBAY"` * + `"OTHER_PLATFORM"` * + `"POS"` * + `"WEB"` * + `"WISH"` * + `"WIX_APP_STORE"` * + `"WIX_INVOICES"` */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: Cart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Cart.Address; }; type CreateCheckoutResponse = { /** * The newly created checkout's ID. */ checkoutId?: string; }; type Currency = { /** * Currency code */ code?: string; /** * Currency symbol */ symbol?: string; }; type CustomLineItem = { /** * Custom line item ID. Defaults to an auto-generated ID. */ _id?: string; /** * Custom line item description lines. Used for displaying the cart, checkout and order. */ descriptionLines?: Array; /** * Custom line item media. Supported formats: * + Link to an image/video from the [Wix Media Manager](https://support.wix.com/en/article/wix-media-about-the-media-manager) - `"wix:image://v1/3c76e2_c53...4ea4~mv2.jpg#originWidth=1000&originHeight=1000"`. * + An image from the web - `"http(s)://"`. */ media?: string; /** * Custom line item name. */ name?: string; /** * Custom line item price. */ price?: string; /** * Custom line item quantity. */ quantity?: number; }; type DeleteCartRequest = { /** * ID of the cart to delete. */ _id: string; }; type DeleteCartResponse = {}; type DeleteCurrentCartRequest = {}; type DeliveryLogistics = { /** * Expected delivery time, in free text. For example, "3-5 business days". */ deliveryTime?: string; /** * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". */ instructions?: string; /** * Pickup details. */ pickupDetails?: Cart.PickupDetails; }; type Description = { /** * Subscription option description. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type DescriptionLine = { /** * Description line color value. */ colorInfo?: Cart.Color; /** * Description line name. */ name?: Cart.DescriptionLineName; /** * Description line plain text value. */ plainText?: Cart.PlainTextValue; }; type DescriptionLineDescriptionLineValueOneOf = {}; type DescriptionLineName = { /** * Description line name in site's default language. */ original?: string; /** * Description line name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type DescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: Cart.Color; /** * Description line plain text value. */ plainText?: Cart.PlainTextValue; }; type Details = { applicationError?: Cart.ApplicationError; /** * Deprecated in APIs. Used to enable migration from rendering arbitrary tracing to rest response. */ tracing?: Record; validationError?: Cart.ValidationError; }; type DetailsKindOneOf = { applicationError?: Cart.ApplicationError; validationError?: Cart.ValidationError; }; type DiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: Cart.MultiCurrencyPrice; /** * Discount rule name */ name?: Cart.DiscountRuleName; }; type DiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Discount rule name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type DomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Cart.ActionEvent; createdEvent?: Cart.EntityCreatedEvent; deletedEvent?: Cart.EntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Cart.ExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Cart.EntityUpdatedEvent; }; type DomainEventBodyOneOf = { actionEvent?: Cart.ActionEvent; createdEvent?: Cart.EntityCreatedEvent; deletedEvent?: Cart.EntityDeletedEvent; extendedFieldsUpdatedEvent?: Cart.ExtendedFieldsUpdatedEvent; updatedEvent?: Cart.EntityUpdatedEvent; }; type Empty = {}; type EntityCreatedEvent = { entityAsJson?: string; }; type EntityDeletedEvent = {}; type EntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type EstimateCurrentCartTotalsRequest = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Cart.Address; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Cart.SelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: Cart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Cart.Address; }; type EstimateTotalsOptions = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Cart.Address; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Cart.SelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: Cart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Cart.Address; }; type EstimateTotalsRequest = { /** * Cart ID. */ _id: string; /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Cart.Address; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Cart.SelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: Cart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Cart.Address; }; type EstimateTotalsResponse = { /** * Additional fees */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Calculated line items. */ calculatedLineItems?: Array; /** * Calculation errors. */ calculationErrors?: Cart.CalculationErrors; /** * Cart. */ cart?: Cart.Cart; /** * Currency used for pricing in this store. */ currency?: string; /** * Applied gift card. */ giftCard?: Cart.GiftCard; /** * Information about valid and invalid memberships, and which ones are selected for usage. */ membershipOptions?: Cart.MembershipOptions; /** * Remaining amount for the order to be fully paid. */ payLater?: Cart.PriceSummary; /** * Minimal amount to pay in order to place the order. */ payNow?: Cart.PriceSummary; /** * Price summary. */ priceSummary?: Cart.PriceSummary; /** * Shipping information. */ shippingInfo?: Cart.ShippingInformation; /** * Tax summary. */ taxSummary?: Cart.TaxSummary; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type ExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type FieldViolation = { data?: Object; description?: string; field?: string; /** * applicable when violated_rule=OTHER */ ruleName?: string; /** * Suppoerted values: * - `'DECIMAL_GT'` * - `'DECIMAL_GTE'` * - `'DECIMAL_LT'` * - `'DECIMAL_LTE'` * - `'DECIMAL_MAX_SCALE'` * - `'FORMAT'` * - `'INVALID_ENUM_VALUE'` * - `'MAX'` * - `'MAX_LENGTH'` * - `'MAX_SIZE'` * - `'MIN'` * - `'MIN_LENGTH'` * - `'MIN_SIZE'` * - `'OTHER'` * - `'REQUIRED_FIELD'` * - `'VALIDATION'` */ violatedRule?: string; }; type FullAddressContactDetails = { /** * Contact's company */ company?: string; /** * Email associated with the address */ email?: string; /** * Contact first name */ firstName?: string; /** * Contact last name */ lastName?: string; /** * Contact phone number */ phone?: string; /** * tax info (Currently usable only in Brazil) */ vatId?: Cart.VatId; }; type GetCartByCheckoutIdRequest = { /** * Checkout ID. */ _id: string; }; type GetCartByCheckoutIdResponse = { /** * The requested cart. */ cart?: Cart.Cart; }; type GetCartRequest = { /** * ID of the cart to retrieve. */ _id: string; }; type GetCartResponse = { /** * The requested cart. */ cart?: Cart.Cart; }; type GetCurrentCartRequest = {}; type GetCurrentCartResponse = { /** * Current session's active cart. */ cart?: Cart.Cart; }; type GiftCard = { /** * Gift Card ID. */ _id?: string; /** * Gift card value. */ amount?: Cart.MultiCurrencyPrice; /** * App ID of the gift card provider. */ appId?: string; /** * Gift card obfuscated code. */ obfuscatedCode?: string; }; type Group = { /** * Item ID (when the coupon scope is limited to just one item). */ entityId?: string; /** * Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */ name?: string; }; type InvalidMembership = { /** * Membership details. */ membership?: Cart.Membership; /** * Reason why this membership is invalid and cannot be used. */ reason?: string; }; type ItemAvailabilityInfo = { /** * Quantity available. */ quantityAvailable?: number; /** * Item availability status. */ status?: string; }; type ItemTaxFullDetails = { /** * If breakdown exists, the sum of rates in the breakdown must equal `tax_rate`. */ rateBreakdown?: Array; /** * Tax rate %, as a decimal point between 0 and 1. */ taxRate?: string; /** * Amount for which tax is calculated. */ taxableAmount?: Cart.MultiCurrencyPrice; /** * Calculated tax, based on `taxable_amount` and `tax_rate`. */ totalTax?: Cart.MultiCurrencyPrice; }; type ItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type LineItem = { /** * Line item ID. */ _id?: string; /** * Item availability details. */ availability?: Cart.ItemAvailabilityInfo; /** * Catalog and item reference. Holds IDs for the item and the catalog it came from, as well as further optional info. */ catalogReference?: Cart.CatalogReference; /** * Line item description lines. Used for displaying the cart, checkout and order. */ descriptionLines?: Array; /** * Item price **before** catalog-defined discount. Defaults to `price` when not provided. */ fullPrice?: Cart.MultiCurrencyPrice; /** * Line item image details. */ image?: string; /** * Item type. Either a preset type or custom. */ itemType?: Cart.ItemType; /** * Type of selected payment option for current item. Defaults to `"FULL_PAYMENT_ONLINE"`. * + `"FULL_PAYMENT_ONLINE"` - The entire payment for this item happens as part of the checkout. * + `"FULL_PAYMENT_OFFLINE"` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `"MEMBERSHIP"` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` will be 0. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. */ physicalProperties?: Cart.PhysicalProperties; /** * Item price **after** catalog-defined discount and line item discounts. */ price?: Cart.MultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Cart.MultiCurrencyPrice; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: Cart.PriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: Cart.ProductName; /** * Item quantity. */ quantity?: number; /** * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID. * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID. * + in most cases, this field is the name as `catalogReference.catalogItemId`. * + Used in membership validation. */ rootCatalogItemId?: string; /** * Service properties. When relevant, this contains information such as date and number of participants. */ serviceProperties?: Cart.ServiceProperties; /** * URL to the item's page on the site. */ url?: string; }; type LineItemPricesData = { /** * Total price **after** catalog-defined discount and line item discounts. */ lineItemPrice?: Cart.MultiCurrencyPrice; /** * Catalog price after catalog discount and automatic discounts. */ price?: Cart.MultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Cart.MultiCurrencyPrice; /** * Tax details. */ taxDetails?: Cart.ItemTaxFullDetails; /** * Total discount for all line items. */ totalDiscount?: Cart.MultiCurrencyPrice; /** * Total price after discounts and after tax. */ totalPriceAfterTax?: Cart.MultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Cart.MultiCurrencyPrice; }; type LineItemQuantityUpdate = { /** * Line item ID. */ _id?: string; /** * New quantity. Number must 1 or higher. */ quantity?: number; }; type Membership = { /** * Membership ID. */ _id?: string; /** * Additional data about this membership. */ additionalData?: Object; /** * ID of the application providing this payment option. */ appId?: string; /** * Optional - For a membership that has limited credits, information about credit usage. */ credits?: Cart.MembershipPaymentCredits; /** * Optional - TMembership expiry date. */ expirationDate?: Date; /** * Line item IDs which are "paid" for by this membership. */ lineItemIds?: Array; /** * The name of this membership. */ name?: Cart.MembershipName; }; type MembershipName = { /** * The name of this membership */ original?: string; /** * Membership name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type MembershipOptions = { /** * List of payment options that can be used. */ eligibleMemberships?: Array; /** * List of payment options that are owned by the member, but cannot be used due to reason provided. */ invalidMemberships?: Array; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Array; }; type MembershipPaymentCredits = { /** * How much credit remained for this membership */ remaining?: number; /** * How much credit this membership has in total */ total?: number; }; type MerchantDiscount = { /** * Discount value. */ amount?: Cart.MultiCurrencyPrice; }; type MerchantDiscountInput = { /** * Discount amount. */ amount?: string; /** * IDs of the line items the discount applies to. */ lineItemIds?: Array; }; type MultiCurrencyPrice = { /** * Amount. */ amount?: string; /** * Converted amount. */ convertedAmount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; /** * Converted amount formatted with currency symbol. */ formattedConvertedAmount?: string; }; type OtherCharge = { /** * Price of added cost. */ price?: Cart.MultiCurrencyPrice; /** * Type of additional cost. */ type?: string; }; type PhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit is taken from `order.weightUnit`. Supported values: * + `"KG"` * + `"LB"` */ weight?: number; }; type PickupDetails = { /** * Pickup address. */ address?: Cart.Address; /** * Whether the pickup address is that of a business - this may effect tax calculation. */ businessLocation?: boolean; /** * Pickup method */ pickupMethod?: string; }; type PlainTextValue = { /** * Description line plain text value in site's default language. */ original?: string; /** * Description line plain text value translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type PriceDescription = { /** * **Required** - Original price description (in site's default language). */ original?: string; /** * Product name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type PriceSummary = { /** * Total additional fees price. */ additionalFees?: Cart.MultiCurrencyPrice; /** * Total calculated discount value. */ discount?: Cart.MultiCurrencyPrice; /** * Total shipping price, before discounts and before tax. */ shipping?: Cart.MultiCurrencyPrice; /** * Subtotal of all line items, before discounts and before tax. */ subtotal?: Cart.MultiCurrencyPrice; /** * Total tax. */ tax?: Cart.MultiCurrencyPrice; /** * Total price after discounts, gift cards, and tax. */ total?: Cart.MultiCurrencyPrice; }; type ProductName = { /** * *Required** - Original product name (in site's default language). */ original?: string; /** * Description product name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type RemoveCouponFromCurrentCartRequest = {}; type RemoveCouponRequest = { /** * Cart ID. */ _id: string; }; type RemoveCouponResponse = { /** * Updated cart. */ cart?: Cart.Cart; }; type RemoveLineItemsFromCurrentCartRequest = { /** * IDs of the line items to remove from the cart. */ lineItemIds: Array; }; type RemoveLineItemsRequest = { /** * Cart ID. */ _id: string; /** * IDs of the line items to remove from the cart. */ lineItemIds: Array; }; type RemoveLineItemsResponse = { /** * Updated cart. */ cart?: Cart.Cart; }; type Scope = { /** * Coupon scope's applied group (e.g., event or ticket in Wix Events) */ group?: Cart.Group; /** * Scope namespace (Wix Stores, Wix Bookings, Wix Events) */ namespace?: string; }; type SecuredMedia = { /** * Media ID in media manager. */ _id?: string; /** * Original file name. */ fileName?: string; /** * File type. */ fileType?: string; }; type SelectedCarrierServiceOption = { /** * This carrier's unique ID */ carrierId?: string; /** * Unique identifier of selected option. For example, "usps_std_overnight". */ code?: string; /** * Shipping costs. */ cost?: Cart.SelectedCarrierServiceOptionPrices; /** * Delivery logistics. */ logistics?: Cart.DeliveryLogistics; /** * Other charges */ otherCharges?: Array; /** * Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) */ requestedShippingOption?: boolean; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type SelectedCarrierServiceOptionOtherCharge = { /** * Price of added charge. */ cost?: Cart.SelectedCarrierServiceOptionPrices; /** * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'. */ details?: string; /** * Type of additional cost. */ type?: string; }; type SelectedCarrierServiceOptionPrices = { /** * Shipping price before discount and before tax. */ price?: Cart.MultiCurrencyPrice; /** * Tax details. */ taxDetails?: Cart.ItemTaxFullDetails; /** * Shipping discount before tax. */ totalDiscount?: Cart.MultiCurrencyPrice; /** * Total shipping price, after discount and after tax. */ totalPriceAfterTax?: Cart.MultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Cart.MultiCurrencyPrice; }; type SelectedMembership = { /** * Membership ID. */ _id?: string; /** * ID of the app providing this payment option. */ appId?: string; /** * IDs of the line items this membership applies to. */ lineItemIds?: Array; }; type SelectedMemberships = { /** * Selected memberships. */ memberships?: Array; }; type SelectedShippingOption = { /** * Carrier ID. */ carrierId?: string; /** * Selected shipping option code. For example, "usps_std_overnight". */ code?: string; }; type ServiceProperties = { /** * The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room. */ numberOfParticipants?: number; /** * The date and time for which the service is supposed to be provided. For example, the time of the class. */ scheduledDate?: Date; }; type ShippingInfo = { /** * Pickup details when this object describes pickup */ pickupDetails?: Cart.V1PickupDetails; /** * Shipment details when this object describes shipment */ shippingAddress?: Cart.CartAddress; /** * Selected shipping rule details */ shippingRuleDetails?: Cart.ShippingRuleDetails; }; type ShippingInfoDetailsOneOf = { /** * Pickup details when this object describes pickup */ pickupDetails?: Cart.V1PickupDetails; /** * Shipment details when this object describes shipment */ shippingAddress?: Cart.CartAddress; }; type ShippingInformation = { /** * All shipping options. */ carrierServiceOptions?: Array; /** * Shipping region. */ region?: Cart.ShippingRegion; /** * Selected shipping option. */ selectedCarrierServiceOption?: Cart.SelectedCarrierServiceOption; }; type ShippingOption = { /** * Unique code of provided shipping option like "usps_std_overnight". * For legacy calculators this would be the UUID of the option. */ code?: string; /** * Sipping price information. */ cost?: Cart.ShippingPrice; /** * Delivery logistics. */ logistics?: Cart.DeliveryLogistics; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ShippingPrice = { /** * Other costs such as insurance, handling & packaging for fragile items, etc. */ otherCharges?: Array; /** * Shipping price. */ price?: Cart.MultiCurrencyPrice; }; type ShippingRegion = { /** * Shipping region ID. */ _id?: string; /** * Shipping region name. */ name?: string; }; type ShippingRuleDetails = { /** * Rule title (as provided by the store owner) */ deliveryOption?: string; /** * Shipping option delivery time */ estimatedDeliveryTime?: string; /** * Selected option ID */ optionId?: string; /** * Selected shipping rule ID */ ruleId?: string; }; type StreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type Subdivision = { /** * Short subdivision code. */ code?: string; /** * Subdivision full name. */ name?: string; }; type SubscriptionOptionInfo = { /** * Subscription option description. */ description?: Cart.Description; /** * Subscription option settings. */ subscriptionSettings?: Cart.SubscriptionSettings; /** * Subscription option title. */ title?: Cart.Title; }; type SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type TaxCalculationDetails = { /** * Error details and reason for tax rate fallback. */ autoTaxFallbackDetails?: Cart.AutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; /** * Rate calculation type. Supported values: * + `"AUTO_RATE"` * + `"FALLBACK_RATE"` * + `"MANUAL_RATE"` * + `"NO_TAX_COLLECTED"` */ rateType?: string; }; type TaxCalculationDetailsCalculationDetailsOneOf = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Cart.AutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; }; type TaxRateBreakdown = { /** * Type of tax against which the calculation was performed. */ name?: string; /** * Rate at which this tax detail was calculated. */ rate?: string; /** * Amount of tax for this tax detail. */ tax?: Cart.MultiCurrencyPrice; }; type TaxSummary = { /** * Tax calculator that was active when the order was created. */ calculationDetails?: Cart.TaxCalculationDetails; /** * Amount for which tax is calculated, added from line items. */ taxableAmount?: Cart.MultiCurrencyPrice; /** * Calculated tax, added from line items. */ totalTax?: Cart.MultiCurrencyPrice; }; type Title = { /** * Subscription option name. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type Totals = { /** * Total calculated discount value, according to order.discount */ discount?: number; /** * Total line items quantity */ quantity?: number; /** * Total shipping price, including tax */ shipping?: number; /** * Subtotal of all line items, before tax */ subtotal?: number; /** * Total tax */ tax?: number; /** * Total price */ total?: number; /** * Total items weight */ weight?: number; }; type UpdateCartInfo = { /** * Date and time the cart was created. */ _createdDate?: Date; /** * ID of the cart to be updated. */ _id?: string; /** * Date and time the cart was updated. */ _updatedDate?: Date; /** * Cart discounts. */ appliedDiscounts?: Array; /** * Buyer information. */ buyerInfo?: Cart.BuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * ID of the checkout related to this cart. */ checkoutId?: string; /** * Contact info. */ contactInfo?: Cart.AddressWithContact; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * Currency used for pricing. */ currency?: string; /** * Line items. */ lineItems?: Array; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrices?: boolean; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type UpdateCartOptions = { /** * The information for the cart being updated. */ cartInfo: Cart.UpdateCartInfo; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */ merchantDiscounts?: Array; }; type UpdateCartRequest = { /** * Cart info. */ cartInfo?: Cart.Cart; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */ merchantDiscounts?: Array; }; type UpdateCartResponse = { /** * Updated Cart. */ cart?: Cart.Cart; }; type UpdateCurrentCartLineItemQuantityRequest = { /** * Line item IDs and their new quantity. */ lineItems: Array; }; type UpdateLineItemsQuantityRequest = { /** * Cart ID. */ _id: string; /** * Line item IDs and their new quantity. */ lineItems: Array; }; type UpdateLineItemsQuantityResponse = { /** * Updated cart. */ cart?: Cart.Cart; }; type V1BuyerInfo = { /** * Customer details */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer's relationship to the website */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; }; type V1Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: Cart.MultiCurrencyPrice; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type V1MerchantDiscount = { /** * Discount value. */ amount?: Cart.MultiCurrencyPrice; }; type V1PickupDetails = { /** * Customer details */ buyerDetails?: Cart.BuyerDetails; /** * Pickup address */ pickupAddress?: Cart.CommonAddress; /** * Store owner's pickup instructions */ pickupInstructions?: string; }; type ValidationError = { fieldViolations?: Array; }; type VatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Checkout.html#) */ namespace Checkout { type ActionEvent = { bodyAsJson?: string; }; type AdditionalFee = { /** * Additional fee's unique code (or ID) for future processing */ code?: string; /** * Translated additional fee's name */ name?: string; /** * Additional fee's price */ price?: Checkout.MultiCurrencyPrice; /** * Provider's app id */ providerAppId?: string; /** * Tax details */ taxDetails?: Checkout.ItemTaxFullDetails; }; type Address = { /** * Address line 1 (free text) */ addressLine1?: string; /** * address line */ addressLine2?: string; /** * City name */ city?: string; /** * Company name */ company?: string; /** * Country code (2 letters) */ country?: string; /** * Email address */ email?: string; /** * Addressee name */ fullName?: Checkout.FullName; /** * Phone number */ phone?: string; /** * Address line 1 (street) */ street?: Checkout.Street; /** * State or district */ subdivision?: string; /** * Tax information (for Brazil only) */ vatId?: Checkout.VatId; /** * ZIP/postal code */ zipCode?: string; }; type AddressAddressLine1OptionsOneOf = { /** * Address line 1 (free text) */ addressLine1?: string; /** * Address line 1 (street) */ street?: Checkout.Street; }; type AddressWithContact = { /** * Address. */ address?: Checkout.ApiAddress; /** * Contact details. */ contactDetails?: Checkout.FullAddressContactDetails; }; type ApiAddress = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Checkout.StreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type ApplicationError = { code?: string; data?: Object; description?: string; }; type AppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type AppliedDiscount = { /** * Coupon details. */ coupon?: Checkout.Coupon; /** * Discount rule */ discountRule?: Checkout.DiscountRule; /** * Discount type. */ discountType?: string; /** * IDs of the line items the discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: Checkout.MerchantDiscount; }; type AppliedDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: Checkout.Coupon; /** * Discount rule */ discountRule?: Checkout.DiscountRule; /** * Merchant discount. */ merchantDiscount?: Checkout.MerchantDiscount; }; type AutoTaxFallbackCalculationDetails = { /** * invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */ error?: Checkout.ApplicationError; /** * reason for fallback */ fallbackReason?: string; }; type BillingInfo = { /** * Full billing address */ address?: Checkout.Address; /** * Deprecated (use paymentProviderTransactionId instead) */ externalTransactionId?: string; /** * Payment date */ paidDate?: Date; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; /** * Transaction ID from payment provider (e.g., PayPal, Square, Stripe) transaction ID */ paymentProviderTransactionId?: string; /** * Whether order can be refunded by payment provider (manually or automatic) */ refundableByPaymentProvider?: boolean; }; type BuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see [Contacts API](https://www.wix.com/velo/reference/wix-crm-backend/contacts/introduction). */ contactId?: string; /** * Buyer email address. */ email?: string; /** * Member ID - If the buyer is a site member. */ memberId?: string; /** * + When `true` - checkout doesn't have an owner yet and anyone can access it. The first to access it will be new owner. * + If `false`, the value in `checkout.createdBy` is the owner. */ openAccess?: boolean; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type BuyerInfoIdOneOf = { /** * Member ID - If the buyer is a site member. */ memberId?: string; /** * + When `true` - checkout doesn't have an owner yet and anyone can access it. The first to access it will be new owner. * + If `false`, the value in `checkout.createdBy` is the owner. */ openAccess?: boolean; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type CalculationErrors = { /** * Carrier errors. */ carrierErrors?: Checkout.CarrierErrors; /** * Coupon calculation error. */ couponCalculationError?: Checkout.Details; /** * Discount Rule calculation error. */ discountsCalculationError?: Checkout.Details; /** * General shipping calculation error. */ generalShippingCalculationError?: Checkout.Details; /** * Gift card calculation error. */ giftCardCalculationError?: Checkout.Details; /** * Membership payment methods calculation errors * For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid */ membershipError?: Checkout.Details; /** * Order validation errors. */ orderValidationErrors?: Array; /** * Tax calculation error. */ taxCalculationError?: Checkout.Details; }; type CalculationErrorsShippingCalculationErrorOneOf = { /** * Carrier errors. */ carrierErrors?: Checkout.CarrierErrors; /** * General shipping calculation error. */ generalShippingCalculationError?: Checkout.Details; }; type CarrierError = { /** * Carrier ID. */ carrierId?: string; /** * Error details. */ error?: Checkout.Details; }; type CarrierErrors = { /** * Carrier errors. */ errors?: Array; }; type CarrierServiceOption = { /** * Carrier ID. */ carrierId?: string; /** * Shipping options offered by this carrier for this request. */ shippingOptions?: Array; }; type CatalogReference = { /** * App ID of the catalog the item comes from. For example, the Wix Stores `appId` is `"1380b703-ce81-ff05-f115-39571d94dfcd"`. */ appId?: string; /** * ID of the item within its catalog. For example, `productId` for Wix Stores. */ catalogItemId?: string; /** * Additional info in key:value form. For example, for a product variant from Wix Stores Catalog, `options` field would hold something like one of the following: * + `{"Size": "M", "Color": "Red"}` * + `{"variantId": ""}`. */ options?: Object; }; type ChannelInfo = { /** * Sales channel that submitted the subscription */ type?: string; }; type ChargeDetails = { /** * Discount applied for this line item */ discount?: number; /** * price of line item (depends on subscription option) */ price?: number; /** * Tax applied for this line item */ tax?: number; /** * Is tax applied for this line item */ taxIncludedInPrice?: boolean; /** * Total price charged to the customer (for this line items) after computation of quantity and discount */ totalPrice?: number; }; type Checkout = { /** * Date and time the checkout was created. */ _createdDate?: Date; /** * Checkout ID. */ _id?: string; /** * Date and time the checkout was updated. */ _updatedDate?: Date; /** * Additional Fees */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Billing information. */ billingInfo?: Checkout.AddressWithContact; /** * Buyer information. */ buyerInfo?: Checkout.BuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * Errors when calculating totals. */ calculationErrors?: Checkout.CalculationErrors; /** * Cart ID that this checkout was created from. Empty if this checkout wasn't created out of a cart. */ cartId?: string; /** * Sales channel that submitted the order. "WIX_APP_STORE" refers to the Wix mobile app. */ channelType?: string; /** * Whether an order was successfully created from this checkout. * For an order to be successful, it must be successfully paid for (unless the total is 0). */ completed?: boolean; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * ID of the checkout's initiator. */ createdBy?: Checkout.CreatedBy; /** * Currency used for pricing in this store. */ currency?: string; /** * Custom fields. */ customFields?: Array; /** * Applied gift card details. */ giftCard?: Checkout.GiftCard; /** * Line items. */ lineItems?: Array; /** * Information about valid and invalid memberships, and which ones are selected for usage */ membershipOptions?: Checkout.MembershipOptions; /** * Remaining amount for the order to be fully paid. */ payLater?: Checkout.PriceSummary; /** * Minimal amount to pay in order to place the order. */ payNow?: Checkout.PriceSummary; /** * Calculated price summary for the checkout. */ priceSummary?: Checkout.PriceSummary; /** * Shipping information. */ shippingInfo?: Checkout.ShippingInfo; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrice?: boolean; /** * Tax summary. */ taxSummary?: Checkout.TaxSummary; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type CheckoutMarkedAsCompleted = { checkout?: Checkout.Checkout; }; type Color = { /** * Optional - HEX or RGB color code for display. */ code?: string; /** * Optional - Description line color name in site's default language. */ original?: string; /** * Optional - Translated description line color name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type CommonVatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; type Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: Checkout.MultiCurrencyPrice; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type CreateCheckoutOptions = { /** * Sales channel that submitted the order. Supported values: * + `"WEB"`, `"POS"`, `"EBAY"`, `"AMAZON"`, `"WIX_APP_STORE"`, `"WIX_INVOICES"`, `"BACKOFFICE_MERCHANT"`, `"WISH"`, `"OTHER_PLATFORM"`. */ channelType?: string; /** * Checkout information. */ checkoutInfo?: Checkout.Checkout; /** * The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items to be added to checkout. */ customLineItems?: Array; /** * Gift card code. */ giftCardCode?: string; /** * Line items to be added to checkout. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole checkout. */ merchantDiscounts?: Array; }; type CreateCheckoutRequest = { /** * Sales channel that submitted the order. Supported values: * + `"WEB"`, `"POS"`, `"EBAY"`, `"AMAZON"`, `"WIX_APP_STORE"`, `"WIX_INVOICES"`, `"BACKOFFICE_MERCHANT"`, `"WISH"`, `"OTHER_PLATFORM"`. */ channelType?: string; /** * Checkout information. */ checkoutInfo?: Checkout.Checkout; /** * The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items to be added to checkout. */ customLineItems?: Array; /** * Gift card code. */ giftCardCode?: string; /** * Line items to be added to checkout. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole checkout. */ merchantDiscounts?: Array; }; type CreateCheckoutResponse = { /** * Newly created checkout. */ checkout?: Checkout.Checkout; }; type CreateOrderAndChargeOptions = { /** * Payment token. */ paymentToken?: string; /** * Custom URL params to be added to redirect URLs. */ urlParams?: Record; }; type CreateOrderAndChargeRequest = { /** * Checkout ID. */ _id: string; /** * Payment token. */ paymentToken?: string; /** * Custom URL params to be added to redirect URLs. */ urlParams?: Record; }; type CreateOrderAndChargeResponse = { /** * ID of newly created order. */ orderId?: string; /** * The payment gateway is cashier. * payment_gateway_order_id will be returned given that money was charged. * In some cases, money will not be charged: * If the total price is 0 - For example, could be a free item or a an item with 100% discount * If the total price is not 0, but the payment is covered by alternative payment methods such as gift card */ paymentGatewayOrderId?: string; /** * Payment response token. */ paymentResponseToken?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type CreateOrderAndChargeResponseIdOneOf = { /** * ID of newly created order. */ orderId?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type CreateOrderOptions = { /** * Custom URL params to be added to redirect URLs. */ urlParams?: Record; }; type CreateOrderRequest = { /** * Checkout ID. */ _id: string; /** * Custom URL params to be added to redirect URLs. */ urlParams?: Record; }; type CreateOrderResponse = { /** * ID of newly created order (ecom order ID) */ orderId?: string; /** * The payment gateway is cashier. * payment_gateway_order_id will be returned given that money needs to be charged. * In some cases, money should not be charged: * If the total price is 0 - For example, could be a free item or a an item with 100% discount * If the total price is not 0, but the payment is covered by alternative payment methods such as gift card */ paymentGatewayOrderId?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type CreateOrderResponseIdOneOf = { /** * ID of newly created order (ecom order ID) */ orderId?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type CreatedBy = { /** * App ID - when the order was created by an external application or Wix service. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type CreatedByIdOneOf = { /** * App ID - when the order was created by an external application or Wix service. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type CustomField = { /** * Custom field title. */ title?: string; /** * Translated custom field title. */ translatedTitle?: string; /** * Custom field value. */ value?: any; }; type CustomLineItem = { /** * Custom line item ID. Defaults to an auto-generated ID. */ _id?: string; /** * Custom line item description lines. Used for displaying the cart, checkout and order. */ descriptionLines?: Array; /** * Custom line item media. * + Link to an image/video from the [Wix Media Manager](https://support.wix.com/en/article/wix-media-about-the-media-manager) - `"wix:image://v1/3c76e2_c53...4ea4~mv2.jpg#originWidth=1000&originHeight=1000"`. * + An image from the web - `"http(s)://"`. */ media?: string; /** * Custom line item name. */ name?: string; /** * Custom line item price. */ price?: string; /** * Custom line item quantity. */ quantity?: number; }; type CustomTextFieldSelection = { /** * Custom text field name */ title?: string; /** * Custom text field value */ value?: string; }; type DeliveryLogistics = { /** * Expected delivery time, in free text. For example, "3-5 business days". */ deliveryTime?: string; /** * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". */ instructions?: string; /** * Pickup details. */ pickupDetails?: Checkout.PickupDetails; }; type Description = { /** * Subscription option description. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type DescriptionLine = { /** * Description line color value. */ colorInfo?: Checkout.Color; /** * Description line name. */ name?: Checkout.DescriptionLineName; /** * Description line plain text value. */ plainText?: Checkout.PlainTextValue; }; type DescriptionLineDescriptionLineValueOneOf = {}; type DescriptionLineName = { /** * Optional - Description line name in site's default language. */ original?: string; /** * Optional - Translated description line item according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type DescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: Checkout.Color; /** * Description line plain text value. */ plainText?: Checkout.PlainTextValue; }; type Details = { applicationError?: Checkout.ApplicationError; /** * deprecated in API's - to enable migration from rendering arbitrary tracing to rest response */ tracing?: Record; validationError?: Checkout.ValidationError; }; type DetailsKindOneOf = { applicationError?: Checkout.ApplicationError; validationError?: Checkout.ValidationError; }; type Discount = { /** * Discount type. */ type?: string; /** * Discount value. */ value?: number; }; type DiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: Checkout.MultiCurrencyPrice; /** * Discount rule name */ name?: Checkout.DiscountRuleName; }; type DiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type DomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Checkout.ActionEvent; createdEvent?: Checkout.EntityCreatedEvent; deletedEvent?: Checkout.EntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Checkout.ExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Checkout.EntityUpdatedEvent; }; type DomainEventBodyOneOf = { actionEvent?: Checkout.ActionEvent; createdEvent?: Checkout.EntityCreatedEvent; deletedEvent?: Checkout.EntityDeletedEvent; extendedFieldsUpdatedEvent?: Checkout.ExtendedFieldsUpdatedEvent; updatedEvent?: Checkout.EntityUpdatedEvent; }; type Empty = {}; type EntityCreatedEvent = { entityAsJson?: string; }; type EntityDeletedEvent = {}; type EntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type ExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type FieldViolation = { data?: Object; description?: string; field?: string; /** * applicable when violated_rule=OTHER */ ruleName?: string; /** * Suppoerted values: * - `'DECIMAL_GT'` * - `'DECIMAL_GTE'` * - `'DECIMAL_LT'` * - `'DECIMAL_LTE'` * - `'DECIMAL_MAX_SCALE'` * - `'FORMAT'` * - `'INVALID_ENUM_VALUE'` * - `'MAX'` * - `'MAX_LENGTH'` * - `'MAX_SIZE'` * - `'MIN'` * - `'MIN_LENGTH'` * - `'MIN_SIZE'` * - `'OTHER'` * - `'REQUIRED_FIELD'` * - `'VALIDATION'` */ violatedRule?: string; }; type FullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: Checkout.CommonVatId; }; type FullName = { /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; }; type GetCheckoutRequest = { /** * Checkout ID. */ _id: string; }; type GetCheckoutResponse = { /** * The requested checkout. */ checkout?: Checkout.Checkout; }; type GetWixCheckoutURLRequest = { /** * Checkout ID. */ _id: string; }; type GetWixCheckoutURLResponse = { /** * Checkout URL. */ checkoutUrl?: string; }; type GetWixCheckoutUrlOptions = {}; type GiftCard = { /** * Gift Card ID. */ _id?: string; /** * Gift card value. */ amount?: Checkout.MultiCurrencyPrice; /** * App ID of the gift card provider. */ appId?: string; /** * Gift card obfuscated code. */ obfuscatedCode?: string; }; type Group = { /** * Item ID (when the coupon scope is limited to just one item). */ entityId?: string; /** * Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */ name?: string; }; type InvalidMembership = { /** * Membership details. */ membership?: Checkout.Membership; /** * Reason why this membership is invalid and cannot be used. */ reason?: string; }; type ItemAvailabilityInfo = { /** * Quantity available. */ quantityAvailable?: number; /** * Item availability status. Supported Values: * + `"NOT_FOUND"`: Item does not exist * + `"NOT_AVAILABLE"`: Item not in stock * + `"PARTIALLY_AVAILABLE"`: Available quantity is less than requested */ status?: string; }; type ItemTaxFullDetails = { /** * If breakdown exists, the sum of rates in the breakdown must equal `tax_rate`. */ rateBreakdown?: Array; /** * Tax rate %, as a decimal point between 0 and 1. */ taxRate?: string; /** * Amount for which tax is calculated. */ taxableAmount?: Checkout.MultiCurrencyPrice; /** * Calculated tax, based on `taxable_amount` and `tax_rate`. */ totalTax?: Checkout.MultiCurrencyPrice; }; type ItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type LineItem = { /** * Line item ID. */ _id?: string; /** * Item availability details. */ availability?: Checkout.ItemAvailabilityInfo; /** * Catalog and item reference. Holds IDs for the item and the catalog it came from, as well as further optional info. */ catalogReference?: Checkout.CatalogReference; /** * Partial payment for the given item to be paid upfront during the checkout. Eligible for catalog items with type `DEPOSIT_ONLINE` only. */ depositAmount?: Checkout.MultiCurrencyPrice; /** * Line item description lines. Used for displaying the cart, checkout and order. */ descriptionLines?: Array; /** * Discount for this line item's entire quantity. */ discount?: Checkout.MultiCurrencyPrice; /** * Item price **before** catalog-defined discount. Defaults to `price` when not provided. */ fullPrice?: Checkout.MultiCurrencyPrice; /** * Item type. Either a preset type or custom. */ itemType?: Checkout.ItemType; /** * Total price **after** catalog-defined discount and line item discounts. */ lineItemPrice?: Checkout.MultiCurrencyPrice; /** * Line item image details. */ media?: string; /** * Type of selected payment option for current item. Defaults to `"FULL_PAYMENT_ONLINE"`. * + `"FULL_PAYMENT_ONLINE"`: The entire payment for this item happens as part of the checkout. * + `"FULL_PAYMENT_OFFLINE"`: The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `"MEMBERSHIP"`: Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0. * + `"DEPOSIT_ONLINE"`: Partial payment for the given item to be paid upfront during the checkout. Amount to be paid is defined by deposit_amount field. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. */ physicalProperties?: Checkout.PhysicalProperties; /** * Item price **after** catalog-defined discount and line item discounts. */ price?: Checkout.MultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Checkout.MultiCurrencyPrice; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: Checkout.PriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: Checkout.ProductName; /** * Item quantity. */ quantity?: number; /** * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID. * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID. * + In most cases, this field has the same value as `catalogReference.catalogItemId`. * + Used in membership validation. */ rootCatalogItemId?: string; /** * Service properties. When relevant, this contains information such as date and number of participants. */ serviceProperties?: Checkout.ServiceProperties; /** * Tax details for this line item. */ taxDetails?: Checkout.ItemTaxFullDetails; /** * Total price after all discounts and tax. */ totalPriceAfterTax?: Checkout.MultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Checkout.MultiCurrencyPrice; /** * URL to the item's page on the site. */ url?: string; }; type MarkCheckoutAsCompletedRequest = { /** * Checkout ID. */ _id: string; }; type MarkCheckoutAsCompletedResponse = {}; type MediaItem = { /** * Media ID (for media items previously saved in Wix Media) */ _id?: string; /** * Alternative text for presentation when media cannot be displayed */ altText?: string; /** * Media external URL */ externalImageUrl?: string; /** * Media item height */ height?: number; /** * Media type */ mediaType?: string; /** * Media URL */ url?: string; /** * Media item width */ width?: number; }; type Membership = { /** * Membership ID. */ _id?: string; /** * Additional data about this membership. */ additionalData?: Object; /** * ID of the application providing this payment option. */ appId?: string; /** * Optional - For a membership that has limited credits, information about credit usage. */ credits?: Checkout.MembershipPaymentCredits; /** * Optional - TMembership expiry date. */ expirationDate?: Date; /** * Line item IDs which are "paid for" by this membership. */ lineItemIds?: Array; /** * The name of this membership. */ name?: Checkout.MembershipName; }; type MembershipName = { /** * The name of this membership */ original?: string; /** * Optional - Translated name of this membership. Defaults to `original` when not provided. */ translated?: string; }; type MembershipOptions = { /** * List of payment options that can be used */ eligibleMemberships?: Array; /** * List of payment options that are owned by the member, but cannot be used due to reason provided */ invalidMemberships?: Array; /** * The selected payment options and which line items they apply to */ selectedMemberships?: Checkout.SelectedMemberships; }; type MembershipPaymentCredits = { /** * How much credit remained for this membership */ remaining?: number; /** * How much credit this membership has in total */ total?: number; }; type MerchantDiscount = { /** * Discount value. */ amount?: Checkout.MultiCurrencyPrice; }; type MerchantDiscountInput = { /** * Discount amount. */ amount?: string; /** * IDs of the line items the discount applies to. */ lineItemIds?: Array; }; type MultiCurrencyPrice = { /** * Amount. */ amount?: string; /** * Converted amount. */ convertedAmount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; /** * Converted amount formatted with currency symbol. */ formattedConvertedAmount?: string; }; type OptionSelection = { /** * Option name */ option?: string; /** * Selected choice for this option */ selection?: string; }; type OrderCreated = { /** * Order archive status */ archived?: boolean; /** * Customer information */ buyerInfo?: Checkout.V2BuyerInfo; /** * Currency used for pricing in this store */ currency?: string; /** * Order creation date */ dateCreated?: Date; /** * Order fulfillment status */ fulfillmentStatus?: string; /** * ID displayed in the owner's store (auto generated) */ number?: string; /** * Order ID (auto generated upon order creation) */ orderId?: string; /** * Order payment status */ paymentStatus?: string; /** * Whether the order was read by the store owner */ read?: boolean; /** * Totals for order's line items */ totals?: Checkout.Totals; /** * Weight measurement unit used in this store. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type OrdersExperiments = { epCommitTax?: boolean; moveBuyerOrderConfirmationEmailToEp?: boolean; moveMerchantEmailToEp?: boolean; producedByEpBridge?: boolean; }; type OtherCharge = { /** * Price of added cost. */ price?: Checkout.MultiCurrencyPrice; /** * Type of additional cost. */ type?: string; }; type PhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit (`"KG"` or `"LB"`) is taken from `order.weightUnit`. */ weight?: number; }; type PickupAddress = { /** * Address */ addressLine?: string; /** * City */ city?: string; /** * Country code (2 letters) */ country?: string; /** * State/District */ subdivision?: string; /** * ZIP/postal code */ zipCode?: string; }; type PickupDetails = { /** * Pickup address. */ address?: Checkout.ApiAddress; /** * Whether the pickup address is that of a business - this may effect tax calculation. */ businessLocation?: boolean; /** * Pickup method */ pickupMethod?: string; }; type PlainTextValue = { /** * Optional - Description line plain text value in site's default language. */ original?: string; /** * Optional - Translated description line plain text value according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type PriceDescription = { /** * Required** - Original price description (in site's default language). */ original?: string; /** * Optional - Translated product name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type PriceSummary = { /** * Total additional fees price. */ additionalFees?: Checkout.MultiCurrencyPrice; /** * Total calculated discount value. */ discount?: Checkout.MultiCurrencyPrice; /** * Total shipping price, before discounts and before tax. */ shipping?: Checkout.MultiCurrencyPrice; /** * Subtotal of all line items, before discounts and before tax. */ subtotal?: Checkout.MultiCurrencyPrice; /** * Total tax. */ tax?: Checkout.MultiCurrencyPrice; /** * Total price after discounts, gift cards, and tax. */ total?: Checkout.MultiCurrencyPrice; }; type ProductDetails = { /** * Line item fulfillerId from stores fulfillers. No value means self fulfilled */ fulfillerId?: string; /** * Line item type (may be extended) */ lineItemType?: string; /** * Line item primary media for preview */ mediaItem?: Checkout.MediaItem; /** * Line item name */ name?: string; /** * Line item notes */ notes?: string; /** * Line item product ID (optional for POS orders) */ productId?: string; /** * Line item SKU */ sku?: string; /** * Tax group id */ taxGroupId?: string; /** * Line item name translated to buyer's language */ translatedName?: string; /** * Line item weight */ weight?: number; }; type ProductName = { /** * Required** - Original item name (in site's default language). */ original?: string; /** * Optional - Translated item name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type RemoveCouponRequest = { /** * Checkout ID. */ _id: string; }; type RemoveCouponResponse = { /** * Updated checkout after removal of coupon. */ checkout?: Checkout.Checkout; }; type RemoveGiftCardRequest = { /** * Checkout ID. */ _id: string; }; type RemoveGiftCardResponse = { /** * Updated checkout after removal of gift card. */ checkout?: Checkout.Checkout; }; type RemoveLineItemsRequest = { /** * Checkout ID. */ _id: string; /** * IDs of the line items to be removed. */ lineItemIds: Array; }; type RemoveLineItemsResponse = { /** * Updated checkout after removal of line items. */ checkout?: Checkout.Checkout; }; type Scope = { /** * Coupon scope's applied group (e.g., event or ticket in Wix Events) */ group?: Checkout.Group; /** * Scope namespace (Wix Stores, Wix Bookings, Wix Events) */ namespace?: string; }; type SecuredMedia = { /** * Media ID in media manager. */ _id?: string; /** * Original file name. */ fileName?: string; /** * File type. */ fileType?: string; }; type SelectedCarrierServiceOption = { /** * This carrier's unique ID */ carrierId?: string; /** * Unique identifier of selected option. For example, "usps_std_overnight". */ code?: string; /** * Shipping costs. */ cost?: Checkout.SelectedCarrierServiceOptionPrices; /** * Delivery logistics. */ logistics?: Checkout.DeliveryLogistics; /** * Other charges */ otherCharges?: Array; /** * Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) */ requestedShippingOption?: boolean; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type SelectedCarrierServiceOptionOtherCharge = { /** * Price of added charge. */ cost?: Checkout.SelectedCarrierServiceOptionPrices; /** * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'. */ details?: string; /** * Type of additional cost. */ type?: string; }; type SelectedCarrierServiceOptionPrices = { /** * Shipping price before discount and before tax. */ price?: Checkout.MultiCurrencyPrice; /** * Tax details. */ taxDetails?: Checkout.ItemTaxFullDetails; /** * Shipping discount before tax. */ totalDiscount?: Checkout.MultiCurrencyPrice; /** * Total shipping price, after discount and after tax. */ totalPriceAfterTax?: Checkout.MultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Checkout.MultiCurrencyPrice; }; type SelectedMembership = { /** * Membership ID. */ _id?: string; /** * ID of the app providing this payment option. */ appId?: string; /** * IDs of the line items this membership applies to. */ lineItemIds?: Array; }; type SelectedMemberships = { /** * Selected memberships. */ memberships?: Array; }; type ServiceProperties = { /** * Optional - The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room. */ numberOfParticipants?: number; /** * Optional - The date and time for which the service is supposed to be provided. For example, the time of the class. */ scheduledDate?: Date; }; type ShipmentDetails = { /** * Shipping destination address */ address?: Checkout.Address; /** * Discount applied for shipping */ discount?: number; /** * Tax applied for shipping */ tax?: number; /** * Whether tax is included in the price */ taxIncludedInPrice?: boolean; }; type ShippingInfo = { /** * All carrier options for this shipping rule. */ carrierServiceOptions?: Array; /** * Shipping region. */ region?: Checkout.ShippingRegion; /** * Selected option out of the options allowed for the region (see `region` field). * The region field is chosen based on the address provided. */ selectedCarrierServiceOption?: Checkout.SelectedCarrierServiceOption; /** * Shipping address and contact details. */ shippingDestination?: Checkout.AddressWithContact; }; type ShippingOption = { /** * Unique code of provided shipping option like "usps_std_overnight". * For legacy calculators this would be the UUID of the option. */ code?: string; /** * Sipping price information. */ cost?: Checkout.ShippingPrice; /** * Delivery logistics. */ logistics?: Checkout.DeliveryLogistics; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ShippingPrice = { /** * Other costs such as insurance, handling & packaging for fragile items, etc. */ otherCharges?: Array; /** * Shipping price. */ price?: Checkout.MultiCurrencyPrice; }; type ShippingRegion = { /** * Shipping region ID. */ _id?: string; /** * Shipping region name. */ name?: string; }; type StoreSettings = { /** * The language to be used when communicating with the buyer * For a site that support multiple languages, this would be the language the buyer selected * Otherwise this would be the site language */ buyerLanguage?: string; /** * Currency used for pricing in this store */ currency?: string; /** * Weight measurement unit used in this store. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type Street = { /** * Street name */ name?: string; /** * Street number */ number?: string; }; type StreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type Subscription = { /** * Subscription id (auto-generated upon subscription creation) */ _id?: string; /** * Coupon that was applied to subscription */ appliedCoupon?: Checkout.V1AppliedCoupon; /** * Full billing address */ billingAddress?: Checkout.Address; /** * information about first subscription payment */ billingInfo?: Checkout.V1BillingInfo; /** * member or contact */ buyerInfo?: Checkout.V1BuyerInfo; /** * Message from the customer (e.g., customization request) */ buyerNote?: string; /** * The id of the cart this order was created from */ cartId?: string; /** * Sales channel that submitted this subscription */ channelInfo?: Checkout.ChannelInfo; /** * The id of the checkout this subscriptions was created from */ checkoutId?: string; /** * Custom field */ customField?: Checkout.V1CustomField; /** * Subscription creation date */ dateCreated?: Date; /** * id of subscription in external system */ externalId?: string; /** * Line items ordered */ lineItems?: Array; /** * Delivery information */ shippingInfo?: Checkout.V1ShippingInfo; /** * site settings at the moment when subscription created */ storeSettings?: Checkout.StoreSettings; /** * Information about subscription option from which subscription was created */ subscriptionOptionInfo?: Checkout.V1SubscriptionOptionInfo; /** * defines when subscriber will be charged: for frequency=MONTH, billingCycles=6, interval=2 payment will be done every 2 month during one year */ subscriptionSettings?: Checkout.V1SubscriptionSettings; /** * Totals for subscription's line items */ totals?: Checkout.V1Totals; }; type SubscriptionCreated = { subscription?: Checkout.Subscription; }; type SubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Current cycle number. For example, if the subscription is in the 3rd month of a 4-month subscription, the value will be `3`. */ cycleNumber?: number; /** * Subscription options info. */ subscriptionOptionInfo?: Checkout.V2SubscriptionOptionInfo; /** * Subscription settings. */ subscriptionSettings?: Checkout.V1SubscriptionSettings; }; type SubscriptionOptionInfo = { /** * Subscription option description. */ description?: Checkout.Description; /** * Subscription option settings. */ subscriptionSettings?: Checkout.SubscriptionSettings; /** * Subscription option title. */ title?: Checkout.Title; }; type SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type TaxCalculationDetails = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Checkout.AutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; /** * Rate calculation type. */ rateType?: string; }; type TaxCalculationDetailsCalculationDetailsOneOf = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Checkout.AutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; }; type TaxRateBreakdown = { /** * Type of tax against which the calculation was performed. */ name?: string; /** * Rate at which this tax detail was calculated. */ rate?: string; /** * Amount of tax for this tax detail. */ tax?: Checkout.MultiCurrencyPrice; }; type TaxSummary = { /** * Tax calculator that was active when the order was created. */ calculationDetails?: Checkout.TaxCalculationDetails; /** * Amount for which tax is calculated, added from line items. */ taxableAmount?: Checkout.MultiCurrencyPrice; /** * Calculated tax, added from line items. */ totalTax?: Checkout.MultiCurrencyPrice; }; type Title = { /** * Subscription option name. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type Totals = { /** * Total calculated discount value. */ discount?: string; /** * Total calculated gift card value. */ giftCard?: string; /** * Total number of line items. */ quantity?: number; /** * Total refund. */ refund?: string; /** * Total shipping price, before tax. */ shipping?: string; /** * Subtotal of all the line items, before tax. */ subtotal?: string; /** * Total tax. */ tax?: string; /** * Total price charged. */ total?: string; /** * Total items weight. */ weight?: string; }; type UpdateCheckout = { /** * Date and time the checkout was created. */ _createdDate?: Date; /** * Checkout ID. */ _id?: string; /** * Date and time the checkout was updated. */ _updatedDate?: Date; /** * Additional Fees */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Billing information. */ billingInfo?: Checkout.AddressWithContact; /** * Buyer information. */ buyerInfo?: Checkout.BuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * Errors when calculating totals. */ calculationErrors?: Checkout.CalculationErrors; /** * Cart ID that this checkout was created from. Empty if this checkout wasn't created out of a cart. */ cartId?: string; /** * Sales channel that submitted the order. "WIX_APP_STORE" refers to the Wix mobile app. */ channelType?: string; /** * Whether an order was successfully created from this checkout. * For an order to be successful, it must be successfully paid for (unless the total is 0). */ completed?: boolean; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * ID of the checkout's initiator. */ createdBy?: Checkout.CreatedBy; /** * Currency used for pricing in this store. */ currency?: string; /** * Custom fields. */ customFields?: Array; /** * Applied gift card details. */ giftCard?: Checkout.GiftCard; /** * Line items. */ lineItems?: Array; /** * Information about valid and invalid memberships, and which ones are selected for usage */ membershipOptions?: Checkout.MembershipOptions; /** * Remaining amount for the order to be fully paid. */ payLater?: Checkout.PriceSummary; /** * Minimal amount to pay in order to place the order. */ payNow?: Checkout.PriceSummary; /** * Calculated price summary for the checkout. */ priceSummary?: Checkout.PriceSummary; /** * Shipping information. */ shippingInfo?: Checkout.ShippingInfo; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrice?: boolean; /** * Tax summary. */ taxSummary?: Checkout.TaxSummary; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type UpdateCheckoutOptions = { /** * The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Gift card code. */ giftCardCode?: string; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole checkout. */ merchantDiscounts?: Array; }; type UpdateCheckoutRequest = { /** * Checkout information. */ checkout: Checkout.Checkout; /** * The code of an existing coupon to apply to checkout. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Gift card code. */ giftCardCode?: string; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole checkout. */ merchantDiscounts?: Array; }; type UpdateCheckoutResponse = { /** * Updated checkout. */ checkout?: Checkout.Checkout; }; type UpdatedCheckoutMessage = { /** * Previous checkout. */ oldCheckout?: Checkout.Checkout; /** * Updated checkout. */ updatedCheckout?: Checkout.Checkout; }; type V1AppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type V1BillingInfo = { /** * Order ID from payment gateway (e.g., Wix Payments) */ paymentGatewayOrderId?: string; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; }; type V1BuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer type */ identityType?: string; }; type V1CustomField = { /** * Title for the custom field */ title?: string; /** * The title translated according to the buyer language */ translatedTitle?: string; /** * Free text that the customer entered in the custom field during the checkout process */ value?: string; }; type V1LineItem = { /** * Charges details */ chargeDetails?: Checkout.ChargeDetails; /** * Line item custom text field selections */ customTextFields?: Array; /** * Line item ID (auto-generated) */ index?: number; /** * Line item options ordered */ options?: Array; /** * Product details */ productDetails?: Checkout.ProductDetails; /** * Line item quantity */ quantity?: number; /** * Line item variantId (from Stores Catalog) */ variantId?: string; }; type V1PickupDetails = { /** * Pickup address */ address?: Checkout.PickupAddress; /** * Store owner's pickup instructions */ pickupInstructions?: string; }; type V1ShippingInfo = { /** * Delivery option name */ deliveryOption?: string; /** * Delivery option delivery time */ estimatedDeliveryTime?: string; /** * Pickup details (when this object describes pickup) */ pickupDetails?: Checkout.V1PickupDetails; /** * Shipment details (when this object describes shipment) */ shipmentDetails?: Checkout.ShipmentDetails; }; type V1ShippingInfoDetailsOneOf = { /** * Pickup details (when this object describes pickup) */ pickupDetails?: Checkout.V1PickupDetails; /** * Shipment details (when this object describes shipment) */ shipmentDetails?: Checkout.ShipmentDetails; }; type V1SubscriptionOptionInfo = { _id?: string; description?: string; discount?: Checkout.Discount; title?: string; }; type V1SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type V1Totals = { /** * Total calculated discount value */ discount?: number; /** * Total line items quantity */ quantity?: number; /** * Total shipping price, including tax */ shipping?: number; /** * Subtotal of all line items, before tax */ subtotal?: number; /** * Total tax */ tax?: number; /** * Total price */ total?: number; /** * Total weight */ weight?: number; }; type V2BuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer type */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; /** * Deprecated (use identityType instead) */ type?: string; }; type V2SubscriptionOptionInfo = { /** * Subscription option description. */ description?: string; /** * Subscription option title. */ title?: string; }; type ValidationError = { fieldViolations?: Array; }; type VatId = { /** * Customer's tax ID */ number?: string; /** * tax type */ type?: string; }; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.CurrentCart.html#) */ namespace CurrentCart { type ActionEvent = { bodyAsJson?: string; }; type AddToCartRequest = { /** * Cart ID. */ _id: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type AddToCartResponse = { /** * Updated cart. */ cart?: CurrentCart.Cart; }; type AddToCurrentCartOptions = { /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type AddToCurrentCartRequest = { /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type AdditionalFee = { /** * Additional fee's unique code (or ID) for future processing */ code?: string; /** * Translated additional fee's name */ name?: string; /** * Additional fee's price */ price?: CurrentCart.MultiCurrencyPrice; /** * Provider's app id */ providerAppId?: string; /** * Tax details */ taxDetails?: CurrentCart.ItemTaxFullDetails; }; type Address = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: CurrentCart.StreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type AddressLocation = { /** * Address latitude. */ latitude?: number; /** * Address longitude. */ longitude?: number; }; type AddressWithContact = { /** * Address. */ address?: CurrentCart.Address; /** * Contact details. */ contactDetails?: CurrentCart.ApiFullAddressContactDetails; }; type ApiFullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: CurrentCart.VatId; }; type ApplicationError = { code?: string; data?: Object; description?: string; }; type AppliedCoupon = { /** * Coupon code */ code?: string; /** * Converted discount value */ convertedDiscountValue?: string; /** * Coupon internal ID */ couponId?: string; /** * Type (e.g., moneyOff, percentOff) */ couponType?: string; /** * Discount value */ discountValue?: string; /** * Coupon name */ name?: string; }; type AppliedDiscount = { /** * Coupon details. */ coupon?: CurrentCart.V1Coupon; /** * Discount rule */ discountRule?: CurrentCart.DiscountRule; /** * Discount type. */ discountType?: string; /** * IDs of the line items the discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: CurrentCart.V1MerchantDiscount; }; type AppliedDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: CurrentCart.V1Coupon; /** * Discount rule */ discountRule?: CurrentCart.DiscountRule; /** * Merchant discount. */ merchantDiscount?: CurrentCart.V1MerchantDiscount; }; type AutoTaxFallbackCalculationDetails = { /** * invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */ error?: CurrentCart.ApplicationError; /** * Reason for fallback. Supported values: * + `"AUTO_TAX_FAILED"` * + `"AUTO_TAX_DEACTIVATED"` */ fallbackReason?: string; }; type BuyerDetails = { /** * Email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; /** * Phone number */ phone?: string; }; type BuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see the [Contacts API](https://www.wix.com/velo/reference/wix-crm-backend/contacts/introduction). */ contactId?: string; /** * Member ID - if the buyer is a site member. */ memberId?: string; /** * User ID - if the cart owner is a Wix user. */ userId?: string; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type BuyerInfoIdOneOf = { /** * Member ID - if the buyer is a site member. */ memberId?: string; /** * User ID - if the cart owner is a Wix user. */ userId?: string; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type CalculatedLineItem = { /** * Line item ID. */ lineItemId?: string; /** * Type of selected payment option for current item. Defaults to `"FULL_PAYMENT_ONLINE"`. * + `"FULL_PAYMENT_ONLINE"` - The entire payment for this item happens as part of the checkout. * + `"FULL_PAYMENT_OFFLINE"` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `"MEMBERSHIP"` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` will be 0. */ paymentOption?: string; /** * Price breakdown for this line item. */ pricesBreakdown?: CurrentCart.LineItemPricesData; }; type CalculationErrors = { /** * Carrier errors. */ carrierErrors?: CurrentCart.CarrierErrors; /** * Coupon calculation error. */ couponCalculationError?: CurrentCart.Details; /** * Discount Rule calculation error. */ discountsCalculationError?: CurrentCart.Details; /** * General shipping calculation error. */ generalShippingCalculationError?: CurrentCart.Details; /** * Gift card calculation error. */ giftCardCalculationError?: CurrentCart.Details; /** * Membership payment methods calculation errors * For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid */ membershipError?: CurrentCart.Details; /** * Order validation errors. */ orderValidationErrors?: Array; /** * Tax calculation error. */ taxCalculationError?: CurrentCart.Details; }; type CalculationErrorsShippingCalculationErrorOneOf = { /** * Carrier errors. */ carrierErrors?: CurrentCart.CarrierErrors; /** * General shipping calculation error. */ generalShippingCalculationError?: CurrentCart.Details; }; type CarrierError = { /** * Carrier ID. */ carrierId?: string; /** * Error details. */ error?: CurrentCart.Details; }; type CarrierErrors = { /** * Carrier errors. */ errors?: Array; }; type CarrierServiceOption = { /** * Carrier ID. */ carrierId?: string; /** * Shipping options offered by this carrier for this request. */ shippingOptions?: Array; }; type Cart = { /** * Date and time the cart was created. */ _createdDate?: Date; /** * Cart ID. */ _id?: string; /** * Date and time the cart was updated. */ _updatedDate?: Date; /** * Cart discounts. */ appliedDiscounts?: Array; /** * Buyer information. */ buyerInfo?: CurrentCart.BuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * ID of the checkout related to this cart. */ checkoutId?: string; /** * Contact info. */ contactInfo?: CurrentCart.AddressWithContact; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * Currency used for pricing. */ currency?: string; /** * Line items. */ lineItems?: Array; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrices?: boolean; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type CartAddress = { /** * Address */ address?: CurrentCart.CommonAddress; /** * Contact details */ contactDetails?: CurrentCart.FullAddressContactDetails; }; type CartCompletedEvent = { /** * Coupon applied to this cart */ appliedCoupon?: CurrentCart.AppliedCoupon; /** * Customer's billing address */ billingAddress?: CurrentCart.CartAddress; /** * Customer's Wix ID */ buyerInfo?: CurrentCart.V1BuyerInfo; /** * Message from the customer */ buyerNote?: string; cartId?: string; /** * Time the cart was created */ completedTime?: Date; /** * Currency used for pricing in this store */ currency?: CurrentCart.Currency; /** * Cart shipping information */ shippingInfo?: CurrentCart.ShippingInfo; /** * Totals for order's line items */ totals?: CurrentCart.Totals; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type CartDiscount = { /** * Coupon details. */ coupon?: CurrentCart.Coupon; /** * Merchant discount. */ merchantDiscount?: CurrentCart.MerchantDiscount; }; type CartDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: CurrentCart.Coupon; /** * Merchant discount. */ merchantDiscount?: CurrentCart.MerchantDiscount; }; type CatalogReference = { /** * App ID of the catalog the item comes from. For example, the Wix Stores `appId` is `"1380b703-ce81-ff05-f115-39571d94dfcd"`. */ appId?: string; /** * ID of the item within its catalog. For example, `productId` for Wix Stores. */ catalogItemId?: string; /** * Additional info in key:value form. For example, for a product variant from Wix Stores Catalog, `options` field would hold something like one of the following: * + `{"Size": "M", "Color": "Red"}` * + `{"variantId": ""}`. */ options?: Object; }; type Color = { /** * HEX or RGB color code for display. */ code?: string; /** * Description line color name in site's default language. */ original?: string; /** * Description line color name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type CommonAddress = { /** * Main address line, usually street and number as free text. */ addressLine?: string; /** * Main address line, usually street and number as free text. */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains Apt, Suite, and Floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Country code. */ country?: string; /** * Zip/postal code. */ postalCode?: string; /** * Street name and number. */ streetAddress?: CurrentCart.StreetAddress; /** * Subdivision. Usually a state, region, prefecture, or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */ subdivision?: string; }; type CommonAddressStreetOneOf = { /** * Main address line, usually street and number as free text. */ addressLine?: string; /** * Street name and number. */ streetAddress?: CurrentCart.StreetAddress; }; type Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon code. */ code?: string; }; type CreateCartRequest = { /** * Cart info. */ cartInfo?: CurrentCart.Cart; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will apply to the whole cart. */ merchantDiscounts?: Array; }; type CreateCartResponse = { /** * Cart. */ cart?: CurrentCart.Cart; }; type CreateCheckoutFromCurrentCartOptions = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: CurrentCart.Address; /** * Sales channel type. Supported values: * + `"AMAZON"` * + `"BACKOFFICE_MERCHANT"` * + `"EBAY"` * + `"OTHER_PLATFORM"` * + `"POS"` * + `"WEB"` * + `"WISH"` * + `"WIX_APP_STORE"` * + `"WIX_INVOICES"` */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: CurrentCart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: CurrentCart.Address; }; type CreateCheckoutFromCurrentCartRequest = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: CurrentCart.Address; /** * Sales channel type. Supported values: * + `"AMAZON"` * + `"BACKOFFICE_MERCHANT"` * + `"EBAY"` * + `"OTHER_PLATFORM"` * + `"POS"` * + `"WEB"` * + `"WISH"` * + `"WIX_APP_STORE"` * + `"WIX_INVOICES"` */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: CurrentCart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: CurrentCart.Address; }; type CreateCheckoutRequest = { /** * Cart ID. */ _id: string; /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: CurrentCart.Address; /** * Sales channel type. Supported values: * + `"AMAZON"` * + `"BACKOFFICE_MERCHANT"` * + `"EBAY"` * + `"OTHER_PLATFORM"` * + `"POS"` * + `"WEB"` * + `"WISH"` * + `"WIX_APP_STORE"` * + `"WIX_INVOICES"` */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: CurrentCart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: CurrentCart.Address; }; type CreateCheckoutResponse = { /** * The newly created checkout's ID. */ checkoutId?: string; }; type Currency = { /** * Currency code */ code?: string; /** * Currency symbol */ symbol?: string; }; type CustomLineItem = { /** * Custom line item ID. Defaults to an auto-generated ID. */ _id?: string; /** * Custom line item description lines. Used for displaying the cart, checkout and order. */ descriptionLines?: Array; /** * Custom line item media. Supported formats: * + Link to an image/video from the [Wix Media Manager](https://support.wix.com/en/article/wix-media-about-the-media-manager) - `"wix:image://v1/3c76e2_c53...4ea4~mv2.jpg#originWidth=1000&originHeight=1000"`. * + An image from the web - `"http(s)://"`. */ media?: string; /** * Custom line item name. */ name?: string; /** * Custom line item price. */ price?: string; /** * Custom line item quantity. */ quantity?: number; }; type DeleteCartRequest = { /** * ID of the cart to delete. */ _id: string; }; type DeleteCartResponse = {}; type DeleteCurrentCartRequest = {}; type DeliveryLogistics = { /** * Expected delivery time, in free text. For example, "3-5 business days". */ deliveryTime?: string; /** * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". */ instructions?: string; /** * Pickup details. */ pickupDetails?: CurrentCart.PickupDetails; }; type Description = { /** * Subscription option description. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type DescriptionLine = { /** * Description line color value. */ colorInfo?: CurrentCart.Color; /** * Description line name. */ name?: CurrentCart.DescriptionLineName; /** * Description line plain text value. */ plainText?: CurrentCart.PlainTextValue; }; type DescriptionLineDescriptionLineValueOneOf = {}; type DescriptionLineName = { /** * Description line name in site's default language. */ original?: string; /** * Description line name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type DescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: CurrentCart.Color; /** * Description line plain text value. */ plainText?: CurrentCart.PlainTextValue; }; type Details = { applicationError?: CurrentCart.ApplicationError; /** * Deprecated in APIs. Used to enable migration from rendering arbitrary tracing to rest response. */ tracing?: Record; validationError?: CurrentCart.ValidationError; }; type DetailsKindOneOf = { applicationError?: CurrentCart.ApplicationError; validationError?: CurrentCart.ValidationError; }; type DiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: CurrentCart.MultiCurrencyPrice; /** * Discount rule name */ name?: CurrentCart.DiscountRuleName; }; type DiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Discount rule name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type DomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: CurrentCart.ActionEvent; createdEvent?: CurrentCart.EntityCreatedEvent; deletedEvent?: CurrentCart.EntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: CurrentCart.ExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: CurrentCart.EntityUpdatedEvent; }; type DomainEventBodyOneOf = { actionEvent?: CurrentCart.ActionEvent; createdEvent?: CurrentCart.EntityCreatedEvent; deletedEvent?: CurrentCart.EntityDeletedEvent; extendedFieldsUpdatedEvent?: CurrentCart.ExtendedFieldsUpdatedEvent; updatedEvent?: CurrentCart.EntityUpdatedEvent; }; type Empty = {}; type EntityCreatedEvent = { entityAsJson?: string; }; type EntityDeletedEvent = {}; type EntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type EstimateCurrentCartTotalsOptions = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: CurrentCart.Address; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: CurrentCart.SelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: CurrentCart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: CurrentCart.Address; }; type EstimateCurrentCartTotalsRequest = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: CurrentCart.Address; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: CurrentCart.SelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: CurrentCart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: CurrentCart.Address; }; type EstimateTotalsRequest = { /** * Cart ID. */ _id: string; /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: CurrentCart.Address; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: CurrentCart.SelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: CurrentCart.SelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: CurrentCart.Address; }; type EstimateTotalsResponse = { /** * Additional fees */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Calculated line items. */ calculatedLineItems?: Array; /** * Calculation errors. */ calculationErrors?: CurrentCart.CalculationErrors; /** * Cart. */ cart?: CurrentCart.Cart; /** * Currency used for pricing in this store. */ currency?: string; /** * Applied gift card. */ giftCard?: CurrentCart.GiftCard; /** * Information about valid and invalid memberships, and which ones are selected for usage. */ membershipOptions?: CurrentCart.MembershipOptions; /** * Remaining amount for the order to be fully paid. */ payLater?: CurrentCart.PriceSummary; /** * Minimal amount to pay in order to place the order. */ payNow?: CurrentCart.PriceSummary; /** * Price summary. */ priceSummary?: CurrentCart.PriceSummary; /** * Shipping information. */ shippingInfo?: CurrentCart.ShippingInformation; /** * Tax summary. */ taxSummary?: CurrentCart.TaxSummary; /** * Weight measurement unit - defaults to site's weight unit. Supported values: * + `"KG"` * + `"LB"` */ weightUnit?: string; }; type ExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type FieldViolation = { data?: Object; description?: string; field?: string; /** * applicable when violated_rule=OTHER */ ruleName?: string; /** * Suppoerted values: * - `'DECIMAL_GT'` * - `'DECIMAL_GTE'` * - `'DECIMAL_LT'` * - `'DECIMAL_LTE'` * - `'DECIMAL_MAX_SCALE'` * - `'FORMAT'` * - `'INVALID_ENUM_VALUE'` * - `'MAX'` * - `'MAX_LENGTH'` * - `'MAX_SIZE'` * - `'MIN'` * - `'MIN_LENGTH'` * - `'MIN_SIZE'` * - `'OTHER'` * - `'REQUIRED_FIELD'` * - `'VALIDATION'` */ violatedRule?: string; }; type FullAddressContactDetails = { /** * Contact's company */ company?: string; /** * Email associated with the address */ email?: string; /** * Contact first name */ firstName?: string; /** * Contact last name */ lastName?: string; /** * Contact phone number */ phone?: string; /** * tax info (Currently usable only in Brazil) */ vatId?: CurrentCart.VatId; }; type GetCartByCheckoutIdRequest = { /** * Checkout ID. */ _id: string; }; type GetCartByCheckoutIdResponse = { /** * The requested cart. */ cart?: CurrentCart.Cart; }; type GetCartRequest = { /** * ID of the cart to retrieve. */ _id: string; }; type GetCartResponse = { /** * The requested cart. */ cart?: CurrentCart.Cart; }; type GetCurrentCartRequest = {}; type GetCurrentCartResponse = { /** * Current session's active cart. */ cart?: CurrentCart.Cart; }; type GiftCard = { /** * Gift Card ID. */ _id?: string; /** * Gift card value. */ amount?: CurrentCart.MultiCurrencyPrice; /** * App ID of the gift card provider. */ appId?: string; /** * Gift card obfuscated code. */ obfuscatedCode?: string; }; type Group = { /** * Item ID (when the coupon scope is limited to just one item). */ entityId?: string; /** * Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */ name?: string; }; type InvalidMembership = { /** * Membership details. */ membership?: CurrentCart.Membership; /** * Reason why this membership is invalid and cannot be used. */ reason?: string; }; type ItemAvailabilityInfo = { /** * Quantity available. */ quantityAvailable?: number; /** * Item availability status. */ status?: string; }; type ItemTaxFullDetails = { /** * If breakdown exists, the sum of rates in the breakdown must equal `tax_rate`. */ rateBreakdown?: Array; /** * Tax rate %, as a decimal point between 0 and 1. */ taxRate?: string; /** * Amount for which tax is calculated. */ taxableAmount?: CurrentCart.MultiCurrencyPrice; /** * Calculated tax, based on `taxable_amount` and `tax_rate`. */ totalTax?: CurrentCart.MultiCurrencyPrice; }; type ItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type LineItem = { /** * Line item ID. */ _id?: string; /** * Item availability details. */ availability?: CurrentCart.ItemAvailabilityInfo; /** * Catalog and item reference. Holds IDs for the item and the catalog it came from, as well as further optional info. */ catalogReference?: CurrentCart.CatalogReference; /** * Line item description lines. Used for displaying the cart, checkout and order. */ descriptionLines?: Array; /** * Item price **before** catalog-defined discount. Defaults to `price` when not provided. */ fullPrice?: CurrentCart.MultiCurrencyPrice; /** * Line item image details. */ image?: string; /** * Item type. Either a preset type or custom. */ itemType?: CurrentCart.ItemType; /** * Type of selected payment option for current item. Defaults to `"FULL_PAYMENT_ONLINE"`. * + `"FULL_PAYMENT_ONLINE"` - The entire payment for this item happens as part of the checkout. * + `"FULL_PAYMENT_OFFLINE"` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `"MEMBERSHIP"` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` will be 0. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. */ physicalProperties?: CurrentCart.PhysicalProperties; /** * Item price **after** catalog-defined discount and line item discounts. */ price?: CurrentCart.MultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: CurrentCart.MultiCurrencyPrice; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: CurrentCart.PriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: CurrentCart.ProductName; /** * Item quantity. */ quantity?: number; /** * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID. * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID. * + in most cases, this field is the name as `catalogReference.catalogItemId`. * + Used in membership validation. */ rootCatalogItemId?: string; /** * Service properties. When relevant, this contains information such as date and number of participants. */ serviceProperties?: CurrentCart.ServiceProperties; /** * URL to the item's page on the site. */ url?: string; }; type LineItemPricesData = { /** * Total price **after** catalog-defined discount and line item discounts. */ lineItemPrice?: CurrentCart.MultiCurrencyPrice; /** * Catalog price after catalog discount and automatic discounts. */ price?: CurrentCart.MultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: CurrentCart.MultiCurrencyPrice; /** * Tax details. */ taxDetails?: CurrentCart.ItemTaxFullDetails; /** * Total discount for all line items. */ totalDiscount?: CurrentCart.MultiCurrencyPrice; /** * Total price after discounts and after tax. */ totalPriceAfterTax?: CurrentCart.MultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: CurrentCart.MultiCurrencyPrice; }; type LineItemQuantityUpdate = { /** * Line item ID. */ _id?: string; /** * New quantity. Number must 1 or higher. */ quantity?: number; }; type Membership = { /** * Membership ID. */ _id?: string; /** * Additional data about this membership. */ additionalData?: Object; /** * ID of the application providing this payment option. */ appId?: string; /** * Optional - For a membership that has limited credits, information about credit usage. */ credits?: CurrentCart.MembershipPaymentCredits; /** * Optional - TMembership expiry date. */ expirationDate?: Date; /** * Line item IDs which are "paid" for by this membership. */ lineItemIds?: Array; /** * The name of this membership. */ name?: CurrentCart.MembershipName; }; type MembershipName = { /** * The name of this membership */ original?: string; /** * Membership name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type MembershipOptions = { /** * List of payment options that can be used. */ eligibleMemberships?: Array; /** * List of payment options that are owned by the member, but cannot be used due to reason provided. */ invalidMemberships?: Array; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Array; }; type MembershipPaymentCredits = { /** * How much credit remained for this membership */ remaining?: number; /** * How much credit this membership has in total */ total?: number; }; type MerchantDiscount = { /** * Discount value. */ amount?: CurrentCart.MultiCurrencyPrice; }; type MerchantDiscountInput = { /** * Discount amount. */ amount?: string; /** * IDs of the line items the discount applies to. */ lineItemIds?: Array; }; type MultiCurrencyPrice = { /** * Amount. */ amount?: string; /** * Converted amount. */ convertedAmount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; /** * Converted amount formatted with currency symbol. */ formattedConvertedAmount?: string; }; type OtherCharge = { /** * Price of added cost. */ price?: CurrentCart.MultiCurrencyPrice; /** * Type of additional cost. */ type?: string; }; type PhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit is taken from `order.weightUnit`. Supported values: * + `"KG"` * + `"LB"` */ weight?: number; }; type PickupDetails = { /** * Pickup address. */ address?: CurrentCart.Address; /** * Whether the pickup address is that of a business - this may effect tax calculation. */ businessLocation?: boolean; /** * Pickup method */ pickupMethod?: string; }; type PlainTextValue = { /** * Description line plain text value in site's default language. */ original?: string; /** * Description line plain text value translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type PriceDescription = { /** * **Required** - Original price description (in site's default language). */ original?: string; /** * Product name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type PriceSummary = { /** * Total additional fees price. */ additionalFees?: CurrentCart.MultiCurrencyPrice; /** * Total calculated discount value. */ discount?: CurrentCart.MultiCurrencyPrice; /** * Total shipping price, before discounts and before tax. */ shipping?: CurrentCart.MultiCurrencyPrice; /** * Subtotal of all line items, before discounts and before tax. */ subtotal?: CurrentCart.MultiCurrencyPrice; /** * Total tax. */ tax?: CurrentCart.MultiCurrencyPrice; /** * Total price after discounts, gift cards, and tax. */ total?: CurrentCart.MultiCurrencyPrice; }; type ProductName = { /** * *Required** - Original product name (in site's default language). */ original?: string; /** * Description product name translated into buyer's language. Defaults to `original` when not defined. */ translated?: string; }; type RemoveCouponFromCurrentCartRequest = {}; type RemoveCouponRequest = { /** * Cart ID. */ _id: string; }; type RemoveCouponResponse = { /** * Updated cart. */ cart?: CurrentCart.Cart; }; type RemoveLineItemsFromCurrentCartRequest = { /** * IDs of the line items to remove from the cart. */ lineItemIds: Array; }; type RemoveLineItemsRequest = { /** * Cart ID. */ _id: string; /** * IDs of the line items to remove from the cart. */ lineItemIds: Array; }; type RemoveLineItemsResponse = { /** * Updated cart. */ cart?: CurrentCart.Cart; }; type Scope = { /** * Coupon scope's applied group (e.g., event or ticket in Wix Events) */ group?: CurrentCart.Group; /** * Scope namespace (Wix Stores, Wix Bookings, Wix Events) */ namespace?: string; }; type SecuredMedia = { /** * Media ID in media manager. */ _id?: string; /** * Original file name. */ fileName?: string; /** * File type. */ fileType?: string; }; type SelectedCarrierServiceOption = { /** * This carrier's unique ID */ carrierId?: string; /** * Unique identifier of selected option. For example, "usps_std_overnight". */ code?: string; /** * Shipping costs. */ cost?: CurrentCart.SelectedCarrierServiceOptionPrices; /** * Delivery logistics. */ logistics?: CurrentCart.DeliveryLogistics; /** * Other charges */ otherCharges?: Array; /** * Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) */ requestedShippingOption?: boolean; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type SelectedCarrierServiceOptionOtherCharge = { /** * Price of added charge. */ cost?: CurrentCart.SelectedCarrierServiceOptionPrices; /** * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'. */ details?: string; /** * Type of additional cost. */ type?: string; }; type SelectedCarrierServiceOptionPrices = { /** * Shipping price before discount and before tax. */ price?: CurrentCart.MultiCurrencyPrice; /** * Tax details. */ taxDetails?: CurrentCart.ItemTaxFullDetails; /** * Shipping discount before tax. */ totalDiscount?: CurrentCart.MultiCurrencyPrice; /** * Total shipping price, after discount and after tax. */ totalPriceAfterTax?: CurrentCart.MultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: CurrentCart.MultiCurrencyPrice; }; type SelectedMembership = { /** * Membership ID. */ _id?: string; /** * ID of the app providing this payment option. */ appId?: string; /** * IDs of the line items this membership applies to. */ lineItemIds?: Array; }; type SelectedMemberships = { /** * Selected memberships. */ memberships?: Array; }; type SelectedShippingOption = { /** * Carrier ID. */ carrierId?: string; /** * Selected shipping option code. For example, "usps_std_overnight". */ code?: string; }; type ServiceProperties = { /** * The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room. */ numberOfParticipants?: number; /** * The date and time for which the service is supposed to be provided. For example, the time of the class. */ scheduledDate?: Date; }; type ShippingInfo = { /** * Pickup details when this object describes pickup */ pickupDetails?: CurrentCart.V1PickupDetails; /** * Shipment details when this object describes shipment */ shippingAddress?: CurrentCart.CartAddress; /** * Selected shipping rule details */ shippingRuleDetails?: CurrentCart.ShippingRuleDetails; }; type ShippingInfoDetailsOneOf = { /** * Pickup details when this object describes pickup */ pickupDetails?: CurrentCart.V1PickupDetails; /** * Shipment details when this object describes shipment */ shippingAddress?: CurrentCart.CartAddress; }; type ShippingInformation = { /** * All shipping options. */ carrierServiceOptions?: Array; /** * Shipping region. */ region?: CurrentCart.ShippingRegion; /** * Selected shipping option. */ selectedCarrierServiceOption?: CurrentCart.SelectedCarrierServiceOption; }; type ShippingOption = { /** * Unique code of provided shipping option like "usps_std_overnight". * For legacy calculators this would be the UUID of the option. */ code?: string; /** * Sipping price information. */ cost?: CurrentCart.ShippingPrice; /** * Delivery logistics. */ logistics?: CurrentCart.DeliveryLogistics; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ShippingPrice = { /** * Other costs such as insurance, handling & packaging for fragile items, etc. */ otherCharges?: Array; /** * Shipping price. */ price?: CurrentCart.MultiCurrencyPrice; }; type ShippingRegion = { /** * Shipping region ID. */ _id?: string; /** * Shipping region name. */ name?: string; }; type ShippingRuleDetails = { /** * Rule title (as provided by the store owner) */ deliveryOption?: string; /** * Shipping option delivery time */ estimatedDeliveryTime?: string; /** * Selected option ID */ optionId?: string; /** * Selected shipping rule ID */ ruleId?: string; }; type StreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type Subdivision = { /** * Short subdivision code. */ code?: string; /** * Subdivision full name. */ name?: string; }; type SubscriptionOptionInfo = { /** * Subscription option description. */ description?: CurrentCart.Description; /** * Subscription option settings. */ subscriptionSettings?: CurrentCart.SubscriptionSettings; /** * Subscription option title. */ title?: CurrentCart.Title; }; type SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type TaxCalculationDetails = { /** * Error details and reason for tax rate fallback. */ autoTaxFallbackDetails?: CurrentCart.AutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; /** * Rate calculation type. Supported values: * + `"AUTO_RATE"` * + `"FALLBACK_RATE"` * + `"MANUAL_RATE"` * + `"NO_TAX_COLLECTED"` */ rateType?: string; }; type TaxCalculationDetailsCalculationDetailsOneOf = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: CurrentCart.AutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; }; type TaxRateBreakdown = { /** * Type of tax against which the calculation was performed. */ name?: string; /** * Rate at which this tax detail was calculated. */ rate?: string; /** * Amount of tax for this tax detail. */ tax?: CurrentCart.MultiCurrencyPrice; }; type TaxSummary = { /** * Tax calculator that was active when the order was created. */ calculationDetails?: CurrentCart.TaxCalculationDetails; /** * Amount for which tax is calculated, added from line items. */ taxableAmount?: CurrentCart.MultiCurrencyPrice; /** * Calculated tax, added from line items. */ totalTax?: CurrentCart.MultiCurrencyPrice; }; type Title = { /** * Subscription option name. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type Totals = { /** * Total calculated discount value, according to order.discount */ discount?: number; /** * Total line items quantity */ quantity?: number; /** * Total shipping price, including tax */ shipping?: number; /** * Subtotal of all line items, before tax */ subtotal?: number; /** * Total tax */ tax?: number; /** * Total price */ total?: number; /** * Total items weight */ weight?: number; }; type UpdateCartRequest = { /** * Cart info. */ cartInfo?: CurrentCart.Cart; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */ merchantDiscounts?: Array; }; type UpdateCartResponse = { /** * Updated Cart. */ cart?: CurrentCart.Cart; }; type UpdateCurrentCartLineItemQuantityRequest = { /** * Line item IDs and their new quantity. */ lineItems: Array; }; type UpdateCurrentCartOptions = { /** * Cart info. */ cartInfo?: CurrentCart.Cart; /** * The code of an existing coupon to apply to the cart. For more information, see the [Coupons API](https://www.wix.com/velo/reference/wix-marketing-backend/coupons). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */ merchantDiscounts?: Array; }; type UpdateLineItemsQuantityRequest = { /** * Cart ID. */ _id: string; /** * Line item IDs and their new quantity. */ lineItems: Array; }; type UpdateLineItemsQuantityResponse = { /** * Updated cart. */ cart?: CurrentCart.Cart; }; type V1BuyerInfo = { /** * Customer details */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer's relationship to the website */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; }; type V1Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: CurrentCart.MultiCurrencyPrice; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type V1MerchantDiscount = { /** * Discount value. */ amount?: CurrentCart.MultiCurrencyPrice; }; type V1PickupDetails = { /** * Customer details */ buyerDetails?: CurrentCart.BuyerDetails; /** * Pickup address */ pickupAddress?: CurrentCart.CommonAddress; /** * Store owner's pickup instructions */ pickupInstructions?: string; }; type ValidationError = { fieldViolations?: Array; }; type VatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Events.html#) */ namespace Events { type ecomDiscountsV1DiscountRuleActionEvent = { bodyAsJson?: string; }; type ecomDiscountsV1DiscountRuleActiveTimeInfo = { /** * Discount rule active end time. */ end?: Date; /** * Discount rule active start time. */ start?: Date; }; type ecomDiscountsV1DiscountRuleAnd = { /** * Array of triggers. Currently chaining up to 2 triggers is supported. */ triggers?: Array; }; type ecomDiscountsV1DiscountRuleAppliedDiscount = { /** * Applied discount rule. */ appliedDiscountRule?: Events.ecomDiscountsV1DiscountRuleAppliedDiscountRule; /** * Discount type. */ discountType?: string; /** * IDs of line items the discount applies to. */ lineItemIds?: Array; }; type ecomDiscountsV1DiscountRuleAppliedDiscountRule = { /** * Discount rule ID. */ _id?: string; /** * Total discount amount from all line items the discount applied to. */ amount?: Events.ecomDiscountsV1DiscountRuleMultiCurrencyPrice; /** * Discount rule type. */ discountRuleType?: string; /** * Discount rule name. */ name?: Events.ecomDiscountsV1DiscountRuleDiscountRuleName; }; type ecomDiscountsV1DiscountRuleBackendEventMetadata = { entityId: string; eventTime: string; id: string; triggeredByAnonymizeRequest: boolean; }; type ecomDiscountsV1DiscountRuleCatalogItemFilter = { /** * Catalog App ID. For example, the Wix Stores `appId`, or the 3rd-party `appId`. */ catalogAppId?: string; /** * ID of the item within its Wix or 3rd-party catalog. For example, `productId` for Wix Stores. */ catalogItemIds?: Array; }; type ecomDiscountsV1DiscountRuleCatalogReference = { /** * ID of the catalog app. For example, the Wix Stores `appId`, or the 3rd-party `appId`. */ appId?: string; /** * ID of the item within its Wix or 3rd-party catalog. For example, `productId` for Wix Stores or `eventId` for Wix Events. */ catalogItemId?: string; /** * Additional info in key:value form. For example, `{"options":{"Size": "M", "Color": "Red"}}` or `{"variantId": ""}`. */ options?: Object; }; type ecomDiscountsV1DiscountRuleCreateDiscountRuleRequest = { /** * Discount rule info. */ discountRule: Events.ecomDiscountsV1DiscountRuleDiscountRule; }; type ecomDiscountsV1DiscountRuleCreateDiscountRuleResponse = { /** * Discount rule. */ discountRule?: Events.ecomDiscountsV1DiscountRuleDiscountRule; }; type ecomDiscountsV1DiscountRuleCursorPaging = { /** * Pointer to the next or previous page in the list of results. */ cursor?: string; /** * Number of items to load. */ limit?: number; }; type ecomDiscountsV1DiscountRuleCursors = { /** * Cursor pointing to next page in the list of results. */ next?: string; /** * Cursor pointing to previous page in the list of results. */ prev?: string; }; type ecomDiscountsV1DiscountRuleCustom = { /** * Trigger ID. */ _id?: string; /** * App ID of the trigger creator. */ appId?: string; /** * Optional - additional data in key:value form. * + This data will be passed to the Custom Triggers Service SPI. * + For example, for a weather trigger that would be eligible if temperature is above 30 degrees, params would be: `{ "minTemp": 30 }`. */ params?: Object; }; type ecomDiscountsV1DiscountRuleCustomFilter = { /** * Custom filter app ID. */ appId?: string; /** * Custom-filter related data in key:value form. * For example, an array of collectionIDs: `{ ["collectionId": "12345"], ["collectionId": "67890"] }`. */ params?: Object; }; type ecomDiscountsV1DiscountRuleDeleteDiscountRuleRequest = { /** * ID of the discount rule to delete. */ discountRuleId: string; }; type ecomDiscountsV1DiscountRuleDeleteDiscountRuleResponse = {}; type ecomDiscountsV1DiscountRuleDiscount = { /** * Discount type. */ discountType?: string; /** * Amount to be discounted from original price. */ fixedAmount?: string; /** * Fixed price. Line item will be fixed to this price. */ fixedPrice?: string; /** * Percentage to be discounted from original price. */ percentage?: number; /** * Data related to `SPECIFIC_ITEMS` target type. */ specificItemsInfo?: Events.ecomDiscountsV1DiscountRuleSpecificItemsInfo; /** * Type of the target this discount is applied to. */ targetType?: string; }; type ecomDiscountsV1DiscountRuleDiscountDiscountOneOf = { /** * Amount to be discounted from original price. */ fixedAmount?: string; /** * Fixed price. Line item will be fixed to this price. */ fixedPrice?: string; /** * Percentage to be discounted from original price. */ percentage?: number; }; type ecomDiscountsV1DiscountRuleDiscountRule = { /** * Date and time the discount rule was created. */ _createdDate?: Date; /** * Discount rule ID. */ _id?: string; /** * Date and time the discount rule was last updated. */ _updatedDate?: Date; /** * Whether the discount rule is active. */ active?: boolean; /** * Time frame when the discount rule is active. */ activeTimeInfo?: Events.ecomDiscountsV1DiscountRuleActiveTimeInfo; /** * Description of a set of discounts that can be performed, if the trigger/s is met. * Currently only a single discount is supported. */ discounts?: Events.ecomDiscountsV1DiscountRuleDiscounts; /** * Discount rule name. */ name?: string; /** * calculated string which describe the discount rule //WHAT CAN BE THE MAXIMAL VAL? */ offer?: string; /** * Revision number, which increments by 1 each time the discount rule is updated. * To prevent conflicting changes, the existing `revision` must be used when updating a discount rule. */ revision?: string; /** * Discount rule status. */ status?: string; /** * Discount rule trigger. Description of a set of conditions that must be fulfilled to perform pre-defined discounts (see `discounts` field). * Not providing a trigger means the discount rule will always be applied (if possible). */ trigger?: Events.ecomDiscountsV1DiscountRuleDiscountTrigger; /** * Number of times the discount rule was used. */ usageCount?: number; }; type ecomDiscountsV1DiscountRuleDiscountRuleCreated = { entity: Events.ecomDiscountsV1DiscountRuleDiscountRule; metadata: Events.ecomDiscountsV1DiscountRuleBackendEventMetadata; }; type ecomDiscountsV1DiscountRuleDiscountRuleDeleted = { metadata: Events.ecomDiscountsV1DiscountRuleBackendEventMetadata; }; type ecomDiscountsV1DiscountRuleDiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomDiscountsV1DiscountRuleDiscountRuleUpdated = { entity: Events.ecomDiscountsV1DiscountRuleDiscountRule; metadata: Events.ecomDiscountsV1DiscountRuleBackendEventMetadata; }; type ecomDiscountsV1DiscountRuleDiscountTrigger = { /** * Chain multiple triggers with AND operator. */ and?: Events.ecomDiscountsV1DiscountRuleAnd; /** * Custom trigger. */ custom?: Events.ecomDiscountsV1DiscountRuleCustom; /** * Item quantity trigger. */ itemQuantityRange?: Events.ecomDiscountsV1DiscountRuleItemQuantityRange; /** * Subtotal trigger */ subtotalRange?: Events.ecomDiscountsV1DiscountRuleSubtotalRange; /** * Trigger Type */ triggerType?: string; }; type ecomDiscountsV1DiscountRuleDiscountTriggerTriggerOneOf = { /** * Chain multiple triggers with AND operator. */ and?: Events.ecomDiscountsV1DiscountRuleAnd; /** * Custom trigger. */ custom?: Events.ecomDiscountsV1DiscountRuleCustom; /** * Item quantity trigger. */ itemQuantityRange?: Events.ecomDiscountsV1DiscountRuleItemQuantityRange; /** * Subtotal trigger */ subtotalRange?: Events.ecomDiscountsV1DiscountRuleSubtotalRange; }; type ecomDiscountsV1DiscountRuleDiscounts = { /** * Discounts. */ values?: Array; }; type ecomDiscountsV1DiscountRuleDomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Events.ecomDiscountsV1DiscountRuleActionEvent; createdEvent?: Events.ecomDiscountsV1DiscountRuleEntityCreatedEvent; deletedEvent?: Events.ecomDiscountsV1DiscountRuleEntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Events.ecomDiscountsV1DiscountRuleExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Events.ecomDiscountsV1DiscountRuleEntityUpdatedEvent; }; type ecomDiscountsV1DiscountRuleDomainEventBodyOneOf = { actionEvent?: Events.ecomDiscountsV1DiscountRuleActionEvent; createdEvent?: Events.ecomDiscountsV1DiscountRuleEntityCreatedEvent; deletedEvent?: Events.ecomDiscountsV1DiscountRuleEntityDeletedEvent; extendedFieldsUpdatedEvent?: Events.ecomDiscountsV1DiscountRuleExtendedFieldsUpdatedEvent; updatedEvent?: Events.ecomDiscountsV1DiscountRuleEntityUpdatedEvent; }; type ecomDiscountsV1DiscountRuleEmpty = {}; type ecomDiscountsV1DiscountRuleEntityCreatedEvent = { entityAsJson?: string; }; type ecomDiscountsV1DiscountRuleEntityDeletedEvent = {}; type ecomDiscountsV1DiscountRuleEntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type ecomDiscountsV1DiscountRuleExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type ecomDiscountsV1DiscountRuleGetAppliedDiscountsRequest = { /** * Line items for which to check for discount rules. */ lineItems?: Array; }; type ecomDiscountsV1DiscountRuleGetAppliedDiscountsResponse = { /** * All eligible discounts. */ appliedDiscounts?: Array; }; type ecomDiscountsV1DiscountRuleGetDiscountRuleRequest = { /** * ID of the discount rule to retrieve. */ discountRuleId: string; }; type ecomDiscountsV1DiscountRuleGetDiscountRuleResponse = { /** * The requested discount rule. */ discountRule?: Events.ecomDiscountsV1DiscountRuleDiscountRule; }; type ecomDiscountsV1DiscountRuleItemQuantityRange = { /** * Quantity range - from (inclusive). */ from?: number; /** * All associated scopes for `SPECIFIC_ITEMS` target type. */ scopes?: Array; /** * Quantity range - to (inclusive). */ to?: number; }; type ecomDiscountsV1DiscountRuleLineItem = { /** * Line item ID. */ _id?: string; /** * Optional - Catalog and item reference info. See [Catalog SPI](https://bo.wix.com/wix-docs/rest/ecommerce/catalog-spi/introduction) for more details. * Empty in the case of a custom line item. */ catalogReference?: Events.ecomDiscountsV1DiscountRuleCatalogReference; /** * Price. */ price?: string; /** * Quantity. */ quantity?: number; }; type ecomDiscountsV1DiscountRuleMultiCurrencyPrice = { /** * Amount. */ amount?: string; /** * Converted amount. */ convertedAmount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; /** * Converted amount formatted with currency symbol. */ formattedConvertedAmount?: string; }; type ecomDiscountsV1DiscountRulePlatformPaging = { /** * Number of items to load. */ limit?: number; /** * Number of items to skip in the current sort order. */ offset?: number; }; type ecomDiscountsV1DiscountRulePlatformPagingMetadata = { /** * The number of items returned in this response. */ count?: number; /** * Cursors to navigate through result pages. Returned if cursor paging was used. */ cursors?: Events.ecomDiscountsV1DiscountRuleCursors; /** * The offset which was requested. Returned if offset paging was used. */ offset?: number; /** * The total number of items that match the query. Returned if offset paging was used. */ total?: number; }; type ecomDiscountsV1DiscountRulePlatformQuery = { /** * Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: Events.ecomDiscountsV1DiscountRuleCursorPaging; /** * Filter object. */ filter?: Object; /** * Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: Events.ecomDiscountsV1DiscountRulePlatformPaging; /** * Sorting options. For example, `[{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}]`. */ sort?: Array; }; type ecomDiscountsV1DiscountRulePlatformQueryPagingMethodOneOf = { /** * Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: Events.ecomDiscountsV1DiscountRuleCursorPaging; /** * Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: Events.ecomDiscountsV1DiscountRulePlatformPaging; }; type ecomDiscountsV1DiscountRuleQueryDiscountRulesRequest = { /** * Query options. */ query: Events.ecomDiscountsV1DiscountRulePlatformQuery; }; type ecomDiscountsV1DiscountRuleQueryDiscountRulesResponse = { /** * List of discount rules. */ discountRules?: Array; /** * Details on the paged set of results returned. */ pagingMetadata?: Events.ecomDiscountsV1DiscountRulePlatformPagingMetadata; }; type ecomDiscountsV1DiscountRuleScope = { /** * Scope ID. */ _id?: string; /** * Catalog item filter. Must be passed with `type."CATALOG_ITEM"`. */ catalogItemFilter?: Events.ecomDiscountsV1DiscountRuleCatalogItemFilter; /** * Custom filter. Must be passed with `type."CATALOG_ITEM"`. */ customFilter?: Events.ecomDiscountsV1DiscountRuleCustomFilter; /** * Scope type. */ type?: string; }; type ecomDiscountsV1DiscountRuleScopeScopeItemsOneOf = { /** * Catalog item filter. Must be passed with `type."CATALOG_ITEM"`. */ catalogItemFilter?: Events.ecomDiscountsV1DiscountRuleCatalogItemFilter; /** * Custom filter. Must be passed with `type."CATALOG_ITEM"`. */ customFilter?: Events.ecomDiscountsV1DiscountRuleCustomFilter; }; type ecomDiscountsV1DiscountRuleSorting = { /** * Name of the field to sort by. */ fieldName?: string; /** * Sort order. */ order?: string; }; type ecomDiscountsV1DiscountRuleSpecificItemsInfo = { /** * All associated scopes for `SPECIFIC_ITEMS` target type. */ scopes?: Array; }; type ecomDiscountsV1DiscountRuleSubtotalRange = { /** * Price range - from (inclusive). */ from?: string; /** * All associated scopes for `SPECIFIC_ITEMS` target type. * The trigger will be eligible if the line item is contained in one of the scopes. */ scopes?: Array; /** * Price range - to (inclusive). */ to?: string; }; type ecomDiscountsV1DiscountRuleUpdateDiscountRuleRequest = { /** * Discount rule info. */ discountRule: Events.ecomDiscountsV1DiscountRuleDiscountRule; }; type ecomDiscountsV1DiscountRuleUpdateDiscountRuleResponse = { /** * Updated discount rule. */ discountRule?: Events.ecomDiscountsV1DiscountRuleDiscountRule; }; type ecomV1CartActionEvent = { bodyAsJson?: string; }; type ecomV1CartAddToCartRequest = { /** * Cart ID. */ _id: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type ecomV1CartAddToCartResponse = { /** * Updated cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartAddToCurrentCartRequest = { /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; }; type ecomV1CartAdditionalFee = { /** * Additional fee's unique code (or ID) for future processing */ code?: string; /** * Translated additional fee's name */ name?: string; /** * Additional fee's price */ price?: Events.ecomV1CartMultiCurrencyPrice; /** * Provider's app id */ providerAppId?: string; /** * Tax details */ taxDetails?: Events.ecomV1CartItemTaxFullDetails; }; type ecomV1CartAddress = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Events.ecomV1CartStreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type ecomV1CartAddressLocation = { /** * Address latitude. */ latitude?: number; /** * Address longitude. */ longitude?: number; }; type ecomV1CartAddressWithContact = { /** * Address. */ address?: Events.ecomV1CartAddress; /** * Contact details. */ contactDetails?: Events.ecomV1CartApiFullAddressContactDetails; }; type ecomV1CartApiFullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: Events.ecomV1CartVatId; }; type ecomV1CartApplicationError = { code?: string; data?: Object; description?: string; }; type ecomV1CartAppliedCoupon = { /** * Coupon code */ code?: string; /** * Converted discount value */ convertedDiscountValue?: string; /** * Coupon internal ID */ couponId?: string; /** * Type (e.g., moneyOff, percentOff) */ couponType?: string; /** * Discount value */ discountValue?: string; /** * Coupon name */ name?: string; }; type ecomV1CartAppliedDiscount = { /** * Coupon details. */ coupon?: Events.ecomV1CartV1Coupon; /** * Discount rule */ discountRule?: Events.ecomV1CartDiscountRule; /** * Discount type. */ discountType?: string; /** * IDs of line items the discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1CartV1MerchantDiscount; }; type ecomV1CartAppliedDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: Events.ecomV1CartV1Coupon; /** * Discount rule */ discountRule?: Events.ecomV1CartDiscountRule; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1CartV1MerchantDiscount; }; type ecomV1CartAutoTaxFallbackCalculationDetails = { /** * invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */ error?: Events.ecomV1CartApplicationError; /** * reason for fallback */ fallbackReason?: string; }; type ecomV1CartBackendEventMetadata = { entityId: string; eventTime: string; id: string; triggeredByAnonymizeRequest: boolean; }; type ecomV1CartBuyerDetails = { /** * Email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; /** * Phone number */ phone?: string; }; type ecomV1CartBuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction). */ contactId?: string; /** * Member ID - if the buyer is a site member. */ memberId?: string; /** * User ID - if the cart owner is a Wix user. */ userId?: string; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type ecomV1CartBuyerInfoIdOneOf = { /** * Member ID - if the buyer is a site member. */ memberId?: string; /** * User ID - if the cart owner is a Wix user. */ userId?: string; /** * Visitor ID - if the buyer is **not** a site member. */ visitorId?: string; }; type ecomV1CartCalculatedLineItem = { /** * Line item ID. */ lineItemId?: string; /** * Type of selected payment option for current item. Supported values: * + `"FULL_PAYMENT_ONLINE"` - The entire payment for this item will happen as part of the checkout * + `"FULL_PAYMENT_OFFLINE"` - The entire payment for this item will happen after the checkout * + `"MEMBERSHIP"` - This item cannot be paid via monetary payment options, only via non monetary option such membership. When this option is used, price must be set to 0 * + `"DEPOSIT_ONLINE"` - Partial payment of the given item will happen as part of the checkout. Amount to be paid is defined by deposit_amount field. */ paymentOption?: string; /** * Price breakdown for this line item. */ pricesBreakdown?: Events.ecomV1CartLineItemPricesData; }; type ecomV1CartCalculationErrors = { /** * Carrier errors. */ carrierErrors?: Events.ecomV1CartCarrierErrors; /** * Coupon calculation error. */ couponCalculationError?: Events.ecomV1CartDetails; /** * Discount Rule calculation error. */ discountsCalculationError?: Events.ecomV1CartDetails; /** * General shipping calculation error. */ generalShippingCalculationError?: Events.ecomV1CartDetails; /** * Gift card calculation error. */ giftCardCalculationError?: Events.ecomV1CartDetails; /** * Membership payment methods calculation errors * For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid */ membershipError?: Events.ecomV1CartDetails; /** * Order validation errors. */ orderValidationErrors?: Array; /** * Tax calculation error. */ taxCalculationError?: Events.ecomV1CartDetails; }; type ecomV1CartCalculationErrorsShippingCalculationErrorOneOf = { /** * Carrier errors. */ carrierErrors?: Events.ecomV1CartCarrierErrors; /** * General shipping calculation error. */ generalShippingCalculationError?: Events.ecomV1CartDetails; }; type ecomV1CartCarrierError = { /** * Carrier ID. */ carrierId?: string; /** * Error details. */ error?: Events.ecomV1CartDetails; }; type ecomV1CartCarrierErrors = { /** * Carrier errors. */ errors?: Array; }; type ecomV1CartCarrierServiceOption = { /** * Carrier ID. */ carrierId?: string; /** * Shipping options offered by this carrier for this request. */ shippingOptions?: Array; }; type ecomV1CartCart = { /** * Date and time the cart was created. */ _createdDate?: Date; /** * Cart ID. */ _id?: string; /** * Date and time the cart was updated. */ _updatedDate?: Date; /** * Cart discounts. */ appliedDiscounts?: Array; /** * Buyer information. */ buyerInfo?: Events.ecomV1CartBuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * ID of the checkout related to this cart. */ checkoutId?: string; /** * Contact info. */ contactInfo?: Events.ecomV1CartAddressWithContact; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * Currency used for pricing. */ currency?: string; /** * Line items. */ lineItems?: Array; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrices?: boolean; /** * Weight measurement unit - defaults to site's weight unit. */ weightUnit?: string; }; type ecomV1CartCartAddress = { /** * Address */ address?: Events.ecomV1CartCommonAddress; /** * Contact details */ contactDetails?: Events.ecomV1CartFullAddressContactDetails; }; type ecomV1CartCartCompletedEvent = { /** * Coupon applied to this cart */ appliedCoupon?: Events.ecomV1CartAppliedCoupon; /** * Customer's billing address */ billingAddress?: Events.ecomV1CartCartAddress; /** * Customer's Wix ID */ buyerInfo?: Events.ecomV1CartV1BuyerInfo; /** * Message from the customer */ buyerNote?: string; cartId?: string; /** * Time the cart was created */ completedTime?: Date; /** * Currency used for pricing in this store */ currency?: Events.ecomV1CartCurrency; /** * Cart shipping information */ shippingInfo?: Events.ecomV1CartShippingInfo; /** * Totals for order's line items */ totals?: Events.ecomV1CartTotals; /** * Weight unit used in this store */ weightUnit?: string; }; type ecomV1CartCartCreated = { entity: Events.ecomV1CartCart; metadata: Events.ecomV1CartBackendEventMetadata; }; type ecomV1CartCartDeleted = { metadata: Events.ecomV1CartBackendEventMetadata; }; type ecomV1CartCartDiscount = { /** * Coupon details. */ coupon?: Events.ecomV1CartCoupon; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1CartMerchantDiscount; }; type ecomV1CartCartDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: Events.ecomV1CartCoupon; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1CartMerchantDiscount; }; type ecomV1CartCartUpdated = { entity: Events.ecomV1CartCart; metadata: Events.ecomV1CartBackendEventMetadata; }; type ecomV1CartCatalogReference = { /** * ID of the catalog app. For example, the Wix Stores `appId`, or the 3rd-party `appId`. */ appId?: string; /** * ID of the item within its Wix or 3rd-party catalog. For example, `productId` for Wix Stores or `eventId` for Wix Events. */ catalogItemId?: string; /** * Additional info in key:value form. For example, `{"options":{"Size": "M", "Color": "Red"}}` or `{"variantId": ""}`. */ options?: Object; }; type ecomV1CartColor = { /** * Optional - HEX or RGB color code for display. */ code?: string; /** * Optional - Description line color name in site's default language. */ original?: string; /** * Optional - Translated description line color name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartCommonAddress = { /** * Main address line, usually street and number as free text. */ addressLine?: string; /** * Main address line, usually street and number as free text. */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains Apt, Suite, and Floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Country code. */ country?: string; /** * Zip/postal code. */ postalCode?: string; /** * Street name and number. */ streetAddress?: Events.ecomV1CartStreetAddress; /** * Subdivision. Usually a state, region, prefecture, or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */ subdivision?: string; }; type ecomV1CartCommonAddressStreetOneOf = { /** * Main address line, usually street and number as free text. */ addressLine?: string; /** * Street name and number. */ streetAddress?: Events.ecomV1CartStreetAddress; }; type ecomV1CartCoupon = { /** * Coupon ID. */ _id?: string; /** * Coupon code. */ code?: string; }; type ecomV1CartCreateCartRequest = { /** * Cart info. */ cartInfo?: Events.ecomV1CartCart; /** * Code of an existing coupon to apply to cart. For more information, see [Coupons API](https://dev.wix.com/api/rest/wix-coupons/coupons/introduction). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */ merchantDiscounts?: Array; }; type ecomV1CartCreateCartResponse = { /** * Cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartCreateCheckoutFromCurrentCartRequest = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Events.ecomV1CartAddress; /** * Sales channel type. */ channelType?: string; /** * Mandatory when setting billing or shipping address and user is not logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: Events.ecomV1CartSelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Events.ecomV1CartAddress; }; type ecomV1CartCreateCheckoutRequest = { /** * Cart ID. */ _id: string; /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Events.ecomV1CartAddress; /** * Sales channel type. */ channelType?: string; /** * Mandatory when setting a billing or shipping address if the site visitor isn't logged in. */ email?: string; /** * Selected shipping option. */ selectedShippingOption?: Events.ecomV1CartSelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Events.ecomV1CartAddress; }; type ecomV1CartCreateCheckoutResponse = { /** * The newly created checkout's ID. */ checkoutId?: string; }; type ecomV1CartCurrency = { /** * Currency code */ code?: string; /** * Currency symbol */ symbol?: string; }; type ecomV1CartCustomLineItem = { /** * Custom line item ID. Defaults to an auto-generated ID. */ _id?: string; /** * Custom line item description lines. Used for display purposes for the cart, checkout and order. */ descriptionLines?: Array; /** * Custom line item's media. */ media?: string; /** * Custom line item name. */ name?: string; /** * Custom line item price. */ price?: string; /** * Custom line item quantity. */ quantity?: number; }; type ecomV1CartDeleteCartRequest = { /** * ID of the cart to delete. */ _id: string; }; type ecomV1CartDeleteCartResponse = {}; type ecomV1CartDeleteCurrentCartRequest = {}; type ecomV1CartDeliveryLogistics = { /** * Expected delivery time, in free text. For example, "3-5 business days". */ deliveryTime?: string; /** * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". */ instructions?: string; /** * Pickup details. */ pickupDetails?: Events.ecomV1CartPickupDetails; }; type ecomV1CartDescription = { /** * Subscription option description. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type ecomV1CartDescriptionLine = { /** * Description line color value. */ colorInfo?: Events.ecomV1CartColor; /** * Description line name. */ name?: Events.ecomV1CartDescriptionLineName; /** * Description line plain text value. */ plainText?: Events.ecomV1CartPlainTextValue; }; type ecomV1CartDescriptionLineDescriptionLineValueOneOf = {}; type ecomV1CartDescriptionLineName = { /** * Optional - Description line name in site's default language. */ original?: string; /** * Optional - Translated description line item according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartDescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: Events.ecomV1CartColor; /** * Description line plain text value. */ plainText?: Events.ecomV1CartPlainTextValue; }; type ecomV1CartDetails = { applicationError?: Events.ecomV1CartApplicationError; /** * deprecated in API's - to enable migration from rendering arbitrary tracing to rest response */ tracing?: Record; validationError?: Events.ecomV1CartValidationError; }; type ecomV1CartDetailsKindOneOf = { applicationError?: Events.ecomV1CartApplicationError; validationError?: Events.ecomV1CartValidationError; }; type ecomV1CartDiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: Events.ecomV1CartMultiCurrencyPrice; /** * Discount rule name */ name?: Events.ecomV1CartDiscountRuleName; }; type ecomV1CartDiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartDomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Events.ecomV1CartActionEvent; createdEvent?: Events.ecomV1CartEntityCreatedEvent; deletedEvent?: Events.ecomV1CartEntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Events.ecomV1CartExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Events.ecomV1CartEntityUpdatedEvent; }; type ecomV1CartDomainEventBodyOneOf = { actionEvent?: Events.ecomV1CartActionEvent; createdEvent?: Events.ecomV1CartEntityCreatedEvent; deletedEvent?: Events.ecomV1CartEntityDeletedEvent; extendedFieldsUpdatedEvent?: Events.ecomV1CartExtendedFieldsUpdatedEvent; updatedEvent?: Events.ecomV1CartEntityUpdatedEvent; }; type ecomV1CartEmpty = {}; type ecomV1CartEntityCreatedEvent = { entityAsJson?: string; }; type ecomV1CartEntityDeletedEvent = {}; type ecomV1CartEntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type ecomV1CartEstimateCurrentCartTotalsRequest = { /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Events.ecomV1CartAddress; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Events.ecomV1CartSelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: Events.ecomV1CartSelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Events.ecomV1CartAddress; }; type ecomV1CartEstimateTotalsRequest = { /** * Cart ID. */ _id: string; /** * Billing address. Used for calculating tax if all the items in the cart are not shippable. */ billingAddress?: Events.ecomV1CartAddress; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Events.ecomV1CartSelectedMemberships; /** * Selected shipping option. */ selectedShippingOption?: Events.ecomV1CartSelectedShippingOption; /** * Shipping address. Used for calculating tax and shipping (when applicable). */ shippingAddress?: Events.ecomV1CartAddress; }; type ecomV1CartEstimateTotalsResponse = { /** * Additional fees */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Calculated line items. */ calculatedLineItems?: Array; /** * Calculation errors. */ calculationErrors?: Events.ecomV1CartCalculationErrors; /** * Cart. */ cart?: Events.ecomV1CartCart; /** * Currency used for pricing in this store. */ currency?: string; /** * Applied gift card. */ giftCard?: Events.ecomV1CartGiftCard; /** * Information about valid and invalid memberships, and which ones are selected for usage. */ membershipOptions?: Events.ecomV1CartMembershipOptions; /** * Remaining amount for the order to be fully paid. */ payLater?: Events.ecomV1CartPriceSummary; /** * Minimal amount to pay in order to place the order. */ payNow?: Events.ecomV1CartPriceSummary; /** * Price summary. */ priceSummary?: Events.ecomV1CartPriceSummary; /** * Shipping information. */ shippingInfo?: Events.ecomV1CartShippingInformation; /** * Tax summary. */ taxSummary?: Events.ecomV1CartTaxSummary; /** * Weight measurement unit - defaults to site's weight unit. */ weightUnit?: string; }; type ecomV1CartExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type ecomV1CartFieldViolation = { data?: Object; description?: string; field?: string; /** * applicable when violated_rule=OTHER */ ruleName?: string; /** * Suppoerted values: * - `'DECIMAL_GT'` * - `'DECIMAL_GTE'` * - `'DECIMAL_LT'` * - `'DECIMAL_LTE'` * - `'DECIMAL_MAX_SCALE'` * - `'FORMAT'` * - `'INVALID_ENUM_VALUE'` * - `'MAX'` * - `'MAX_LENGTH'` * - `'MAX_SIZE'` * - `'MIN'` * - `'MIN_LENGTH'` * - `'MIN_SIZE'` * - `'OTHER'` * - `'REQUIRED_FIELD'` * - `'VALIDATION'` */ violatedRule?: string; }; type ecomV1CartFullAddressContactDetails = { /** * Contact's company */ company?: string; /** * Email associated with the address */ email?: string; /** * Contact first name */ firstName?: string; /** * Contact last name */ lastName?: string; /** * Contact phone number */ phone?: string; /** * tax info (Currently usable only in Brazil) */ vatId?: Events.ecomV1CartVatId; }; type ecomV1CartGetCartByCheckoutIdRequest = { /** * Checkout ID. */ _id: string; }; type ecomV1CartGetCartByCheckoutIdResponse = { /** * The requested cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartGetCartRequest = { /** * Cart ID. */ _id: string; }; type ecomV1CartGetCartResponse = { /** * The requested cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartGetCurrentCartRequest = {}; type ecomV1CartGetCurrentCartResponse = { /** * Current session's active cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartGiftCard = { /** * Gift Card ID. */ _id?: string; /** * Gift card value. */ amount?: Events.ecomV1CartMultiCurrencyPrice; /** * App ID of the gift card provider. */ appId?: string; /** * Gift card obfuscated code. */ obfuscatedCode?: string; }; type ecomV1CartGroup = { /** * Item ID (when the coupon scope is limited to just one item). */ entityId?: string; /** * Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */ name?: string; }; type ecomV1CartInvalidMembership = { /** * Membership details. */ membership?: Events.ecomV1CartMembership; /** * Reason why this membership is invalid and cannot be used. */ reason?: string; }; type ecomV1CartItemAvailabilityInfo = { /** * Quantity available. */ quantityAvailable?: number; /** * Item availability status. Supported Values: * + `"NOT_FOUND"`: Item does not exist * + `"NOT_AVAILABLE"`: Item not in stock * + `"PARTIALLY_AVAILABLE"`: Available quantity is less than requested */ status?: string; }; type ecomV1CartItemTaxFullDetails = { /** * If breakdown exists, the sum of rates in the breakdown must equal `tax_rate`. */ rateBreakdown?: Array; /** * Tax rate %, as a decimal point between 0 and 1. */ taxRate?: string; /** * Amount for which tax is calculated. */ taxableAmount?: Events.ecomV1CartMultiCurrencyPrice; /** * Calculated tax, based on `taxable_amount` and `tax_rate`. */ totalTax?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ecomV1CartItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ecomV1CartLineItem = { /** * Line item ID. */ _id?: string; /** * Item availability details. */ availability?: Events.ecomV1CartItemAvailabilityInfo; /** * Catalog and item reference info. See [Catalog SPI](https://bo.wix.com/wix-docs/rest/ecommerce/catalog-spi/introduction) for more details. * Empty in the case of a custom line item. */ catalogReference?: Events.ecomV1CartCatalogReference; /** * Line item description lines. Used for display purposes for the cart, checkout and order. */ descriptionLines?: Array; /** * Item price **before** catalog-defined discount. Defaults to `price` when not provided. */ fullPrice?: Events.ecomV1CartMultiCurrencyPrice; /** * Line item image details. */ image?: string; /** * Item type. Either a preset type or custom. */ itemType?: Events.ecomV1CartItemType; /** * Type of selected payment option for current item. Defaults to `FULL_PAYMENT_ONLINE`. * + `FULL_PAYMENT_ONLINE` - The entire payment for this item happens as part of the checkout. * + `FULL_PAYMENT_OFFLINE` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `MEMBERSHIP` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. */ physicalProperties?: Events.ecomV1CartPhysicalProperties; /** * Item price **after** catalog-defined discount and line item discounts. */ price?: Events.ecomV1CartMultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Events.ecomV1CartMultiCurrencyPrice; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: Events.ecomV1CartPriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: Events.ecomV1CartProductName; /** * Item quantity. */ quantity?: number; /** * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID. * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID. * + in most cases, this field is the name as `catalogReference.catalogItemId`. * + Used in membership validation. */ rootCatalogItemId?: string; /** * Service properties. When relevant, this contains information such as date and number of participants. */ serviceProperties?: Events.ecomV1CartServiceProperties; /** * URL to the item's page on the site. */ url?: string; }; type ecomV1CartLineItemPricesData = { /** * Total price **after** catalog-defined discount and line item discounts. */ lineItemPrice?: Events.ecomV1CartMultiCurrencyPrice; /** * Catalog price after catalog discount and automatic discounts. */ price?: Events.ecomV1CartMultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Events.ecomV1CartMultiCurrencyPrice; /** * Tax details. */ taxDetails?: Events.ecomV1CartItemTaxFullDetails; /** * Total discount for all line items. */ totalDiscount?: Events.ecomV1CartMultiCurrencyPrice; /** * Total price after discounts and after tax. */ totalPriceAfterTax?: Events.ecomV1CartMultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartLineItemQuantityUpdate = { /** * Line item ID. */ _id?: string; /** * New quantity. Number must 1 or higher. */ quantity?: number; }; type ecomV1CartMembership = { /** * Membership ID. */ _id?: string; /** * Additional data about this membership. */ additionalData?: Object; /** * ID of the application providing this payment option. */ appId?: string; /** * Optional - For a membership that has limited credits, information about credit usage. */ credits?: Events.ecomV1CartMembershipPaymentCredits; /** * Optional - TMembership expiry date. */ expirationDate?: Date; /** * Line item IDs which are "paid" for by this membership. */ lineItemIds?: Array; /** * The name of this membership. */ name?: Events.ecomV1CartMembershipName; }; type ecomV1CartMembershipName = { /** * The name of this membership */ original?: string; /** * Optional - Translated name of this membership. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartMembershipOptions = { /** * List of payment options that can be used. */ eligibleMemberships?: Array; /** * List of payment options that are owned by the member, but cannot be used due to reason provided. */ invalidMemberships?: Array; /** * The selected membership payment options and which line items they apply to. */ selectedMemberships?: Array; }; type ecomV1CartMembershipPaymentCredits = { /** * How much credit remained for this membership */ remaining?: number; /** * How much credit this membership has in total */ total?: number; }; type ecomV1CartMerchantDiscount = { /** * Discount value. */ amount?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartMerchantDiscountInput = { /** * Discount amount. */ amount?: string; /** * IDs of line items the discount applies to. */ lineItemIds?: Array; }; type ecomV1CartMultiCurrencyPrice = { /** * Amount. */ amount?: string; /** * Converted amount. */ convertedAmount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; /** * Converted amount formatted with currency symbol. */ formattedConvertedAmount?: string; }; type ecomV1CartOtherCharge = { /** * Price of added cost. */ price?: Events.ecomV1CartMultiCurrencyPrice; /** * Type of additional cost. */ type?: string; }; type ecomV1CartPhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit (KG or LB) is taken from `order.weightUnit`. */ weight?: number; }; type ecomV1CartPickupDetails = { /** * Pickup address. */ address?: Events.ecomV1CartAddress; /** * Whether the pickup address is that of a business - this may effect tax calculation. */ businessLocation?: boolean; /** * Pickup method */ pickupMethod?: string; }; type ecomV1CartPlainTextValue = { /** * Optional - Description line plain text value in site's default language. */ original?: string; /** * Optional - Translated description line plain text value according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartPriceDescription = { /** * Required** - Original price description (in site's default language). */ original?: string; /** * Optional - Translated product name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartPriceSummary = { /** * Total additional fees price. */ additionalFees?: Events.ecomV1CartMultiCurrencyPrice; /** * Total calculated discount value. */ discount?: Events.ecomV1CartMultiCurrencyPrice; /** * Total shipping price, before discounts and before tax. */ shipping?: Events.ecomV1CartMultiCurrencyPrice; /** * Subtotal of all line items, before discounts and before tax. */ subtotal?: Events.ecomV1CartMultiCurrencyPrice; /** * Total tax. */ tax?: Events.ecomV1CartMultiCurrencyPrice; /** * Total price after discounts, gift cards, and tax. */ total?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartProductName = { /** * Required** - Original item name (in site's default language). */ original?: string; /** * Optional - Translated item name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CartRemoveCouponFromCurrentCartRequest = {}; type ecomV1CartRemoveCouponRequest = { /** * Cart ID. */ _id: string; }; type ecomV1CartRemoveCouponResponse = { /** * Updated cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartRemoveLineItemsFromCurrentCartRequest = { /** * Line item IDs to remove from cart. */ lineItemIds: Array; }; type ecomV1CartRemoveLineItemsRequest = { /** * Cart ID. */ _id: string; /** * Line item IDs to remove from cart. */ lineItemIds: Array; }; type ecomV1CartRemoveLineItemsResponse = { /** * Updated cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartScope = { /** * Coupon scope's applied group (e.g., event or ticket in Wix Events) */ group?: Events.ecomV1CartGroup; /** * Scope namespace (Wix Stores, Wix Bookings, Wix Events) */ namespace?: string; }; type ecomV1CartSecuredMedia = { /** * Media ID in media manager. */ _id?: string; /** * Original file name. */ fileName?: string; /** * File type. */ fileType?: string; }; type ecomV1CartSelectedCarrierServiceOption = { /** * This carrier's unique ID */ carrierId?: string; /** * Unique identifier of selected option. For example, "usps_std_overnight". */ code?: string; /** * Shipping costs. */ cost?: Events.ecomV1CartSelectedCarrierServiceOptionPrices; /** * Delivery logistics. */ logistics?: Events.ecomV1CartDeliveryLogistics; /** * Other charges */ otherCharges?: Array; /** * Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) */ requestedShippingOption?: boolean; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ecomV1CartSelectedCarrierServiceOptionOtherCharge = { /** * Price of added charge. */ cost?: Events.ecomV1CartSelectedCarrierServiceOptionPrices; /** * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'. */ details?: string; /** * Type of additional cost. */ type?: string; }; type ecomV1CartSelectedCarrierServiceOptionPrices = { /** * Shipping price before discount and before tax. */ price?: Events.ecomV1CartMultiCurrencyPrice; /** * Tax details. */ taxDetails?: Events.ecomV1CartItemTaxFullDetails; /** * Shipping discount before tax. */ totalDiscount?: Events.ecomV1CartMultiCurrencyPrice; /** * Total shipping price, after discount and after tax. */ totalPriceAfterTax?: Events.ecomV1CartMultiCurrencyPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartSelectedMembership = { /** * Membership ID. */ _id?: string; /** * ID of the app providing this payment option. */ appId?: string; /** * IDs of the line items this membership applies to. */ lineItemIds?: Array; }; type ecomV1CartSelectedMemberships = { /** * Selected memberships. */ memberships?: Array; }; type ecomV1CartSelectedShippingOption = { /** * Carrier ID. */ carrierId?: string; /** * Selected shipping option code. For example, "usps_std_overnight". */ code?: string; }; type ecomV1CartServiceProperties = { /** * Optional - The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room. */ numberOfParticipants?: number; /** * Optional - The date and time for which the service is supposed to be provided. For example, the time of the class. */ scheduledDate?: Date; }; type ecomV1CartShippingInfo = { /** * Pickup details when this object describes pickup */ pickupDetails?: Events.ecomV1CartV1PickupDetails; /** * Shipment details when this object describes shipment */ shippingAddress?: Events.ecomV1CartCartAddress; /** * Selected shipping rule details */ shippingRuleDetails?: Events.ecomV1CartShippingRuleDetails; }; type ecomV1CartShippingInfoDetailsOneOf = { /** * Pickup details when this object describes pickup */ pickupDetails?: Events.ecomV1CartV1PickupDetails; /** * Shipment details when this object describes shipment */ shippingAddress?: Events.ecomV1CartCartAddress; }; type ecomV1CartShippingInformation = { /** * All shipping options. */ carrierServiceOptions?: Array; /** * Shipping region. */ region?: Events.ecomV1CartShippingRegion; /** * Selected shipping option. */ selectedCarrierServiceOption?: Events.ecomV1CartSelectedCarrierServiceOption; }; type ecomV1CartShippingOption = { /** * Unique code of provided shipping option like "usps_std_overnight". * For legacy calculators this would be the UUID of the option. */ code?: string; /** * Sipping price information. */ cost?: Events.ecomV1CartShippingPrice; /** * Delivery logistics. */ logistics?: Events.ecomV1CartDeliveryLogistics; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ecomV1CartShippingPrice = { /** * Other costs such as insurance, handling & packaging for fragile items, etc. */ otherCharges?: Array; /** * Shipping price. */ price?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartShippingRegion = { /** * Shipping region ID. */ _id?: string; /** * Shipping region name. */ name?: string; }; type ecomV1CartShippingRuleDetails = { /** * Rule title (as provided by the store owner) */ deliveryOption?: string; /** * Shipping option delivery time */ estimatedDeliveryTime?: string; /** * Selected option ID */ optionId?: string; /** * Selected shipping rule ID */ ruleId?: string; }; type ecomV1CartStreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type ecomV1CartSubdivision = { /** * Short subdivision code. */ code?: string; /** * Subdivision full name. */ name?: string; }; type ecomV1CartSubscriptionOptionInfo = { /** * Subscription option description. */ description?: Events.ecomV1CartDescription; /** * Subscription option settings. */ subscriptionSettings?: Events.ecomV1CartSubscriptionSettings; /** * Subscription option title. */ title?: Events.ecomV1CartTitle; }; type ecomV1CartSubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type ecomV1CartTaxCalculationDetails = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Events.ecomV1CartAutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; /** * Rate calculation type. */ rateType?: string; }; type ecomV1CartTaxCalculationDetailsCalculationDetailsOneOf = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Events.ecomV1CartAutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; }; type ecomV1CartTaxRateBreakdown = { /** * Type of tax against which the calculation was performed. */ name?: string; /** * Rate at which this tax detail was calculated. */ rate?: string; /** * Amount of tax for this tax detail. */ tax?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartTaxSummary = { /** * Tax calculator that was active when the order was created. */ calculationDetails?: Events.ecomV1CartTaxCalculationDetails; /** * Amount for which tax is calculated, added from line items. */ taxableAmount?: Events.ecomV1CartMultiCurrencyPrice; /** * Calculated tax, added from line items. */ totalTax?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartTitle = { /** * Subscription option name. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type ecomV1CartTotals = { /** * Total calculated discount value, according to order.discount */ discount?: number; /** * Total line items quantity */ quantity?: number; /** * Total shipping price, including tax */ shipping?: number; /** * Subtotal of all line items, before tax */ subtotal?: number; /** * Total tax */ tax?: number; /** * Total price */ total?: number; /** * Total items weight */ weight?: number; }; type ecomV1CartUpdateCartRequest = { /** * Cart info. */ cartInfo?: Events.ecomV1CartCart; /** * Coupon code. For more information, see [Coupons API](https://dev.wix.com/api/rest/wix-coupons/coupons/introduction). */ couponCode?: string; /** * Custom line items. */ customLineItems?: Array; /** * Catalog line items. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole cart. */ merchantDiscounts?: Array; }; type ecomV1CartUpdateCartResponse = { /** * Updated Cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartUpdateCurrentCartLineItemQuantityRequest = { /** * Line item IDs and their new quantity. */ lineItems: Array; }; type ecomV1CartUpdateLineItemsQuantityRequest = { /** * Cart ID. */ _id: string; /** * Line item IDs and their new quantity. */ lineItems: Array; }; type ecomV1CartUpdateLineItemsQuantityResponse = { /** * Updated cart. */ cart?: Events.ecomV1CartCart; }; type ecomV1CartV1BuyerInfo = { /** * Customer details */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer's relationship to the website */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; }; type ecomV1CartV1Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: Events.ecomV1CartMultiCurrencyPrice; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type ecomV1CartV1MerchantDiscount = { /** * Discount value. */ amount?: Events.ecomV1CartMultiCurrencyPrice; }; type ecomV1CartV1PickupDetails = { /** * Customer details */ buyerDetails?: Events.ecomV1CartBuyerDetails; /** * Pickup address */ pickupAddress?: Events.ecomV1CartCommonAddress; /** * Store owner's pickup instructions */ pickupInstructions?: string; }; type ecomV1CartValidationError = { fieldViolations?: Array; }; type ecomV1CartVatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; type ecomV1CheckoutActionEvent = { bodyAsJson?: string; }; type ecomV1CheckoutAdditionalFee = { /** * Additional fee's unique code (or ID) for future processing */ code?: string; /** * Translated additional fee's name */ name?: string; /** * Additional fee's price */ price?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Provider's app id */ providerAppId?: string; /** * Tax details */ taxDetails?: Events.ecomV1CheckoutItemTaxFullDetails; }; type ecomV1CheckoutAddress = { /** * Address line 1 (free text) */ addressLine1?: string; /** * address line */ addressLine2?: string; /** * City name */ city?: string; /** * Company name */ company?: string; /** * Country code (2 letters) */ country?: string; /** * Email address */ email?: string; /** * Addressee name */ fullName?: Events.ecomV1CheckoutFullName; /** * Phone number */ phone?: string; /** * Address line 1 (street) */ street?: Events.ecomV1CheckoutStreet; /** * State or district */ subdivision?: string; /** * Tax information (for Brazil only) */ vatId?: Events.ecomV1CheckoutVatId; /** * ZIP/postal code */ zipCode?: string; }; type ecomV1CheckoutAddressAddressLine1OptionsOneOf = { /** * Address line 1 (free text) */ addressLine1?: string; /** * Address line 1 (street) */ street?: Events.ecomV1CheckoutStreet; }; type ecomV1CheckoutAddressWithContact = { /** * Address. */ address?: Events.ecomV1CheckoutApiAddress; /** * Contact details. */ contactDetails?: Events.ecomV1CheckoutFullAddressContactDetails; }; type ecomV1CheckoutApiAddress = { /** * Main address line (usually street name and number). */ addressLine?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Country's full name. */ countryFullname?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Events.ecomV1CheckoutStreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; /** * Subdivision full-name. */ subdivisionFullname?: string; }; type ecomV1CheckoutApplicationError = { code?: string; data?: Object; description?: string; }; type ecomV1CheckoutAppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type ecomV1CheckoutAppliedDiscount = { /** * Coupon details. */ coupon?: Events.ecomV1CheckoutCoupon; /** * Discount rule */ discountRule?: Events.ecomV1CheckoutDiscountRule; /** * Discount type. */ discountType?: string; /** * IDs of line items the discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1CheckoutMerchantDiscount; }; type ecomV1CheckoutAppliedDiscountDiscountSourceOneOf = { /** * Coupon details. */ coupon?: Events.ecomV1CheckoutCoupon; /** * Discount rule */ discountRule?: Events.ecomV1CheckoutDiscountRule; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1CheckoutMerchantDiscount; }; type ecomV1CheckoutAutoTaxFallbackCalculationDetails = { /** * invalid request (i.e. address), timeout, internal error, license error, and others will be encoded here */ error?: Events.ecomV1CheckoutApplicationError; /** * reason for fallback */ fallbackReason?: string; }; type ecomV1CheckoutBackendEventMetadata = { entityId: string; eventTime: string; id: string; triggeredByAnonymizeRequest: boolean; }; type ecomV1CheckoutBillingInfo = { /** * Full billing address */ address?: Events.ecomV1CheckoutAddress; /** * Deprecated (use paymentProviderTransactionId instead) */ externalTransactionId?: string; /** * Payment date */ paidDate?: Date; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; /** * Transaction ID from payment provider (e.g., PayPal, Square, Stripe) transaction ID */ paymentProviderTransactionId?: string; /** * Whether order can be refunded by payment provider (manually or automatic) */ refundableByPaymentProvider?: boolean; }; type ecomV1CheckoutBuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction). */ contactId?: string; /** * Buyer email address. */ email?: string; /** * Member ID (if site visitor is a site member). */ memberId?: string; /** * + When `true` - checkout doesn't have an owner yet and anyone can access it. The first to access it will be new owner. * + If `false`, the value in `checkout.createdBy` is the owner. */ openAccess?: boolean; /** * Visitor ID (if site visitor is **not** a member). */ visitorId?: string; }; type ecomV1CheckoutBuyerInfoIdOneOf = { /** * Member ID (if site visitor is a site member). */ memberId?: string; /** * + When `true` - checkout doesn't have an owner yet and anyone can access it. The first to access it will be new owner. * + If `false`, the value in `checkout.createdBy` is the owner. */ openAccess?: boolean; /** * Visitor ID (if site visitor is **not** a member). */ visitorId?: string; }; type ecomV1CheckoutCalculationErrors = { /** * Carrier errors. */ carrierErrors?: Events.ecomV1CheckoutCarrierErrors; /** * Coupon calculation error. */ couponCalculationError?: Events.ecomV1CheckoutDetails; /** * Discount Rule calculation error. */ discountsCalculationError?: Events.ecomV1CheckoutDetails; /** * General shipping calculation error. */ generalShippingCalculationError?: Events.ecomV1CheckoutDetails; /** * Gift card calculation error. */ giftCardCalculationError?: Events.ecomV1CheckoutDetails; /** * Membership payment methods calculation errors * For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid */ membershipError?: Events.ecomV1CheckoutDetails; /** * Order validation errors. */ orderValidationErrors?: Array; /** * Tax calculation error. */ taxCalculationError?: Events.ecomV1CheckoutDetails; }; type ecomV1CheckoutCalculationErrorsShippingCalculationErrorOneOf = { /** * Carrier errors. */ carrierErrors?: Events.ecomV1CheckoutCarrierErrors; /** * General shipping calculation error. */ generalShippingCalculationError?: Events.ecomV1CheckoutDetails; }; type ecomV1CheckoutCarrierError = { /** * Carrier ID. */ carrierId?: string; /** * Error details. */ error?: Events.ecomV1CheckoutDetails; }; type ecomV1CheckoutCarrierErrors = { /** * Carrier errors. */ errors?: Array; }; type ecomV1CheckoutCarrierServiceOption = { /** * Carrier ID. */ carrierId?: string; /** * Shipping options offered by this carrier for this request. */ shippingOptions?: Array; }; type ecomV1CheckoutCatalogReference = { /** * ID of the catalog app. For example, the Wix Stores `appId`, or the 3rd-party `appId`. */ appId?: string; /** * ID of the item within its Wix or 3rd-party catalog. For example, `productId` for Wix Stores or `eventId` for Wix Events. */ catalogItemId?: string; /** * Additional info in key:value form. For example, `{"options":{"Size": "M", "Color": "Red"}}` or `{"variantId": ""}`. */ options?: Object; }; type ecomV1CheckoutChannelInfo = { /** * Sales channel that submitted the subscription */ type?: string; }; type ecomV1CheckoutChargeDetails = { /** * Discount applied for this line item */ discount?: number; /** * price of line item (depends on subscription option) */ price?: number; /** * Tax applied for this line item */ tax?: number; /** * Is tax applied for this line item */ taxIncludedInPrice?: boolean; /** * Total price charged to the customer (for this line items) after computation of quantity and discount */ totalPrice?: number; }; type ecomV1CheckoutCheckout = { /** * Date and time the checkout was created. */ _createdDate?: Date; /** * Checkout ID. */ _id?: string; /** * Date and time the checkout was updated. */ _updatedDate?: Date; /** * Additional Fees */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Billing information. */ billingInfo?: Events.ecomV1CheckoutAddressWithContact; /** * Buyer information. */ buyerInfo?: Events.ecomV1CheckoutBuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * Errors when calculating totals. */ calculationErrors?: Events.ecomV1CheckoutCalculationErrors; /** * Sales channel that submitted the order. "WIX_APP_STORE" refers to the Wix mobile app. */ channelType?: string; /** * Whether an order was successfully created from this checkout. * For an order to be successful, it must be successfully paid for (unless the total is 0). */ completed?: boolean; /** * All the converted prices are presented in this currency. */ conversionCurrency?: string; /** * ID of the checkout's initiator. */ createdBy?: Events.ecomV1CheckoutCreatedBy; /** * Currency used for pricing in this store. */ currency?: string; /** * Custom fields. */ customFields?: Array; /** * Applied gift card details. */ giftCard?: Events.ecomV1CheckoutGiftCard; /** * Line items. */ lineItems?: Array; /** * Information about valid and invalid memberships, and which ones are selected for usage */ membershipOptions?: Events.ecomV1CheckoutMembershipOptions; /** * Remaining amount for the order to be fully paid. */ payLater?: Events.ecomV1CheckoutPriceSummary; /** * Minimal amount to pay in order to place the order. */ payNow?: Events.ecomV1CheckoutPriceSummary; /** * Calculated price summary for the checkout. */ priceSummary?: Events.ecomV1CheckoutPriceSummary; /** * Shipping information. */ shippingInfo?: Events.ecomV1CheckoutShippingInfo; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrice?: boolean; /** * Tax summary. */ taxSummary?: Events.ecomV1CheckoutTaxSummary; /** * Weight measurement unit - defaults to site's weight unit. */ weightUnit?: string; }; type ecomV1CheckoutCheckoutCompleted = { data: Events.ecomV1CheckoutCheckoutMarkedAsCompleted; metadata: Events.ecomV1CheckoutBackendEventMetadata; }; type ecomV1CheckoutCheckoutCreated = { entity: Events.ecomV1CheckoutCheckout; metadata: Events.ecomV1CheckoutBackendEventMetadata; }; type ecomV1CheckoutCheckoutMarkedAsCompleted = { checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutCheckoutUpdated = { entity: Events.ecomV1CheckoutCheckout; metadata: Events.ecomV1CheckoutBackendEventMetadata; }; type ecomV1CheckoutColor = { /** * Optional - HEX or RGB color code for display. */ code?: string; /** * Optional - Description line color name in site's default language. */ original?: string; /** * Optional - Translated description line color name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutCommonVatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; type ecomV1CheckoutCoupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type ecomV1CheckoutCreateCheckoutRequest = { /** * Sales channel that submitted the order. */ channelType?: string; /** * Checkout information. */ checkoutInfo?: Events.ecomV1CheckoutCheckout; /** * Coupon code. */ couponCode?: string; /** * Custom line items to be added to checkout. */ customLineItems?: Array; /** * Gift card code. */ giftCardCode?: string; /** * Line items to be added to checkout. */ lineItems?: Array; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole checkout. */ merchantDiscounts?: Array; }; type ecomV1CheckoutCreateCheckoutResponse = { /** * Newly created checkout. */ checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutCreateOrderAndChargeRequest = { /** * Checkout ID. */ _id: string; /** * Payment token. */ paymentToken?: string; /** * Custom URL params to be added to redirect URLs. */ urlParams?: Record; }; type ecomV1CheckoutCreateOrderAndChargeResponse = { /** * ID of newly created order. */ orderId?: string; /** * The payment gateway is cashier. * payment_gateway_order_id will be returned given that money was charged. * In some cases, money will not be charged: * If the total price is 0 - For example, could be a free item or a an item with 100% discount * If the total price is not 0, but the payment is covered by alternative payment methods such as gift card */ paymentGatewayOrderId?: string; /** * Payment response token. */ paymentResponseToken?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type ecomV1CheckoutCreateOrderAndChargeResponseIdOneOf = { /** * ID of newly created order. */ orderId?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type ecomV1CheckoutCreateOrderRequest = { /** * Checkout ID. */ _id: string; /** * Custom URL params to be added to redirect URLs. */ urlParams?: Record; }; type ecomV1CheckoutCreateOrderResponse = { /** * ID of newly created order (ecom order ID) */ orderId?: string; /** * The payment gateway is cashier. * payment_gateway_order_id will be returned given that money needs to be charged. * In some cases, money should not be charged: * If the total price is 0 - For example, could be a free item or a an item with 100% discount * If the total price is not 0, but the payment is covered by alternative payment methods such as gift card */ paymentGatewayOrderId?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type ecomV1CheckoutCreateOrderResponseIdOneOf = { /** * ID of newly created order (ecom order ID) */ orderId?: string; /** * ID of newly created subscription. */ subscriptionId?: string; }; type ecomV1CheckoutCreatedBy = { /** * App ID - when the order was created by an external application or Wix service. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type ecomV1CheckoutCreatedByIdOneOf = { /** * App ID - when the order was created by an external application or Wix service. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type ecomV1CheckoutCustomField = { /** * Custom field title. */ title?: string; /** * Translated custom field title. */ translatedTitle?: string; /** * Custom field value. */ value?: any; }; type ecomV1CheckoutCustomLineItem = { /** * Custom line item ID. Defaults to an auto-generated ID. */ _id?: string; /** * Custom line item description lines. Used for display purposes for the cart, checkout and order. */ descriptionLines?: Array; /** * Custom line item's media. */ media?: string; /** * Custom line item name. */ name?: string; /** * Custom line item price. */ price?: string; /** * Custom line item quantity. */ quantity?: number; }; type ecomV1CheckoutCustomTextFieldSelection = { /** * Custom text field name */ title?: string; /** * Custom text field value */ value?: string; }; type ecomV1CheckoutDeliveryLogistics = { /** * Expected delivery time, in free text. For example, "3-5 business days". */ deliveryTime?: string; /** * Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". */ instructions?: string; /** * Pickup details. */ pickupDetails?: Events.ecomV1CheckoutPickupDetails; }; type ecomV1CheckoutDescription = { /** * Subscription option description. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type ecomV1CheckoutDescriptionLine = { /** * Description line color value. */ colorInfo?: Events.ecomV1CheckoutColor; /** * Description line name. */ name?: Events.ecomV1CheckoutDescriptionLineName; /** * Description line plain text value. */ plainText?: Events.ecomV1CheckoutPlainTextValue; }; type ecomV1CheckoutDescriptionLineDescriptionLineValueOneOf = {}; type ecomV1CheckoutDescriptionLineName = { /** * Optional - Description line name in site's default language. */ original?: string; /** * Optional - Translated description line item according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutDescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: Events.ecomV1CheckoutColor; /** * Description line plain text value. */ plainText?: Events.ecomV1CheckoutPlainTextValue; }; type ecomV1CheckoutDetails = { applicationError?: Events.ecomV1CheckoutApplicationError; /** * deprecated in API's - to enable migration from rendering arbitrary tracing to rest response */ tracing?: Record; validationError?: Events.ecomV1CheckoutValidationError; }; type ecomV1CheckoutDetailsKindOneOf = { applicationError?: Events.ecomV1CheckoutApplicationError; validationError?: Events.ecomV1CheckoutValidationError; }; type ecomV1CheckoutDiscount = { /** * Discount type. */ type?: string; /** * Discount value. */ value?: number; }; type ecomV1CheckoutDiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Discount rule name */ name?: Events.ecomV1CheckoutDiscountRuleName; }; type ecomV1CheckoutDiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutDomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Events.ecomV1CheckoutActionEvent; createdEvent?: Events.ecomV1CheckoutEntityCreatedEvent; deletedEvent?: Events.ecomV1CheckoutEntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Events.ecomV1CheckoutExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Events.ecomV1CheckoutEntityUpdatedEvent; }; type ecomV1CheckoutDomainEventBodyOneOf = { actionEvent?: Events.ecomV1CheckoutActionEvent; createdEvent?: Events.ecomV1CheckoutEntityCreatedEvent; deletedEvent?: Events.ecomV1CheckoutEntityDeletedEvent; extendedFieldsUpdatedEvent?: Events.ecomV1CheckoutExtendedFieldsUpdatedEvent; updatedEvent?: Events.ecomV1CheckoutEntityUpdatedEvent; }; type ecomV1CheckoutEmpty = {}; type ecomV1CheckoutEntityCreatedEvent = { entityAsJson?: string; }; type ecomV1CheckoutEntityDeletedEvent = {}; type ecomV1CheckoutEntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type ecomV1CheckoutExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type ecomV1CheckoutFieldViolation = { data?: Object; description?: string; field?: string; /** * applicable when violated_rule=OTHER */ ruleName?: string; /** * Suppoerted values: * - `'DECIMAL_GT'` * - `'DECIMAL_GTE'` * - `'DECIMAL_LT'` * - `'DECIMAL_LTE'` * - `'DECIMAL_MAX_SCALE'` * - `'FORMAT'` * - `'INVALID_ENUM_VALUE'` * - `'MAX'` * - `'MAX_LENGTH'` * - `'MAX_SIZE'` * - `'MIN'` * - `'MIN_LENGTH'` * - `'MIN_SIZE'` * - `'OTHER'` * - `'REQUIRED_FIELD'` * - `'VALIDATION'` */ violatedRule?: string; }; type ecomV1CheckoutFullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: Events.ecomV1CheckoutCommonVatId; }; type ecomV1CheckoutFullName = { /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; }; type ecomV1CheckoutGetCheckoutRequest = { /** * Checkout ID. */ _id: string; }; type ecomV1CheckoutGetCheckoutResponse = { /** * The requested checkout. */ checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutGetWixCheckoutUrlRequest = { /** * Checkout ID. */ _id: string; }; type ecomV1CheckoutGetWixCheckoutUrlResponse = { /** * Checkout URL. */ checkoutUrl?: string; }; type ecomV1CheckoutGiftCard = { /** * Gift Card ID. */ _id?: string; /** * Gift card value. */ amount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * App ID of the gift card provider. */ appId?: string; /** * Gift card obfuscated code. */ obfuscatedCode?: string; }; type ecomV1CheckoutGroup = { /** * Item ID (when the coupon scope is limited to just one item). */ entityId?: string; /** * Coupon scope's group (e.g., product or collection in Wix Stores). See [valid scope values](https://dev.wix.com/api/rest/coupons/coupons/valid-scope-values). */ name?: string; }; type ecomV1CheckoutInvalidMembership = { /** * Membership details. */ membership?: Events.ecomV1CheckoutMembership; /** * Reason why this membership is invalid and cannot be used. */ reason?: string; }; type ecomV1CheckoutItemAvailabilityInfo = { /** * Quantity available. */ quantityAvailable?: number; /** * Item availability status. Supported Values: * + `"NOT_FOUND"`: Item does not exist * + `"NOT_AVAILABLE"`: Item not in stock * + `"PARTIALLY_AVAILABLE"`: Available quantity is less than requested */ status?: string; }; type ecomV1CheckoutItemTaxFullDetails = { /** * If breakdown exists, the sum of rates in the breakdown must equal `tax_rate`. */ rateBreakdown?: Array; /** * Tax rate %, as a decimal point between 0 and 1. */ taxRate?: string; /** * Amount for which tax is calculated. */ taxableAmount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Calculated tax, based on `taxable_amount` and `tax_rate`. */ totalTax?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ecomV1CheckoutItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ecomV1CheckoutLineItem = { /** * Line item ID. */ _id?: string; /** * Item availability details. */ availability?: Events.ecomV1CheckoutItemAvailabilityInfo; /** * Catalog and item reference info. See [Catalog SPI](https://bo.wix.com/wix-docs/rest/ecommerce/catalog-spi/introduction) for more details. * Empty in the case of a custom line item. */ catalogReference?: Events.ecomV1CheckoutCatalogReference; /** * Partial payment for the given item to be paid upfront during the checkout. Eligible for catalog items with type `DEPOSIT_ONLINE` only. */ depositAmount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Line item description lines. Used for display purposes for the cart, checkout and order. */ descriptionLines?: Array; /** * Discount for this line item's entire quantity. */ discount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Item price **before** catalog-defined discount. Defaults to `price` when not provided. */ fullPrice?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Item type. Either a preset type or custom. */ itemType?: Events.ecomV1CheckoutItemType; /** * Total price **after** catalog-defined discount and line item discounts. */ lineItemPrice?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Line item image details. */ media?: string; /** * Type of selected payment option for current item. Defaults to `FULL_PAYMENT_ONLINE`. * + `FULL_PAYMENT_ONLINE` - The entire payment for this item happens as part of the checkout. * + `FULL_PAYMENT_OFFLINE` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `MEMBERSHIP` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0. * + `DEPOSIT_ONLINE` - Partial payment for the given item to be paid upfront during the checkout. Amount to be paid is defined by deposit_amount field. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. */ physicalProperties?: Events.ecomV1CheckoutPhysicalProperties; /** * Item price **after** catalog-defined discount and line item discounts. */ price?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: Events.ecomV1CheckoutPriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: Events.ecomV1CheckoutProductName; /** * Item quantity. */ quantity?: number; /** * In cases where `catalogReference.catalogItemId` is NOT the actual catalog item ID, this field will return the true item's ID. * + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking ID. Therefore this value is set to the service ID. * + In most cases, this field has the same value as `catalogReference.catalogItemId`. * + Used in membership validation. */ rootCatalogItemId?: string; /** * Service properties. When relevant, this contains information such as date and number of participants. */ serviceProperties?: Events.ecomV1CheckoutServiceProperties; /** * Tax details for this line item. */ taxDetails?: Events.ecomV1CheckoutItemTaxFullDetails; /** * Total price after all discounts and tax. */ totalPriceAfterTax?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Total price after all discounts, before tax. */ totalPriceBeforeTax?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * URL to the item's page on the site. */ url?: string; }; type ecomV1CheckoutMarkCheckoutAsCompletedRequest = { /** * Checkout ID. */ _id: string; }; type ecomV1CheckoutMarkCheckoutAsCompletedResponse = {}; type ecomV1CheckoutMediaItem = { /** * Media ID (for media items previously saved in Wix Media) */ _id?: string; /** * Alternative text for presentation when media cannot be displayed */ altText?: string; /** * Media external URL */ externalImageUrl?: string; /** * Media item height */ height?: number; /** * Media type */ mediaType?: string; /** * Media URL */ url?: string; /** * Media item width */ width?: number; }; type ecomV1CheckoutMembership = { /** * Membership ID. */ _id?: string; /** * Additional data about this membership. */ additionalData?: Object; /** * ID of the application providing this payment option. */ appId?: string; /** * Optional - For a membership that has limited credits, information about credit usage. */ credits?: Events.ecomV1CheckoutMembershipPaymentCredits; /** * Optional - TMembership expiry date. */ expirationDate?: Date; /** * Line item IDs which are "paid" for by this membership. */ lineItemIds?: Array; /** * The name of this membership. */ name?: Events.ecomV1CheckoutMembershipName; }; type ecomV1CheckoutMembershipName = { /** * The name of this membership */ original?: string; /** * Optional - Translated name of this membership. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutMembershipOptions = { /** * List of payment options that can be used */ eligibleMemberships?: Array; /** * List of payment options that are owned by the member, but cannot be used due to reason provided */ invalidMemberships?: Array; /** * The selected payment options and which line items they apply to */ selectedMemberships?: Events.ecomV1CheckoutSelectedMemberships; }; type ecomV1CheckoutMembershipPaymentCredits = { /** * How much credit remained for this membership */ remaining?: number; /** * How much credit this membership has in total */ total?: number; }; type ecomV1CheckoutMerchantDiscount = { /** * Discount value. */ amount?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutMerchantDiscountInput = { /** * Discount amount. */ amount?: string; /** * IDs of line items the discount applies to. */ lineItemIds?: Array; }; type ecomV1CheckoutMultiCurrencyPrice = { /** * Amount. */ amount?: string; /** * Converted amount. */ convertedAmount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; /** * Converted amount formatted with currency symbol. */ formattedConvertedAmount?: string; }; type ecomV1CheckoutOptionSelection = { /** * Option name */ option?: string; /** * Selected choice for this option */ selection?: string; }; type ecomV1CheckoutOrderCreated = { /** * Order archive status */ archived?: boolean; /** * Customer information */ buyerInfo?: Events.ecomV1CheckoutV2BuyerInfo; /** * Currency used for pricing in this store */ currency?: string; /** * Order creation date */ dateCreated?: Date; /** * Order fulfillment status */ fulfillmentStatus?: string; /** * ID displayed in the owner's store (auto generated) */ number?: string; /** * Order ID (auto generated upon order creation) */ orderId?: string; /** * Order payment status */ paymentStatus?: string; /** * Whether the order was read by the store owner */ read?: boolean; /** * Totals for order's line items */ totals?: Events.ecomV1CheckoutTotals; /** * Weight unit used in this store */ weightUnit?: string; }; type ecomV1CheckoutOrdersExperiments = { epCommitTax?: boolean; moveBuyerOrderConfirmationEmailToEp?: boolean; moveMerchantEmailToEp?: boolean; producedByEpBridge?: boolean; }; type ecomV1CheckoutOtherCharge = { /** * Price of added cost. */ price?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Type of additional cost. */ type?: string; }; type ecomV1CheckoutPhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit (KG or LB) is taken from `order.weightUnit`. */ weight?: number; }; type ecomV1CheckoutPickupAddress = { /** * Address */ addressLine?: string; /** * City */ city?: string; /** * Country code (2 letters) */ country?: string; /** * State/District */ subdivision?: string; /** * ZIP/postal code */ zipCode?: string; }; type ecomV1CheckoutPickupDetails = { /** * Pickup address. */ address?: Events.ecomV1CheckoutApiAddress; /** * Whether the pickup address is that of a business - this may effect tax calculation. */ businessLocation?: boolean; /** * Pickup method */ pickupMethod?: string; }; type ecomV1CheckoutPlainTextValue = { /** * Optional - Description line plain text value in site's default language. */ original?: string; /** * Optional - Translated description line plain text value according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutPriceDescription = { /** * Required** - Original price description (in site's default language). */ original?: string; /** * Optional - Translated product name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutPriceSummary = { /** * Total additional fees price. */ additionalFees?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Total calculated discount value. */ discount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Total shipping price, before discounts and before tax. */ shipping?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Subtotal of all line items, before discounts and before tax. */ subtotal?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Total tax. */ tax?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Total price after discounts, gift cards, and tax. */ total?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutProductDetails = { /** * Line item fulfillerId from stores fulfillers. No value means self fulfilled */ fulfillerId?: string; /** * Line item type (may be extended) */ lineItemType?: string; /** * Line item primary media for preview */ mediaItem?: Events.ecomV1CheckoutMediaItem; /** * Line item name */ name?: string; /** * Line item notes */ notes?: string; /** * Line item product ID (optional for POS orders) */ productId?: string; /** * Line item SKU */ sku?: string; /** * Tax group id */ taxGroupId?: string; /** * Line item name translated to buyer's language */ translatedName?: string; /** * Line item weight */ weight?: number; }; type ecomV1CheckoutProductName = { /** * Required** - Original product name (in site's default language). */ original?: string; /** * Optional - Translated product name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1CheckoutRemoveCouponRequest = { /** * Checkout ID. */ _id: string; }; type ecomV1CheckoutRemoveCouponResponse = { /** * Updated checkout after removal of coupon. */ checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutRemoveGiftCardRequest = { /** * Checkout ID. */ _id: string; }; type ecomV1CheckoutRemoveGiftCardResponse = { /** * Updated checkout after removal of gift card. */ checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutRemoveLineItemsRequest = { /** * Checkout ID. */ _id: string; /** * IDs of line items to be removed. */ lineItemIds: Array; }; type ecomV1CheckoutRemoveLineItemsResponse = { /** * Updated checkout after removal of line items. */ checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutScope = { /** * Coupon scope's applied group (e.g., event or ticket in Wix Events) */ group?: Events.ecomV1CheckoutGroup; /** * Scope namespace (Wix Stores, Wix Bookings, Wix Events) */ namespace?: string; }; type ecomV1CheckoutSecuredMedia = { /** * Media ID in media manager. */ _id?: string; /** * Original file name. */ fileName?: string; /** * File type. */ fileType?: string; }; type ecomV1CheckoutSelectedCarrierServiceOption = { /** * This carrier's unique ID */ carrierId?: string; /** * Unique identifier of selected option. For example, "usps_std_overnight". */ code?: string; /** * Shipping costs. */ cost?: Events.ecomV1CheckoutSelectedCarrierServiceOptionPrices; /** * Delivery logistics. */ logistics?: Events.ecomV1CheckoutDeliveryLogistics; /** * Other charges */ otherCharges?: Array; /** * Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) */ requestedShippingOption?: boolean; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ecomV1CheckoutSelectedCarrierServiceOptionOtherCharge = { /** * Price of added charge. */ cost?: Events.ecomV1CheckoutSelectedCarrierServiceOptionPrices; /** * Details of the charge, such as 'Full Coverage Insurance of up to 80% of value of shipment'. */ details?: string; /** * Type of additional cost. */ type?: string; }; type ecomV1CheckoutSelectedCarrierServiceOptionPrices = { /** * Shipping price before discount and before tax. */ price?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Tax details. */ taxDetails?: Events.ecomV1CheckoutItemTaxFullDetails; /** * Shipping discount before tax. */ totalDiscount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Total shipping price, after discount and after tax. */ totalPriceAfterTax?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Totals shipping price after discount and before tax. */ totalPriceBeforeTax?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutSelectedMembership = { /** * Membership ID. */ _id?: string; /** * ID of the app providing this payment option. */ appId?: string; /** * IDs of the line items this membership applies to. */ lineItemIds?: Array; }; type ecomV1CheckoutSelectedMemberships = { /** * Selected memberships. */ memberships?: Array; }; type ecomV1CheckoutServiceProperties = { /** * Optional - The number of people participating in this service. For example, the number of people attending the class or the number of people per hotel room. */ numberOfParticipants?: number; /** * Optional - The date and time for which the service is supposed to be provided. For example, the time of the class. */ scheduledDate?: Date; }; type ecomV1CheckoutShipmentDetails = { /** * Shipping destination address */ address?: Events.ecomV1CheckoutAddress; /** * Discount applied for shipping */ discount?: number; /** * Tax applied for shipping */ tax?: number; /** * Whether tax is included in the price */ taxIncludedInPrice?: boolean; }; type ecomV1CheckoutShippingInfo = { /** * All carrier options for this shipping rule. */ carrierServiceOptions?: Array; /** * Shipping region. */ region?: Events.ecomV1CheckoutShippingRegion; /** * Selected option out of the options allowed for the region (see `region` field). * The region field is chosen based on the address provided. */ selectedCarrierServiceOption?: Events.ecomV1CheckoutSelectedCarrierServiceOption; /** * Shipping address and contact details. */ shippingDestination?: Events.ecomV1CheckoutAddressWithContact; }; type ecomV1CheckoutShippingOption = { /** * Unique code of provided shipping option like "usps_std_overnight". * For legacy calculators this would be the UUID of the option. */ code?: string; /** * Sipping price information. */ cost?: Events.ecomV1CheckoutShippingPrice; /** * Delivery logistics. */ logistics?: Events.ecomV1CheckoutDeliveryLogistics; /** * Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). * For example, "Standard" or "First-Class Package International". */ title?: string; }; type ecomV1CheckoutShippingPrice = { /** * Other costs such as insurance, handling & packaging for fragile items, etc. */ otherCharges?: Array; /** * Shipping price. */ price?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutShippingRegion = { /** * Shipping region ID. */ _id?: string; /** * Shipping region name. */ name?: string; }; type ecomV1CheckoutStoreSettings = { /** * The language to be used when communicating with the buyer * For a site that support multiple languages, this would be the language the buyer selected * Otherwise this would be the site language */ buyerLanguage?: string; /** * Currency used for pricing in this store */ currency?: string; /** * Weight unit used in this store */ weightUnit?: string; }; type ecomV1CheckoutStreet = { /** * Street name */ name?: string; /** * Street number */ number?: string; }; type ecomV1CheckoutStreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type ecomV1CheckoutSubscription = { /** * Subscription id (auto-generated upon subscription creation) */ _id?: string; /** * Coupon that was applied to subscription */ appliedCoupon?: Events.ecomV1CheckoutV1AppliedCoupon; /** * Full billing address */ billingAddress?: Events.ecomV1CheckoutAddress; /** * information about first subscription payment */ billingInfo?: Events.ecomV1CheckoutV1BillingInfo; /** * member or contact */ buyerInfo?: Events.ecomV1CheckoutV1BuyerInfo; /** * Message from the customer (e.g., customization request) */ buyerNote?: string; /** * The id of the cart this order was created from */ cartId?: string; /** * Sales channel that submitted this subscription */ channelInfo?: Events.ecomV1CheckoutChannelInfo; /** * The id of the checkout this subscriptions was created from */ checkoutId?: string; /** * Custom field */ customField?: Events.ecomV1CheckoutV1CustomField; /** * Subscription creation date */ dateCreated?: Date; /** * id of subscription in external system */ externalId?: string; /** * Line items ordered */ lineItems?: Array; /** * Delivery information */ shippingInfo?: Events.ecomV1CheckoutV1ShippingInfo; /** * site settings at the moment when subscription created */ storeSettings?: Events.ecomV1CheckoutStoreSettings; /** * Information about subscription option from which subscription was created */ subscriptionOptionInfo?: Events.ecomV1CheckoutV1SubscriptionOptionInfo; /** * defines when subscriber will be charged: for frequency=MONTH, billingCycles=6, interval=2 payment will be done every 2 month during one year */ subscriptionSettings?: Events.ecomV1CheckoutV1SubscriptionSettings; /** * Totals for subscription's line items */ totals?: Events.ecomV1CheckoutV1Totals; }; type ecomV1CheckoutSubscriptionCreated = { subscription?: Events.ecomV1CheckoutSubscription; }; type ecomV1CheckoutSubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Current cycle number. For example, if the subscription is in the 3rd month of a 4-month subscription, the value will be `3`. */ cycleNumber?: number; /** * Subscription options info. */ subscriptionOptionInfo?: Events.ecomV1CheckoutV2SubscriptionOptionInfo; /** * Subscription settings. */ subscriptionSettings?: Events.ecomV1CheckoutV1SubscriptionSettings; }; type ecomV1CheckoutSubscriptionOptionInfo = { /** * Subscription option description. */ description?: Events.ecomV1CheckoutDescription; /** * Subscription option settings. */ subscriptionSettings?: Events.ecomV1CheckoutSubscriptionSettings; /** * Subscription option title. */ title?: Events.ecomV1CheckoutTitle; }; type ecomV1CheckoutSubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type ecomV1CheckoutTaxCalculationDetails = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Events.ecomV1CheckoutAutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; /** * Rate calculation type. */ rateType?: string; }; type ecomV1CheckoutTaxCalculationDetailsCalculationDetailsOneOf = { /** * Details of the fallback rate calculation. */ autoTaxFallbackDetails?: Events.ecomV1CheckoutAutoTaxFallbackCalculationDetails; /** * Reason the manual calculation was used. */ manualRateReason?: string; }; type ecomV1CheckoutTaxRateBreakdown = { /** * Type of tax against which the calculation was performed. */ name?: string; /** * Rate at which this tax detail was calculated. */ rate?: string; /** * Amount of tax for this tax detail. */ tax?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutTaxSummary = { /** * Tax calculator that was active when the order was created. */ calculationDetails?: Events.ecomV1CheckoutTaxCalculationDetails; /** * Amount for which tax is calculated, added from line items. */ taxableAmount?: Events.ecomV1CheckoutMultiCurrencyPrice; /** * Calculated tax, added from line items. */ totalTax?: Events.ecomV1CheckoutMultiCurrencyPrice; }; type ecomV1CheckoutTitle = { /** * Subscription option name. */ original?: string; /** * Translated subscription option name. */ translated?: string; }; type ecomV1CheckoutTotals = { /** * Total calculated discount value. */ discount?: string; /** * Total calculated gift card value. */ giftCard?: string; /** * Total number of line items. */ quantity?: number; /** * Total refund. */ refund?: string; /** * Total shipping price, before tax. */ shipping?: string; /** * Subtotal of all the line items, before tax. */ subtotal?: string; /** * Total tax. */ tax?: string; /** * Total price charged. */ total?: string; /** * Total items weight. */ weight?: string; }; type ecomV1CheckoutUpdateCheckoutRequest = { /** * Checkout information. */ checkout: Events.ecomV1CheckoutCheckout; /** * Coupon code. */ couponCode?: string; /** * Gift card code. */ giftCardCode?: string; /** * Merchant discounts to apply to specific line items. If no `lineItemIds` are passed, the discount will be applied to the whole checkout. */ merchantDiscounts?: Array; }; type ecomV1CheckoutUpdateCheckoutResponse = { /** * Updated checkout. */ checkout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutUpdatedCheckoutMessage = { /** * Previous checkout. */ oldCheckout?: Events.ecomV1CheckoutCheckout; /** * Updated checkout. */ updatedCheckout?: Events.ecomV1CheckoutCheckout; }; type ecomV1CheckoutV1AppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type ecomV1CheckoutV1BillingInfo = { /** * Order ID from payment gateway (e.g., Wix Payments) */ paymentGatewayOrderId?: string; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; }; type ecomV1CheckoutV1BuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer type */ identityType?: string; }; type ecomV1CheckoutV1CustomField = { /** * Title for the custom field */ title?: string; /** * The title translated according to the buyer language */ translatedTitle?: string; /** * Free text that the customer entered in the custom field during the checkout process */ value?: string; }; type ecomV1CheckoutV1LineItem = { /** * Charges details */ chargeDetails?: Events.ecomV1CheckoutChargeDetails; /** * Line item custom text field selections */ customTextFields?: Array; /** * Line item ID (auto-generated) */ index?: number; /** * Line item options ordered */ options?: Array; /** * Product details */ productDetails?: Events.ecomV1CheckoutProductDetails; /** * Line item quantity */ quantity?: number; /** * Line item variantId (from Stores Catalog) */ variantId?: string; }; type ecomV1CheckoutV1PickupDetails = { /** * Pickup address */ address?: Events.ecomV1CheckoutPickupAddress; /** * Store owner's pickup instructions */ pickupInstructions?: string; }; type ecomV1CheckoutV1ShippingInfo = { /** * Delivery option name */ deliveryOption?: string; /** * Delivery option delivery time */ estimatedDeliveryTime?: string; /** * Pickup details (when this object describes pickup) */ pickupDetails?: Events.ecomV1CheckoutV1PickupDetails; /** * Shipment details (when this object describes shipment) */ shipmentDetails?: Events.ecomV1CheckoutShipmentDetails; }; type ecomV1CheckoutV1ShippingInfoDetailsOneOf = { /** * Pickup details (when this object describes pickup) */ pickupDetails?: Events.ecomV1CheckoutV1PickupDetails; /** * Shipment details (when this object describes shipment) */ shipmentDetails?: Events.ecomV1CheckoutShipmentDetails; }; type ecomV1CheckoutV1SubscriptionOptionInfo = { _id?: string; description?: string; discount?: Events.ecomV1CheckoutDiscount; title?: string; }; type ecomV1CheckoutV1SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type ecomV1CheckoutV1Totals = { /** * Total calculated discount value */ discount?: number; /** * Total line items quantity */ quantity?: number; /** * Total shipping price, including tax */ shipping?: number; /** * Subtotal of all line items, before tax */ subtotal?: number; /** * Total tax */ tax?: number; /** * Total price */ total?: number; /** * Total weight */ weight?: number; }; type ecomV1CheckoutV2BuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer type */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; /** * Deprecated (use identityType instead) */ type?: string; }; type ecomV1CheckoutV2SubscriptionOptionInfo = { /** * Subscription option description. */ description?: string; /** * Subscription option title. */ title?: string; }; type ecomV1CheckoutValidationError = { fieldViolations?: Array; }; type ecomV1CheckoutVatId = { /** * Customer's tax ID */ number?: string; /** * tax type */ type?: string; }; type ecomV1FulfillmentsBackendEventMetadata = { entityId: string; eventTime: string; id: string; triggeredByAnonymizeRequest: boolean; }; type ecomV1FulfillmentsBuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer type */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; /** * Deprecated (use identityType instead) */ type?: string; }; type ecomV1FulfillmentsCreateFulfillmentRequest = { /** * Fulfillment info. */ fulfillment: Events.ecomV1FulfillmentsFulfillment; /** * Order ID. */ orderId: string; }; type ecomV1FulfillmentsCreateFulfillmentResponse = { /** * ID of created fulfillment. */ fulfillmentId?: string; /** * Order ID and the orders' fulfillments. */ orderWithFulfillments?: Events.ecomV1FulfillmentsOrderWithFulfillments; }; type ecomV1FulfillmentsDeleteFulfillmentRequest = { /** * IDs of fulfillments to delete. */ fulfillmentId: string; /** * Order ID. */ orderId: string; }; type ecomV1FulfillmentsDeleteFulfillmentResponse = { /** * Order ID and the orders' associated fulfillments after deletion. */ orderWithFulfillments?: Events.ecomV1FulfillmentsOrderWithFulfillments; }; type ecomV1FulfillmentsFulfillment = { /** * Fulfillment creation date and time. */ _createdDate?: Date; /** * Fulfillment ID. */ _id?: string; /** * Line items being fulfilled. */ lineItems?: Array; /** * Fulfillment tracking info. */ trackingInfo?: Events.ecomV1FulfillmentsFulfillmentTrackingInfo; }; type ecomV1FulfillmentsFulfillmentCreated = { /** * Buyer information. */ buyerInfo?: Events.ecomV1FulfillmentsBuyerInfo; /** * Fulfillment creation date and time. */ dateCreated?: Date; /** * ID of the newly created fulfillment. */ fulfillmentId?: string; /** * Order fulfillment status. */ fulfillmentStatus?: string; /** * Order ID (auto generated upon order creation). */ orderId?: string; /** * Fulfillment tracking information. */ trackingInfo?: Events.ecomV1FulfillmentsV2FulfillmentTrackingInfo; }; type ecomV1FulfillmentsFulfillmentDeleted = { /** * ID of the deleted fulfillment. */ fulfillmentId?: string; /** * Order fulfillment status. */ fulfillmentStatus?: string; /** * Order ID (auto generated upon order creation). */ orderId?: string; }; type ecomV1FulfillmentsFulfillmentLineItem = { /** * Line item ID (mirrors the ID of the order line item). */ _id?: string; /** * Line item quantity. * * On creation, if this parameter isn't passed, the new fulfillment will automatically include all items of this line item that have not already been linked to a fulfillment. * * If the order does not have the requested quantity of line items available to add to this fulfillment, the fulfillment will not be created and an error will be returned. * * This property will always have a value when returned. */ quantity?: number; }; type ecomV1FulfillmentsFulfillmentTrackingInfo = { /** * Shipping provider. Using the following shipping providers will allow for auto-filling the tracking link: * * `fedex` * * `ups` * * `usps` * * `dhl` * * `canadaPost` */ shippingProvider?: string; /** * Tracking link - auto-filled if using a predefined shipping provider, otherwise provided on creation. */ trackingLink?: string; /** * Tracking number. */ trackingNumber?: string; }; type ecomV1FulfillmentsFulfillmentUpdated = { /** * ID of the updated fulfillment. */ fulfillmentId?: string; /** * Order ID (auto generated upon order creation). */ orderId?: string; /** * Fulfillment tracking information. */ trackingInfo?: Events.ecomV1FulfillmentsV2FulfillmentTrackingInfo; }; type ecomV1FulfillmentsFulfillmentsUpdated = { entity: Events.ecomV1FulfillmentsOrderWithFulfillments; metadata: Events.ecomV1FulfillmentsBackendEventMetadata; }; type ecomV1FulfillmentsIndexingMessage = { _id?: string; opType?: number; requiredVersions?: Array; }; type ecomV1FulfillmentsListFulfillmentsForMultipleOrdersRequest = { /** * Order IDs for which to retrieve fulfillments. */ orderIds: Array; }; type ecomV1FulfillmentsListFulfillmentsForMultipleOrdersResponse = { /** * List of order IDs and their associated fulfillments. */ ordersWithFulfillments?: Array; }; type ecomV1FulfillmentsListFulfillmentsForSingleOrderRequest = { /** * Order ID for which to retrieve fulfillments. */ orderId: string; }; type ecomV1FulfillmentsListFulfillmentsForSingleOrderResponse = { /** * List of fulfillments associated with the order. */ orderWithFulfillments?: Events.ecomV1FulfillmentsOrderWithFulfillments; }; type ecomV1FulfillmentsOrderWithFulfillments = { /** * Fulfillments associated with the order. */ fulfillments?: Array; /** * Order ID. */ orderId?: string; }; type ecomV1FulfillmentsSnapshotMessage = { _id?: string; opType?: number; }; type ecomV1FulfillmentsUpdateFulfillmentRequest = { /** * Set of fields to update. Fields that aren't included in `fieldMask.paths` are ignored. */ fieldMask?: Array; /** * Fulfillment info to update. */ fulfillment?: Events.ecomV1FulfillmentsFulfillment; /** * Order ID. */ orderId: string; }; type ecomV1FulfillmentsUpdateFulfillmentResponse = { /** * Order ID and the orders' associated fulfillments after update. */ orderWithFulfillments?: Events.ecomV1FulfillmentsOrderWithFulfillments; }; type ecomV1FulfillmentsV2FulfillmentTrackingInfo = { /** * Shipping provider. Using the following shipping providers will allow for autofilling the tracking link: * * `fedex` * * `ups` * * `usps` * * `dhl` * * `canadaPost` */ shippingProvider?: string; /** * Tracking link - autofilled if using a predefined shipping provider, otherwise provided on creation. */ trackingLink?: string; /** * Tracking number. */ trackingNumber?: string; }; type ecomV1OrderActionEvent = { bodyAsJson?: string; }; type ecomV1OrderActivity = { /** * Activity creation date and time. */ _createdDate?: Date; /** * Activity ID. */ _id?: string; /** * Activity author's email. */ authorEmail?: string; /** * Custom activity details (optional). `activity.type` must be `CUSTOM_ACTIVITY`. */ customActivity?: Events.ecomV1OrderCustomActivity; /** * Merchant comment details (optional). `activity.type` must be `MERCHANT_COMMENT`. */ merchantComment?: Events.ecomV1OrderMerchantComment; /** * Additional info about order refunded activity (optional). `activity.type` must be `ORDER_REFUNDED`. */ orderRefunded?: Events.ecomV1OrderOrderRefunded; /** * Activity type. */ type?: string; }; type ecomV1OrderActivityContentOneOf = { /** * Custom activity details (optional). `activity.type` must be `CUSTOM_ACTIVITY`. */ customActivity?: Events.ecomV1OrderCustomActivity; /** * Merchant comment details (optional). `activity.type` must be `MERCHANT_COMMENT`. */ merchantComment?: Events.ecomV1OrderMerchantComment; /** * Additional info about order refunded activity (optional). `activity.type` must be `ORDER_REFUNDED`. */ orderRefunded?: Events.ecomV1OrderOrderRefunded; }; type ecomV1OrderAddActivityRequest = { /** * Order ID. */ _id: string; /** * Activity info. */ activity: Events.ecomV1OrderPublicActivity; }; type ecomV1OrderAddActivityResponse = { /** * ID of the added activity. * Use this ID to either [update](https://bo.wix.com/wix-docs/rest/ecommerce/orders/update-activity) or [delete](https://bo.wix.com/wix-docs/rest/ecommerce/orders/delete-activity) the activity. */ activityId?: string; /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderAddInternalActivityRequest = { /** * Order ID. */ _id: string; /** * Activity info. */ activity: Events.ecomV1OrderInternalActivity; }; type ecomV1OrderAddInternalActivityResponse = { /** * ID of the added internal activity. * Use this ID to either [update](https://bo.wix.com/wix-docs/rest/ecommerce/orders/update-activity) or [delete](https://bo.wix.com/wix-docs/rest/ecommerce/orders/delete-activity) the activity. */ activityId?: string; /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderAdditionalFee = { /** * Additional fee's unique code for future processing. */ code?: string; /** * Name of additional fee. */ name?: string; /** * Additional fee's price. */ price?: Events.ecomV1OrderPrice; /** * SPI implementer's `appId`. */ providerAppId?: string; /** * Tax details. */ taxDetails?: Events.ecomV1OrderItemTaxFullDetails; }; type ecomV1OrderAddress = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Events.ecomV1OrderStreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type ecomV1OrderAddressWithContact = { /** * Address. */ address?: Events.ecomV1OrderAddress; /** * Contact details. */ contactDetails?: Events.ecomV1OrderFullAddressContactDetails; }; type ecomV1OrderAggregateOrdersRequest = { /** * This is an object defining aggregation itself */ aggregation: Object; /** * Filter applied to original data */ filter?: Object; }; type ecomV1OrderAggregateOrdersResponse = { aggregates?: Object; }; type ecomV1OrderApiAddress = { /** * Address line 1 (free text) */ addressLine1?: string; /** * address line */ addressLine2?: string; /** * City name */ city?: string; /** * Company name */ company?: string; /** * Country code (2 letters) */ country?: string; /** * Email address */ email?: string; /** * Addressee name */ fullName?: Events.ecomV1OrderFullName; /** * Phone number */ phone?: string; /** * Address line 1 (street) */ street?: Events.ecomV1OrderStreet; /** * State or district */ subdivision?: string; /** * Tax information (for Brazil only) */ vatId?: Events.ecomV1OrderApiVatId; /** * ZIP/postal code */ zipCode?: string; }; type ecomV1OrderApiAddressAddressLine1OptionsOneOf = { /** * Address line 1 (free text) */ addressLine1?: string; /** * Address line 1 (street) */ street?: Events.ecomV1OrderStreet; }; type ecomV1OrderApiVatId = { /** * Customer's tax ID */ number?: string; /** * tax type */ type?: string; }; type ecomV1OrderApplicationError = { code?: string; data?: Object; description?: string; }; type ecomV1OrderAppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type ecomV1OrderAppliedDiscount = { /** * Applied coupon info. */ coupon?: Events.ecomV1OrderCoupon; /** * Automatic Discount */ discountRule?: Events.ecomV1OrderDiscountRule; /** * Discount type. * * `"GLOBAL"` - discount applies to entire order. * * `"SPECIFIC-ITEMS"` - discount applies to specific items. * * `"SHIPPING"` - discount applies to shipping. For example, free shipping. */ discountType?: string; /** * IDs of line items discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1OrderMerchantDiscount; }; type ecomV1OrderAppliedDiscountDiscountSourceOneOf = { /** * Applied coupon info. */ coupon?: Events.ecomV1OrderCoupon; /** * Automatic Discount */ discountRule?: Events.ecomV1OrderDiscountRule; /** * Merchant discount. */ merchantDiscount?: Events.ecomV1OrderMerchantDiscount; }; type ecomV1OrderArchiveOrderRequest = { /** * Order ID. */ _id: string; }; type ecomV1OrderArchiveOrderResponse = { /** * Archived order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderBackendEventMetadata = { entityId: string; eventTime: string; id: string; triggeredByAnonymizeRequest: boolean; }; type ecomV1OrderBalance = { /** * Balance amount, can be negative. Negative value signifies amount to be refunded * and can happen due to possible overcharge or modified manual order. */ amount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; }; type ecomV1OrderBalanceSummary = { balance?: Events.ecomV1OrderBalance; }; type ecomV1OrderBillingInfo = { /** * Full billing address */ address?: Events.ecomV1OrderApiAddress; /** * Deprecated (use paymentProviderTransactionId instead) */ externalTransactionId?: string; /** * Payment date */ paidDate?: Date; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; /** * Transaction ID from payment provider (e.g., PayPal, Square, Stripe) transaction ID */ paymentProviderTransactionId?: string; /** * Whether order can be refunded by payment provider (manually or automatic) */ refundableByPaymentProvider?: boolean; }; type ecomV1OrderBulkActionMetadata = { /** * Number of items that couldn't be processed. */ totalFailures?: number; /** * Number of items that were successfully processed. */ totalSuccesses?: number; /** * Number of failures without details because detailed failure threshold was exceeded. */ undetailedFailures?: number; }; type ecomV1OrderBulkArchiveOrdersByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type ecomV1OrderBulkArchiveOrdersByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkArchiveOrdersRequest = { /** * IDs of orders to archive. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type ecomV1OrderBulkArchiveOrdersResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkMarkAsFulfilledByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type ecomV1OrderBulkMarkAsFulfilledByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkMarkAsFulfilledRequest = { /** * IDs of orders to be marked as fulfilled. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type ecomV1OrderBulkMarkAsFulfilledResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkMarkAsUnfulfilledByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type ecomV1OrderBulkMarkAsUnfulfilledByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkMarkAsUnfulfilledRequest = { /** * IDs of orders to be marked as not fulfilled. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type ecomV1OrderBulkMarkAsUnfulfilledResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkMarkOrdersAsPaidRequest = { /** * IDs of orders to mark as paid. */ ids: Array; }; type ecomV1OrderBulkMarkOrdersAsPaidResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by the bulk action. * The Order entity within the results optimistically changes its payment status to paid, however this process is async. */ results?: Array; }; type ecomV1OrderBulkOrderResult = { /** * Updated item. Optional - returned only if requested with `return_full_entity` set to `true`. */ item?: Events.ecomV1OrderOrder; /** * Item metadata. */ itemMetadata?: Events.ecomV1OrderItemMetadata; }; type ecomV1OrderBulkUnArchiveOrdersByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type ecomV1OrderBulkUnArchiveOrdersByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBulkUnArchiveOrdersRequest = { /** * IDs or orders to unarchive. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type ecomV1OrderBulkUnArchiveOrdersResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Events.ecomV1OrderBulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type ecomV1OrderBuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction). */ contactId?: string; /** * Buyer email address. */ email?: string; /** * Member ID (if site visitor is a site member). */ memberId?: string; /** * Visitor ID (if site visitor is not a member). */ visitorId?: string; }; type ecomV1OrderBuyerInfoIdOneOf = { /** * Member ID (if site visitor is a site member). */ memberId?: string; /** * Visitor ID (if site visitor is not a member). */ visitorId?: string; }; type ecomV1OrderBuyerInfoUpdate = { /** * Contact ID. */ contactId?: string; /** * Email associated with the buyer. */ email?: string; }; type ecomV1OrderCancel = {}; type ecomV1OrderCancelOrderRequest = { /** * Order ID. */ _id: string; /** * Custom note to be added to the email (optional). */ customMessage?: string; /** * Whether to restock all items in the order. */ restockAllItems?: boolean; /** * Whether to send an order canceled email to the buyer. */ sendOrderCanceledEmail?: boolean; }; type ecomV1OrderCancelOrderResponse = { /** * Canceled order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderCatalogReference = { /** * ID of the catalog app. For example, the Wix Stores `appId`, or the 3rd-party `appId`. */ appId?: string; /** * ID of the item within its Wix or 3rd-party catalog. For example, `productId` for Wix Stores or `eventId` for Wix Events. */ catalogItemId?: string; /** * Additional info in key:value form. For example, `{"options":{"Size": "M", "Color": "Red"}}` or `{"variantId": ""}`. */ options?: Object; }; type ecomV1OrderChannelInfo = { /** * Reference to an order ID from an external system. */ externalOrderId?: string; /** * URL to the order in the external system. */ externalOrderUrl?: string; /** * Sales channel that submitted the order. */ type?: string; }; type ecomV1OrderColor = { /** * Optional - HEX or RGB color code for display. */ code?: string; /** * Optional - Description line color name in site's default language. */ original?: string; /** * Optional - Translated description line color name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderComplete = {}; type ecomV1OrderContinueSideEffectsFlowInLegacyData = { orderId?: string; ordersExperiments?: Events.ecomV1OrderOrdersExperiments; storeId?: string; }; type ecomV1OrderCoupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: Events.ecomV1OrderPrice; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type ecomV1OrderCreateOrderRequest = { /** * Order info. */ order: Events.ecomV1OrderOrder; }; type ecomV1OrderCreateOrderResponse = { /** * Newly created order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderCreatePaymentGatewayOrderRequest = { /** * eCom Order ID */ ecomOrderId: string; }; type ecomV1OrderCreatePaymentGatewayOrderResponse = { /** * ID of the order created in the payment gateway */ paymentGatewayOrderId?: string; }; type ecomV1OrderCreatedBy = { /** * App ID - when the order was created by an external application. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type ecomV1OrderCreatedByStringOneOf = { /** * App ID - when the order was created by an external application. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type ecomV1OrderCursorPaging = { /** * Pointer to the next or previous page in the list of results. */ cursor?: string; /** * Number of items to load. */ limit?: number; }; type ecomV1OrderCursors = { /** * Cursor pointing to next page in the list of results. */ next?: string; /** * Cursor pointing to previous page in the list of results. */ prev?: string; }; type ecomV1OrderCustomActivity = { /** * Additional data in key-value form. For example, `{ "Ticket number": "123456" }`. */ additionalData?: Record; /** * ID of the app that created the custom activity. */ appId?: string; /** * Custom activity type. For example, `"Ticket number set"`. */ type?: string; }; type ecomV1OrderCustomField = { /** * Custom field title. */ title?: string; /** * Translated custom field title. */ translatedTitle?: string; /** * Custom field value. */ value?: any; }; type ecomV1OrderDecrementData = { /** * Line item quantity being decremented. */ decrementBy?: number; /** * ID of the line item being decremented. */ lineItemId?: string; /** * Whether to restock the line item (triggers inventory update). */ restock?: boolean; }; type ecomV1OrderDecrementItemsQuantityRequest = { /** * Order ID */ _id: string; /** * Which items to decrement, and how much to decrement from each one */ decrementData: Array; }; type ecomV1OrderDecrementItemsQuantityResponse = { /** * Updated order data */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderDeleteActivityRequest = { /** * Order ID. */ _id: string; /** * ID of the activity to delete. */ activityId: string; }; type ecomV1OrderDeleteActivityResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderDeliveryLogistics = { /** * Latest expected delivery date. */ deliverByDate?: Date; /** * Expected delivery time in free text. For example, `"3-5 business days"`. */ deliveryTime?: string; /** * Instructions for carrier. For example, `"Please knock on the door. If unanswered, please call contact number. Thanks."`. */ instructions?: string; /** * Pickup details. */ pickupDetails?: Events.ecomV1OrderPickupDetails; /** * Shipping address and contact details. */ shippingDestination?: Events.ecomV1OrderAddressWithContact; }; type ecomV1OrderDeliveryLogisticsAddressOneOf = { /** * Pickup details. */ pickupDetails?: Events.ecomV1OrderPickupDetails; /** * Shipping address and contact details. */ shippingDestination?: Events.ecomV1OrderAddressWithContact; }; type ecomV1OrderDescriptionLine = { /** * Description line color value. */ colorInfo?: Events.ecomV1OrderColor; /** * Description line name. */ name?: Events.ecomV1OrderDescriptionLineName; /** * Description line plain text value. */ plainText?: Events.ecomV1OrderPlainTextValue; }; type ecomV1OrderDescriptionLineDescriptionLineValueOneOf = {}; type ecomV1OrderDescriptionLineName = { /** * Optional - Description line name in site's default language. */ original?: string; /** * Optional - Translated description line item according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderDescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: Events.ecomV1OrderColor; /** * Description line plain text value. */ plainText?: Events.ecomV1OrderPlainTextValue; }; type ecomV1OrderDiffmatokyPayload = { compareChannel?: string; entityId?: string; errorInformation?: Events.ecomV1OrderErrorInformation; left?: string; right?: string; tags?: Array; }; type ecomV1OrderDigitalFile = { /** * Link expiration time and date. */ expirationDate?: Date; /** * ID of the secure file in media. */ fileId?: string; /** * Link will exist after the digital links have been generated on the order. */ link?: string; }; type ecomV1OrderDiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: Events.ecomV1OrderPrice; /** * Discount rule name */ name?: Events.ecomV1OrderDiscountRuleName; }; type ecomV1OrderDiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderDomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Events.ecomV1OrderActionEvent; createdEvent?: Events.ecomV1OrderEntityCreatedEvent; deletedEvent?: Events.ecomV1OrderEntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Events.ecomV1OrderExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Events.ecomV1OrderEntityUpdatedEvent; }; type ecomV1OrderDomainEventBodyOneOf = { actionEvent?: Events.ecomV1OrderActionEvent; createdEvent?: Events.ecomV1OrderEntityCreatedEvent; deletedEvent?: Events.ecomV1OrderEntityDeletedEvent; extendedFieldsUpdatedEvent?: Events.ecomV1OrderExtendedFieldsUpdatedEvent; updatedEvent?: Events.ecomV1OrderEntityUpdatedEvent; }; type ecomV1OrderDownloadLinkSent = {}; type ecomV1OrderEmailEdited = {}; type ecomV1OrderEmpty = {}; type ecomV1OrderEntityCreatedEvent = { entityAsJson?: string; }; type ecomV1OrderEntityDeletedEvent = {}; type ecomV1OrderEntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type ecomV1OrderErrorInformation = { stackTrace?: string; }; type ecomV1OrderExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type ecomV1OrderFulfillerEmailSent = {}; type ecomV1OrderFulfillmentStatusUpdated = { /** * the action that caused this update */ action?: string; /** * the new status (after the update) */ newFulfillmentStatus?: string; /** * The order that was updated */ order?: Events.ecomV1OrderOrder; /** * The previous status (before the update) */ previousFulfillmentStatus?: string; }; type ecomV1OrderFullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: Events.ecomV1OrderVatId; }; type ecomV1OrderFullName = { /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; }; type ecomV1OrderGetOrderRequest = { /** * ID of the order to retrieve. */ _id: string; }; type ecomV1OrderGetOrderResponse = { /** * The requested order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderGetPaymentCollectabilityStatusRequest = { /** * Ecom order ID. */ ecomOrderId: string; }; type ecomV1OrderGetPaymentCollectabilityStatusResponse = { /** * Collectable order amount */ amount?: Events.ecomV1OrderPrice; /** * Payment collectability status */ status?: string; }; type ecomV1OrderGetShipmentsRequest = { _id: string; }; type ecomV1OrderGetShipmentsResponse = { shipmentIds?: Array; }; type ecomV1OrderIndexingMessage = { _id?: string; opType?: number; requiredVersions?: Array; }; type ecomV1OrderInternalActivity = { /** * Internal activity creation date and time. */ _createdDate?: Date; /** * Internal activity ID. */ _id?: string; /** * Internal activity author's email. */ authorEmail?: string; /** * Download link was sent (relevant for orders with digital line items). */ downloadLinkSent?: Events.ecomV1OrderDownloadLinkSent; /** * Order email was updated. */ emailEdited?: Events.ecomV1OrderEmailEdited; /** * Email sent to fulfiller. */ fulfillerEmailSent?: Events.ecomV1OrderFulfillerEmailSent; /** * Invoice was added to order. */ invoiceAdded?: Events.ecomV1OrderInvoiceAdded; /** * Invoice sent to customer via email. */ invoiceSent?: Events.ecomV1OrderInvoiceSent; /** * New exchange order created. */ newExchangeOrderCreated?: Events.ecomV1OrderNewExchangeOrderCreated; /** * Order canceled. */ orderCanceled?: Events.ecomV1OrderOrderCanceled; /** * Order created as a result of items exchange. */ orderCreatedFromExchange?: Events.ecomV1OrderOrderCreatedFromExchange; /** * Order shipping status set as fulfilled. */ orderFulfilled?: Events.ecomV1OrderOrderFulfilled; /** * Order shipping status set as not fulfilled. */ orderNotFulfilled?: Events.ecomV1OrderOrderNotFulfilled; /** * Order paid. Either by the store owner (for offline orders), or when an online transaction was confirmed. */ orderPaid?: Events.ecomV1OrderOrderPaid; /** * Order partially paid. During the checkout for orders with deposit items. */ orderPartiallyPaid?: Events.ecomV1OrderOrderPartiallyPaid; /** * Order placed. */ orderPlaced?: Events.ecomV1OrderOrderPlaced; /** * Order refunded. */ orderRefunded?: Events.ecomV1OrderOrderRefunded; /** * Email notification for pickup sent. */ pickupReadyEmailSent?: Events.ecomV1OrderPickupReadyEmailSent; /** * Shipping address was updated. */ shippingAddressEdited?: Events.ecomV1OrderShippingAddressEdited; /** * An email confirmation of order shipment was sent. */ shippingConfirmationEmailSent?: Events.ecomV1OrderShippingConfirmationEmailSent; /** * Shipping tracking link added to order. */ trackingLinkAdded?: Events.ecomV1OrderTrackingLinkAdded; /** * Shipping tracking number added to order. */ trackingNumberAdded?: Events.ecomV1OrderTrackingNumberAdded; /** * Shipping tracking number was edited. */ trackingNumberEdited?: Events.ecomV1OrderTrackingNumberEdited; }; type ecomV1OrderInternalActivityContentOneOf = { /** * Download link was sent (relevant for orders with digital line items). */ downloadLinkSent?: Events.ecomV1OrderDownloadLinkSent; /** * Order email was updated. */ emailEdited?: Events.ecomV1OrderEmailEdited; /** * Email sent to fulfiller. */ fulfillerEmailSent?: Events.ecomV1OrderFulfillerEmailSent; /** * Invoice was added to order. */ invoiceAdded?: Events.ecomV1OrderInvoiceAdded; /** * Invoice sent to customer via email. */ invoiceSent?: Events.ecomV1OrderInvoiceSent; /** * New exchange order created. */ newExchangeOrderCreated?: Events.ecomV1OrderNewExchangeOrderCreated; /** * Order canceled. */ orderCanceled?: Events.ecomV1OrderOrderCanceled; /** * Order created as a result of items exchange. */ orderCreatedFromExchange?: Events.ecomV1OrderOrderCreatedFromExchange; /** * Order shipping status set as fulfilled. */ orderFulfilled?: Events.ecomV1OrderOrderFulfilled; /** * Order shipping status set as not fulfilled. */ orderNotFulfilled?: Events.ecomV1OrderOrderNotFulfilled; /** * Order paid. Either by the store owner (for offline orders), or when an online transaction was confirmed. */ orderPaid?: Events.ecomV1OrderOrderPaid; /** * Order partially paid. During the checkout for orders with deposit items. */ orderPartiallyPaid?: Events.ecomV1OrderOrderPartiallyPaid; /** * Order placed. */ orderPlaced?: Events.ecomV1OrderOrderPlaced; /** * Order refunded. */ orderRefunded?: Events.ecomV1OrderOrderRefunded; /** * Email notification for pickup sent. */ pickupReadyEmailSent?: Events.ecomV1OrderPickupReadyEmailSent; /** * Shipping address was updated. */ shippingAddressEdited?: Events.ecomV1OrderShippingAddressEdited; /** * An email confirmation of order shipment was sent. */ shippingConfirmationEmailSent?: Events.ecomV1OrderShippingConfirmationEmailSent; /** * Shipping tracking link added to order. */ trackingLinkAdded?: Events.ecomV1OrderTrackingLinkAdded; /** * Shipping tracking number added to order. */ trackingNumberAdded?: Events.ecomV1OrderTrackingNumberAdded; /** * Shipping tracking number was edited. */ trackingNumberEdited?: Events.ecomV1OrderTrackingNumberEdited; }; type ecomV1OrderInvoiceAdded = {}; type ecomV1OrderInvoiceSent = {}; type ecomV1OrderItemMetadata = { /** * Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */ _id?: string; /** * Details about the error in case of failure. */ error?: Events.ecomV1OrderApplicationError; /** * Index of the item within the request array. Allows for correlation between request and response items. */ originalIndex?: number; /** * Whether the requested action was successful for this item. When `false`, the `error` field is populated. */ success?: boolean; }; type ecomV1OrderItemTaxFullDetails = { /** * Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`. */ taxRate?: string; /** * Taxable amount of this line item. */ taxableAmount?: Events.ecomV1OrderPrice; /** * The calculated tax, based on the `taxableAmount` and `taxRate`. */ totalTax?: Events.ecomV1OrderPrice; }; type ecomV1OrderItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ecomV1OrderItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ecomV1OrderLineItemExchangeData = { /** * ID of the exchanged line item. */ lineItemId?: string; /** * Line item quantity being exchanged. */ quantity?: number; }; type ecomV1OrderLineItemUpdate = { /** * Description lines' info. * If description line already exists for this name, it will be replaced. */ descriptionLines?: Array; /** * Line item ID. */ lineItemId?: string; }; type ecomV1OrderMarkAsFulfilledRequest = { /** * Order ID. */ _id: string; }; type ecomV1OrderMarkAsFulfilledResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderMarkAsUnfulfilledRequest = { /** * Order ID. */ _id: string; }; type ecomV1OrderMarkAsUnfulfilledResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderMarkOrderAsPaidRequest = { /** * Order ID. */ _id: string; }; type ecomV1OrderMarkOrderAsPaidResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderMarkOrderAsSeenByHumanRequest = { /** * Order ID. */ _id: string; }; type ecomV1OrderMarkOrderAsSeenByHumanResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderMerchantComment = { /** * Merchant comment message. */ message?: string; }; type ecomV1OrderMerchantDiscount = { /** * Discount amount. */ amount?: Events.ecomV1OrderPrice; /** * Discount description as free text (optional). */ description?: string; /** * Pre-defined discount reason (optional). * * `"ITEMS_EXCHANGE"` - exchange balance acquired as a result of items exchange. */ discountReason?: string; }; type ecomV1OrderMerchantDiscountMerchantDiscountReasonOneOf = { /** * Discount description as free text (optional). */ description?: string; /** * Pre-defined discount reason (optional). * * `"ITEMS_EXCHANGE"` - exchange balance acquired as a result of items exchange. */ discountReason?: string; }; type ecomV1OrderNewExchangeOrderCreated = { /** * ID of the new order created as a result of an exchange of items. */ exchangeOrderId?: string; /** * IDs of the items that were exchanged. */ lineItems?: Array; }; type ecomV1OrderOrder = { /** * Date and time the order was created. */ _createdDate?: Date; /** * Order ID. */ _id?: string; /** * Date and time of order's latest update. */ _updatedDate?: Date; /** * Order activities. */ activities?: Array; /** * Additional fees applied to the order. */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Whether order is archived. */ archived?: boolean; /** * Order attribution source. */ attributionSource?: string; /** * Billing address and contact details. */ billingInfo?: Events.ecomV1OrderAddressWithContact; /** * Buyer information. */ buyerInfo?: Events.ecomV1OrderBuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * Information about the sales channel that submitted this order. */ channelInfo?: Events.ecomV1OrderChannelInfo; /** * Checkout ID. */ checkoutId?: string; /** * ID of the order's initiator. */ createdBy?: Events.ecomV1OrderCreatedBy; /** * Currency used for pricing in this store. */ currency?: string; /** * Custom fields. */ customFields?: Array; /** * Order fulfillment status. */ fulfillmentStatus?: string; /** * Order line items. */ lineItems?: Array; /** * Order number displayed in the site owner's business manager (auto-generated). */ number?: string; /** * Order payment status. * + `NOT_PAID` - This can be an order made online, but not yet paid. In such cases `order.status` will be `INITIALIZED`. * + This status also applies when an offline order needs to be manually marked as paid. In such cases `order.status` will be `APPROVED`. * + `PAID` - All payments associated with this order are paid. For online payments: [`payment.regularPaymentDetails.status: APPROVED`](https://bo.wix.com/wix-docs/rest/ecommerce/order-payments/order-transactions-object). For gift cards: [`payment.giftCardPaymentDetails.voided: false`](https://bo.wix.com/wix-docs/rest/ecommerce/order-payments/order-transactions-object). * + `PARTIALLY_REFUNDED` - Order was refunded, but refund amount is less than order total price. * + `FULLY_REFUNDED` - Order fully refunded. Refund amount equals total price. * + `PENDING` - Payments received but not yet confirmed by the payment provider. * + `PARTIALLY_PAID` - At least one payment was received and approved, covering less than total price amount. */ paymentStatus?: string; /** * Order price summary. */ priceSummary?: Events.ecomV1OrderPriceSummary; /** * Whether a human has seen the order. Set when an order is clicked on in the Business Manager. */ seenByAHuman?: boolean; /** * Shipping info and selected shipping option details. */ shippingInfo?: Events.ecomV1OrderShippingInformation; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Order status. * + `INITIALIZED` - Order was created, but not yet approved or declined. * + `APPROVED` - Order was approved. This happens when either the online payment succeeded or the order is an offline order. * + Once an order is approved, many side effects are triggered. For example, holding of stock in the inventory and sending of notification emails. * + `CANCELED` - Order was canceled by the user. */ status?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrices?: boolean; /** * Tax summary. */ taxSummary?: Events.ecomV1OrderTaxSummary; /** * Weight measurement unit - defaults to site's weight unit. */ weightUnit?: string; }; type ecomV1OrderOrderApproved = { /** * The order that was updated */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderOrderApprovedEvent = { data: Events.ecomV1OrderOrderApproved; metadata: Events.ecomV1OrderBackendEventMetadata; }; type ecomV1OrderOrderCanceled = {}; type ecomV1OrderOrderCanceledEventOrderCanceled = { /** * Personal note added to the email */ customMessage?: string; /** * The order that was cancelled */ order?: Events.ecomV1OrderOrder; /** * Should restock all items on that order */ restockAllItems?: boolean; /** * Should send a confirmation mail to the customer */ sendOrderCanceledEmail?: boolean; }; type ecomV1OrderOrderCreated = { /** * Order archive status */ archived?: boolean; /** * Customer information */ buyerInfo?: Events.ecomV1OrderV2BuyerInfo; /** * Currency used for pricing in this store */ currency?: string; /** * Order creation date */ dateCreated?: Date; /** * Order fulfillment status */ fulfillmentStatus?: string; /** * ID displayed in the owner's store (auto generated) */ number?: string; /** * Order ID (auto generated upon order creation) */ orderId?: string; /** * Order payment status */ paymentStatus?: string; /** * Whether the order was read by the store owner */ read?: boolean; /** * Totals for order's line items */ totals?: Events.ecomV1OrderTotals; /** * Weight unit used in this store */ weightUnit?: string; }; type ecomV1OrderOrderCreatedFromExchange = { /** * ID of the original order for which the exchange happened. */ originalOrderId?: string; }; type ecomV1OrderOrderFulfilled = {}; type ecomV1OrderOrderItemsRestocked = { /** * The order which items were restocked */ order?: Events.ecomV1OrderOrder; /** * Restocked items and quantities */ restockItems?: Array; }; type ecomV1OrderOrderLineItem = { /** * Line item ID. */ _id?: string; /** * References to the line item's origin catalog. * See [Catalog SPI](https://bo.wix.com/wix-docs/rest/ecommerce/catalog-spi/introduction) for more details. * This field is empty in the case of a custom line item. */ catalogReference?: Events.ecomV1OrderCatalogReference; /** * Item's price amount to be charged during checkout, relevant for items with payment option DEPOSIT_ONLINE */ depositAmount?: Events.ecomV1OrderPrice; /** * Line item description lines. Used for display purposes for the cart, checkout and order. */ descriptionLines?: Array; /** * Fulfiller ID. Field is empty when the line item is self-fulfilled. * To get fulfillment information, pass this order's ID to [List Fulfillments For Single Order](https://bo.wix.com/wix-docs/rest/ecommerce/order-fulfillments/list-fulfillments-for-single-order). */ fulfillerId?: string; /** * Line item image. */ image?: string; /** * Item type. Either a preset type or custom. */ itemType?: Events.ecomV1OrderItemType; /** * Type of selected payment option for current item. Defaults to `FULL_PAYMENT_ONLINE`. * + `FULL_PAYMENT_ONLINE` - The entire payment for this item happens as part of the checkout. * + `FULL_PAYMENT_OFFLINE` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `MEMBERSHIP` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0. * + `DEPOSIT_ONLINE` - Partial payment for the given item to be paid upfront during the checkout. Eligible for catalog items with type `DEPOSIT_ONLINE` only. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU and item weight. */ physicalProperties?: Events.ecomV1OrderPhysicalProperties; /** * Line item price after line item discounts for display purposes. */ price?: Events.ecomV1OrderPrice; /** * Line item price before line item discounts for display purposes. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Events.ecomV1OrderPrice; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: Events.ecomV1OrderPriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: Events.ecomV1OrderProductName; /** * Line item quantity. */ quantity?: number; /** * quantity of inventory requested to be returned. Whether to restock or ignore the request is up the vertical. */ restockQuantity?: number; /** * Subscription info. */ subscriptionInfo?: Events.ecomV1OrderSubscriptionInfo; /** * Tax details for this line item. */ taxDetails?: Events.ecomV1OrderItemTaxFullDetails; /** * Total discount for this line item's entire quantity. */ totalDiscount?: Events.ecomV1OrderPrice; /** * Total price after all discounts and tax. */ totalPriceAfterTax?: Events.ecomV1OrderPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Events.ecomV1OrderPrice; }; type ecomV1OrderOrderNotFulfilled = {}; type ecomV1OrderOrderPaid = {}; type ecomV1OrderOrderPartiallyPaid = {}; type ecomV1OrderOrderPlaced = {}; type ecomV1OrderOrderRefunded = { /** * Refund amount. */ amount?: Events.ecomV1OrderPrice; /** * Whether order was refunded manually. For example, via payment provider or using cash. */ manual?: boolean; /** * Reason for refund. */ reason?: string; }; type ecomV1OrderOrdersExperiments = { epCommitTax?: boolean; moveBuyerOrderConfirmationEmailToEp?: boolean; moveMerchantEmailToEp?: boolean; producedByEpBridge?: boolean; }; type ecomV1OrderPaymentStatusUpdated = { /** * The order that was updated */ order?: Events.ecomV1OrderOrder; /** * The previous status (before the update) */ previousPaymentStatus?: string; }; type ecomV1OrderPhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit (KG or LB) is taken from `order.weightUnit`. */ weight?: number; }; type ecomV1OrderPickupAddress = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Events.ecomV1OrderStreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type ecomV1OrderPickupDetails = { /** * Pickup address. */ address?: Events.ecomV1OrderPickupAddress; /** * Pickup method */ pickupMethod?: string; }; type ecomV1OrderPickupReadyEmailSent = {}; type ecomV1OrderPlainTextValue = { /** * Optional - Description line plain text value in site's default language. */ original?: string; /** * Optional - Translated description line plain text value according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderPlatformPaging = { /** * Number of items to load. */ limit?: number; /** * Number of items to skip in the current sort order. */ offset?: number; }; type ecomV1OrderPlatformPagingMetadata = { /** * The number of items returned in this response. */ count?: number; /** * Cursors to navigate through result pages. Returned if cursor paging was used. */ cursors?: Events.ecomV1OrderCursors; /** * The offset which was requested. Returned if offset paging was used. */ offset?: number; /** * The total number of items that match the query. Returned if offset paging was used. */ total?: number; }; type ecomV1OrderPlatformQuery = { /** * Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: Events.ecomV1OrderCursorPaging; /** * Filter object. */ filter?: Object; /** * Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: Events.ecomV1OrderPlatformPaging; /** * Sorting options. For example, `[{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}]`. */ sort?: Array; }; type ecomV1OrderPlatformQueryPagingMethodOneOf = { /** * Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: Events.ecomV1OrderCursorPaging; /** * Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: Events.ecomV1OrderPlatformPaging; }; type ecomV1OrderPreparePaymentCollectionRequest = { /** * Amount to collect */ amount: Events.ecomV1OrderPrice; /** * Ecom order ID. */ ecomOrderId: string; }; type ecomV1OrderPreparePaymentCollectionResponse = { /** * Payment gateway order id which is associated with given payment */ paymentGatewayOrderId?: string; }; type ecomV1OrderPreviewBuyerConfirmationEmailRequest = {}; type ecomV1OrderPreviewBuyerConfirmationEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewBuyerPaymentsReceivedEmailRequest = {}; type ecomV1OrderPreviewBuyerPaymentsReceivedEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewBuyerPickupConfirmationEmailRequest = {}; type ecomV1OrderPreviewBuyerPickupConfirmationEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewCancelEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; orderId: string; }; type ecomV1OrderPreviewCancelEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewCancelRefundEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; orderId: string; /** * Refund amount */ refundAmount?: Events.ecomV1OrderPrice; }; type ecomV1OrderPreviewCancelRefundEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewEmailByTypeRequest = { /** * Suppoerted values: * - `'DOWNLOAD_LINKS'` * - `'ORDER_PLACED'` * - `'ORDER_READY_FOR_PICKUP'` * - `'ORDER_SHIPPED'` */ emailType: string; }; type ecomV1OrderPreviewEmailByTypeResponse = { emailPreview?: string; }; type ecomV1OrderPreviewRefundEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * Refund business details */ details?: Events.ecomV1OrderRefundDetails; orderId: string; /** * Refund amount */ refundAmount: Events.ecomV1OrderPrice; }; type ecomV1OrderPreviewRefundEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewResendDownloadLinksEmailRequest = {}; type ecomV1OrderPreviewResendDownloadLinksEmailResponse = { emailPreview?: string; }; type ecomV1OrderPreviewShippingConfirmationEmailRequest = {}; type ecomV1OrderPreviewShippingConfirmationEmailResponse = { emailPreview?: string; }; type ecomV1OrderPrice = { /** * Amount. */ amount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; }; type ecomV1OrderPriceDescription = { /** * Required** - Original price description (in site's default language). */ original?: string; /** * Optional - Translated product name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderPriceSummary = { /** * Total calculated discount value. */ discount?: Events.ecomV1OrderPrice; /** * Total shipping price, before discounts and before tax. */ shipping?: Events.ecomV1OrderPrice; /** * Subtotal of all the line items, before discounts and before tax. */ subtotal?: Events.ecomV1OrderPrice; /** * Total tax on this order. */ tax?: Events.ecomV1OrderPrice; /** * Order’s total price after discounts and tax. */ total?: Events.ecomV1OrderPrice; /** * Total price of additional fees. */ totalAdditionalFees?: Events.ecomV1OrderPrice; /** * Deprecated - use `total` instead. */ totalPrice?: Events.ecomV1OrderPrice; }; type ecomV1OrderProductName = { /** * Required** - Original item name (in site's default language). */ original?: string; /** * Optional - Translated item name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderPublicActivity = { /** * Custom activity details. */ customActivity?: Events.ecomV1OrderCustomActivity; /** * Merchant commment. */ merchantComment?: Events.ecomV1OrderMerchantComment; }; type ecomV1OrderPublicActivityContentOneOf = { /** * Custom activity details. */ customActivity?: Events.ecomV1OrderCustomActivity; /** * Merchant commment. */ merchantComment?: Events.ecomV1OrderMerchantComment; }; type ecomV1OrderQueryOrderRequest = { /** * Query options. */ query?: Events.ecomV1OrderPlatformQuery; }; type ecomV1OrderQueryOrderResponse = { /** * Details on the paged set of results returned. */ metadata?: Events.ecomV1OrderPlatformPagingMetadata; /** * List of orders. */ orders?: Array; }; type ecomV1OrderRefundDetails = { /** * Refunded line items and quantities. */ items?: Array; /** * Reason for refund, given by user (optional). */ reason?: string; /** * Whether shipping rate is also refunded. */ shippingIncluded?: boolean; }; type ecomV1OrderRefundItem = { /** * ID of the line item being refunded. */ lineItemId?: string; /** * Line item quantity being refunded. */ quantity?: number; }; type ecomV1OrderReschedule = { executeAt?: Date; payload?: string; }; type ecomV1OrderRestockItem = { /** * ID of the line item being restocked. */ lineItemId?: string; /** * Line item quantity being restocked. */ quantity?: number; }; type ecomV1OrderSendBuyerConfirmationEmailRequest = { orderId: string; }; type ecomV1OrderSendBuyerConfirmationEmailResponse = {}; type ecomV1OrderSendBuyerPaymentsReceivedEmailRequest = { orderId: string; }; type ecomV1OrderSendBuyerPaymentsReceivedEmailResponse = {}; type ecomV1OrderSendBuyerPickupConfirmationEmailRequest = { orderId: string; }; type ecomV1OrderSendBuyerPickupConfirmationEmailResponse = {}; type ecomV1OrderSendBuyerShippingConfirmationEmailRequest = { orderId: string; }; type ecomV1OrderSendBuyerShippingConfirmationEmailResponse = {}; type ecomV1OrderSendCancelRefundEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * The ID of order that is canceled/refunded */ orderId: string; /** * Refund amount */ refundAmount: Events.ecomV1OrderPrice; }; type ecomV1OrderSendCancelRefundEmailResponse = {}; type ecomV1OrderSendMerchantOrderReceivedNotificationRequest = { orderId: string; }; type ecomV1OrderSendMerchantOrderReceivedNotificationResponse = {}; type ecomV1OrderSendOrderPaymentReceivedEmail = { orderId?: string; storeId?: string; }; type ecomV1OrderShippingAddressEdited = {}; type ecomV1OrderShippingConfirmationEmailSent = {}; type ecomV1OrderShippingInformation = { /** * App Def Id of external provider which was a source of shipping info */ carrierId?: string; /** * Unique code (or ID) of selected shipping option. For example, `"usps_std_overnight"``. */ code?: string; /** * Shipping costs. */ cost?: Events.ecomV1OrderShippingPrice; /** * Shipping logistics. */ logistics?: Events.ecomV1OrderDeliveryLogistics; /** * Shipping region. */ region?: Events.ecomV1OrderShippingRegion; /** * Shipping option title. * For example, `"USPS Standard Overnight Delivery"`, `"Standard"` or `"First-Class Package International"`. */ title?: string; }; type ecomV1OrderShippingPrice = { /** * Shipping discount before tax. */ discount?: Events.ecomV1OrderPrice; /** * Shipping price for display purposes. */ price?: Events.ecomV1OrderPrice; /** * Tax details. */ taxDetails?: Events.ecomV1OrderItemTaxFullDetails; /** * Shipping price after all discounts (if any exist), and after tax. */ totalPriceAfterTax?: Events.ecomV1OrderPrice; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Events.ecomV1OrderPrice; }; type ecomV1OrderShippingRegion = { /** * Name of shipping region. For example, `"Metropolitan London"`, or `"Outer Melbourne suburbs"`. */ name?: string; }; type ecomV1OrderSnapshotMessage = { _id?: string; opType?: number; }; type ecomV1OrderSorting = { /** * Name of the field to sort by. */ fieldName?: string; /** * Sort order. */ order?: string; }; type ecomV1OrderStreet = { /** * Street name */ name?: string; /** * Street number */ number?: string; }; type ecomV1OrderStreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type ecomV1OrderSubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`. */ cycleNumber?: number; /** * Subscription option description. For example, `"1kg of selected coffee, once a month"`. */ subscriptionOptionDescription?: string; /** * Subscription option title. For example, `"Monthly coffee Subscription"`. */ subscriptionOptionTitle?: string; /** * Subscription detailed information. */ subscriptionSettings?: Events.ecomV1OrderSubscriptionSettings; }; type ecomV1OrderSubscriptionOptionInfo = { /** * Subscription option description. */ description?: string; /** * Subscription option title. */ title?: string; }; type ecomV1OrderSubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type ecomV1OrderTask = { executeAt?: Date; key?: Events.ecomV1OrderTaskKey; payload?: string; }; type ecomV1OrderTaskAction = { cancel?: Events.ecomV1OrderCancel; complete?: Events.ecomV1OrderComplete; reschedule?: Events.ecomV1OrderReschedule; }; type ecomV1OrderTaskActionActionOneOf = { cancel?: Events.ecomV1OrderCancel; complete?: Events.ecomV1OrderComplete; reschedule?: Events.ecomV1OrderReschedule; }; type ecomV1OrderTaskKey = { appId?: string; instanceId?: string; subjectId?: string; }; type ecomV1OrderTaxSummary = { /** * Total tax. */ totalTax?: Events.ecomV1OrderPrice; }; type ecomV1OrderTotals = { /** * Total calculated discount value. */ discount?: string; /** * Total calculated gift card value. */ giftCard?: string; /** * Total number of line items. */ quantity?: number; /** * Total refund. */ refund?: string; /** * Total shipping price, before tax. */ shipping?: string; /** * Subtotal of all the line items, before tax. */ subtotal?: string; /** * Total tax. */ tax?: string; /** * Total price charged. */ total?: string; /** * Total items weight. */ weight?: string; }; type ecomV1OrderTrackingLinkAdded = {}; type ecomV1OrderTrackingNumberAdded = {}; type ecomV1OrderTrackingNumberEdited = {}; type ecomV1OrderTransactionsActivity = { /** * Activity item author */ author?: string; /** * Comment added to activity item */ message?: string; /** * Activity item timestamp */ timestamp?: Date; /** * Activity item type */ type?: string; }; type ecomV1OrderTransactionsAddInvoiceToOrderRequest = { /** * Invoice info. */ invoiceInfo: Events.ecomV1OrderTransactionsInvoiceInfo; /** * Order ID. */ orderId: string; }; type ecomV1OrderTransactionsAddInvoiceToOrderResponse = { /** * List of order invoices. */ orderInvoices?: Array; }; type ecomV1OrderTransactionsAddPaymentsRequest = { /** * Order ID. */ orderId: string; /** * Payments to be added to order. */ payments: Array; }; type ecomV1OrderTransactionsAddPaymentsResponse = { /** * Order ID and its associated transactions. */ orderTransactions?: Events.ecomV1OrderTransactionsOrderTransactions; /** * IDs of added order payments. */ paymentsIds?: Array; }; type ecomV1OrderTransactionsAddress = { /** * Address line 1 (free text) */ addressLine1?: string; /** * address line */ addressLine2?: string; /** * City name */ city?: string; /** * Company name */ company?: string; /** * Country code (2 letters) */ country?: string; /** * Email address */ email?: string; /** * Addressee name */ fullName?: Events.ecomV1OrderTransactionsFullName; /** * Phone number */ phone?: string; /** * Address line 1 (street) */ street?: Events.ecomV1OrderTransactionsStreet; /** * State or district */ subdivision?: string; /** * Tax information (for Brazil only) */ vatId?: Events.ecomV1OrderTransactionsVatId; /** * ZIP/postal code */ zipCode?: string; }; type ecomV1OrderTransactionsAddressAddressLine1OptionsOneOf = { /** * Address line 1 (free text) */ addressLine1?: string; /** * Address line 1 (street) */ street?: Events.ecomV1OrderTransactionsStreet; }; type ecomV1OrderTransactionsApplicationError = { code?: string; data?: Object; description?: string; }; type ecomV1OrderTransactionsAppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type ecomV1OrderTransactionsBackendEventMetadata = { entityId: string; eventTime: string; id: string; triggeredByAnonymizeRequest: boolean; }; type ecomV1OrderTransactionsBillingInfo = { /** * Full billing address */ address?: Events.ecomV1OrderTransactionsAddress; /** * Deprecated (use paymentProviderTransactionId instead) */ externalTransactionId?: string; /** * Payment date */ paidDate?: Date; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; /** * Transaction ID from payment provider (e.g., PayPal, Square, Stripe) transaction ID */ paymentProviderTransactionId?: string; /** * Whether order can be refunded by payment provider (manually or automatic) */ refundableByPaymentProvider?: boolean; }; type ecomV1OrderTransactionsBulkActionMetadata = { /** * Number of items that couldn't be processed. */ totalFailures?: number; /** * Number of items that were successfully processed. */ totalSuccesses?: number; /** * Number of failures without details because detailed failure threshold was exceeded. */ undetailedFailures?: number; }; type ecomV1OrderTransactionsBulkGenerateInvoicesRequest = { /** * Order IDs. */ orderIds: Array; }; type ecomV1OrderTransactionsBulkGenerateInvoicesResponse = { bulkActionMetadata?: Events.ecomV1OrderTransactionsBulkActionMetadata; results?: Array; }; type ecomV1OrderTransactionsBulkInvoiceResult = { item?: Events.ecomV1OrderTransactionsInvoiceForOrder; itemMetadata?: Events.ecomV1OrderTransactionsItemMetadata; }; type ecomV1OrderTransactionsBulkPaymentResult = { /** * Updated payment. Returned if `return_full_entity` set to `true`. */ item?: Events.ecomV1OrderTransactionsPayment; /** * Item metadata. */ itemMetadata?: Events.ecomV1OrderTransactionsItemMetadata; }; type ecomV1OrderTransactionsBulkUpdatePaymentStatusesRequest = { /** * Order and payment IDs for which to update payment status. */ paymentAndOrderIds: Array; /** * Whether to return the full payment entity (`results.item`) in the response. */ returnFullEntity?: boolean; /** * Payment status. */ status?: string; }; type ecomV1OrderTransactionsBulkUpdatePaymentStatusesResponse = { /** * Bulk operation metadata. */ bulkActionMetadata?: Events.ecomV1OrderTransactionsBulkActionMetadata; /** * Bulk operation results. */ results?: Array; }; type ecomV1OrderTransactionsBuyerDetails = { /** * Email address */ email?: string; /** * Addressee name */ fullName?: Events.ecomV1OrderTransactionsFullName; /** * Phone number */ phone?: string; }; type ecomV1OrderTransactionsBuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer type */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; /** * Deprecated (use identityType instead) */ type?: string; }; type ecomV1OrderTransactionsCalculateRefundItemRequest = { /** * ID of the line item being refunded */ lineItemId?: string; /** * How much of that line item is being refunded */ quantity?: number; /** * Should this item be restocked (used for validation purposes) */ restock?: boolean; }; type ecomV1OrderTransactionsCalculateRefundItemResponse = { /** * Line item ID */ lineItemId?: string; /** * The line item's price */ lineItemPrice?: number; }; type ecomV1OrderTransactionsCalculateRefundRequest = { /** * Order ID */ orderId: string; /** * Refunded line items and quantity */ refundItems?: Array; /** * Should include shipping in refund calculation */ refundShipping?: boolean; }; type ecomV1OrderTransactionsCalculateRefundResponse = { /** * Discount given for this order */ discount?: string; /** * The refundable items of that order */ items?: Array; /** * Previous refund given on that order */ previouslyRefundedAmount?: string; /** * Total cost of the order (without tax) */ subtotal?: string; /** * Tax cost of the order */ tax?: string; /** * Total refundable amount */ total?: string; }; type ecomV1OrderTransactionsChannelInfo = { /** * Reference to an order ID from an external system, as defined in channelInfo (e.g., eBay or Amazon) */ externalOrderId?: string; /** * URL to the order in the external system, as defined in channelInfo (e.g., eBay or Amazon) */ externalOrderUrl?: string; /** * Sales channel that submitted the order */ type?: string; }; type ecomV1OrderTransactionsCustomField = { /** * Title for the custom field */ title?: string; /** * The title translated according to the buyer language */ translatedTitle?: string; /** * Free text that the customer entered in the custom field during the checkout process */ value?: string; }; type ecomV1OrderTransactionsCustomTextFieldSelection = { /** * Custom text field name */ title?: string; /** * Custom text field value */ value?: string; }; type ecomV1OrderTransactionsDiffmatokyPayload = { compareChannel?: string; entityId?: string; errorInformation?: Events.ecomV1OrderTransactionsErrorInformation; left?: string; right?: string; tags?: Array; }; type ecomV1OrderTransactionsDigitalFile = { /** * id of the secure file in media */ fileId?: string; }; type ecomV1OrderTransactionsDiscount = { /** * Applied coupon */ appliedCoupon?: Events.ecomV1OrderTransactionsAppliedCoupon; /** * Deprecated (use Totals.discount instead) */ value?: string; }; type ecomV1OrderTransactionsEnteredBy = { _id?: string; /** * Suppoerted values: * - `'APP'` * - `'CONTACT'` * - `'MEMBER'` * - `'USER'` */ identityType?: string; }; type ecomV1OrderTransactionsErrorInformation = { stackTrace?: string; }; type ecomV1OrderTransactionsFulfillment = { /** * Fulfillment ID (auto generated upon fulfillment creation). */ _id?: string; /** * Fulfillment creation date and time. */ dateCreated?: Date; /** * Information about the line items in the fulfilled order. */ lineItems?: Array; /** * Tracking information. */ trackingInfo?: Events.ecomV1OrderTransactionsFulfillmentTrackingInfo; }; type ecomV1OrderTransactionsFulfillmentLineItem = { /** * Line item ID (mirrors the line item index of the order). */ index?: number; /** * Line item quantity. * On creation, if this parameter isn't passed, the new fulfillment will automatically include all items of this line item that have not already been linked to a fulfillment. * If the order does not have the requested quantity of line items available to add to this fulfillment, the fulfillment will not be created and an error will be returned. * This property will always have a value when returned. */ quantity?: number; }; type ecomV1OrderTransactionsFulfillmentTrackingInfo = { /** * Shipping provider. Using the following shipping providers will allow for autofilling the tracking link: * * `fedex` * * `ups` * * `usps` * * `dhl` * * `canadaPost` */ shippingProvider?: string; /** * Tracking link - autofilled if using a predefined shipping provider, otherwise provided on creation. */ trackingLink?: string; /** * Tracking number. */ trackingNumber?: string; }; type ecomV1OrderTransactionsFullName = { /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; }; type ecomV1OrderTransactionsGenerateInvoiceRequest = { /** * Order ID. */ orderId: string; }; type ecomV1OrderTransactionsGenerateInvoiceResponse = { /** * Invoice ID. */ invoiceId?: string; }; type ecomV1OrderTransactionsGetRefundabilityStatusRequest = { /** * Order ID. */ orderId: string; }; type ecomV1OrderTransactionsGetRefundabilityStatusResponse = { /** * Refundability details. */ refundabilities?: Array; /** * Whether the order supports refunding per item. */ refundablePerItem?: boolean; }; type ecomV1OrderTransactionsGiftCard = { /** * giftcard internal ID */ _id?: string; /** * giftcard amount */ amount?: string; /** * giftcard provider appid */ providerId?: string; transactionId?: string; }; type ecomV1OrderTransactionsGiftCardPaymentDetails = { /** * ID of the app that created the gift card. */ appId?: string; /** * Gift card ID. */ giftCardId?: string; /** * Gift card payment ID. */ giftCardPaymentId?: string; /** * Whether the gift card is voided. */ voided?: boolean; }; type ecomV1OrderTransactionsIndexingMessage = { _id?: string; opType?: number; requiredVersions?: Array; }; type ecomV1OrderTransactionsInvoiceForOrder = { /** * Invoice ID. */ invoiceId?: string; /** * Order ID. */ orderId?: string; }; type ecomV1OrderTransactionsInvoiceInfo = { /** * Invoice creation date and time. */ _createdDate?: Date; /** * Invoice ID. */ _id?: string; /** * ID of the app that set the invoice. */ appId?: string; /** * Invoice URL. */ url?: string; }; type ecomV1OrderTransactionsInvoicesForOrder = { /** * Invoices info. */ invoicesInfo?: Array; /** * Order ID. */ orderId?: string; }; type ecomV1OrderTransactionsItemMetadata = { /** * Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */ _id?: string; /** * Details about the error in case of failure. */ error?: Events.ecomV1OrderTransactionsApplicationError; /** * Index of the item within the request array. Allows for correlation between request and response items. */ originalIndex?: number; /** * Whether the requested action was successful for this item. When `false`, the `error` field is populated. */ success?: boolean; }; type ecomV1OrderTransactionsLineItem = { /** * Line item custom text field entry */ customTextFields?: Array; /** * Discount applied for this line item */ discount?: string; /** * Line item fulfillerId from stores fulfillers. No value equals self fulfilled */ fulfillerId?: string; /** * Line item ID (auto-generated, stable within this order only) */ index?: number; /** * Line item type (may be extended) */ lineItemType?: string; /** * Primary media for preview of the line item */ mediaItem?: Events.ecomV1OrderTransactionsMediaItem; /** * Line item name */ name?: string; /** * Line item notes */ notes?: string; /** * Line item options ordered */ options?: Array; /** * Deprecated (use priceData instead) */ price?: string; /** * Price data */ priceData?: Events.ecomV1OrderTransactionsLineItemPriceData; /** * Line item product ID (optional for POS orders) */ productId?: string; /** * Line item quantity */ quantity?: number; /** * Line item SKU */ sku?: string; /** * Tax applied for this line item */ tax?: string; /** * Tax group ID */ taxGroupId?: string; /** * Deprecated (use priceData instead) */ taxIncludedInPrice?: boolean; /** * Deprecated (use priceData instead) */ totalPrice?: string; /** * Product name, translated into the customer's language */ translatedName?: string; /** * Line item variantId (from Stores Catalog) */ variantId?: string; /** * Line item weight */ weight?: string; }; type ecomV1OrderTransactionsLineItemPriceData = { /** * Line item price */ price?: string; /** * Whether tax is included in the price set for this line item */ taxIncludedInPrice?: boolean; /** * Total price charged to the customer (per line item) after computation of quantity and discount */ totalPrice?: string; }; type ecomV1OrderTransactionsListInvoicesForMultipleOrdersRequest = { /** * Order IDs for which to retrieve invoices. */ orderIds: Array; }; type ecomV1OrderTransactionsListInvoicesForMultipleOrdersResponse = { /** * List of order IDs and their associated invoices. */ invoicesForOrder?: Array; }; type ecomV1OrderTransactionsListInvoicesForSingleOrderRequest = { /** * Order ID. */ orderId: string; }; type ecomV1OrderTransactionsListInvoicesForSingleOrderResponse = { /** * List of invoices. */ invoices?: Array; }; type ecomV1OrderTransactionsListTransactionsForMultipleOrdersRequest = { /** * Order IDs for which to retrieve transactions. */ orderIds: Array; }; type ecomV1OrderTransactionsListTransactionsForMultipleOrdersResponse = { /** * List of order IDs and their associated transactions. */ orderTransactions?: Array; }; type ecomV1OrderTransactionsListTransactionsForSingleOrderRequest = { /** * Order ID. */ orderId: string; }; type ecomV1OrderTransactionsListTransactionsForSingleOrderResponse = { /** * Order ID and its associated transactions. */ orderTransactions?: Events.ecomV1OrderTransactionsOrderTransactions; }; type ecomV1OrderTransactionsMediaItem = { /** * Media ID (for media items previously saved in Wix Media) */ _id?: string; /** * Alternative text for presentation when media cannot be displayed */ altText?: string; /** * Media external URL */ externalImageUrl?: string; /** * Media item height */ height?: number; /** * Deprecated */ mediaId?: string; /** * Media type */ mediaType?: string; /** * Media URL */ url?: string; /** * Media item width */ width?: number; }; type ecomV1OrderTransactionsMembershipName = { /** * The name of this membership */ original?: string; /** * Optional - Translated name of this membership. Defaults to `original` when not provided. */ translated?: string; }; type ecomV1OrderTransactionsMembershipPaymentDetails = { /** * The transaction id under the membership system. Can be used to void it */ externalTransactionId?: string; /** * ID of the line item this membership applies to. */ lineItemId?: string; /** * The membership id */ membershipId?: string; /** * Membership name */ name?: Events.ecomV1OrderTransactionsMembershipName; /** * ID of the application providing this payment option */ providerAppId?: string; /** * Payment status */ status?: string; /** * Whether the membership is voided. */ voided?: boolean; }; type ecomV1OrderTransactionsOptionSelection = { /** * Option name */ option?: string; /** * Selected choice for this option */ selection?: string; }; type ecomV1OrderTransactionsOrder = { /** * Order ID (auto-generated upon order creation). */ _id?: string; /** * Log of updates related to the order. */ activities?: Array; /** * Whether or not the order was archived. */ archived?: boolean; /** * Billing information. */ billingInfo?: Events.ecomV1OrderTransactionsBillingInfo; /** * Buyer information. */ buyerInfo?: Events.ecomV1OrderTransactionsBuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * A note added by the buyer. */ buyerNote?: string; /** * Shopping cart ID. */ cartId?: string; /** * Information about the sales channel that submitted this order. */ channelInfo?: Events.ecomV1OrderTransactionsChannelInfo; /** * Currency used for pricing in this store. */ currency?: string; /** * Custom field information. */ customField?: Events.ecomV1OrderTransactionsCustomField; /** * Order creation date and time. */ dateCreated?: Date; /** * Discount information. */ discount?: Events.ecomV1OrderTransactionsDiscount; /** * Identity of the order's initiator. */ enteredBy?: Events.ecomV1OrderTransactionsEnteredBy; /** * Order's current fulfillment status (whether the order received a tracking number or was delivered/picked up). */ fulfillmentStatus?: string; /** * Order fulfillment information. */ fulfillments?: Array; /** * Invoice information. */ invoiceInfo?: Events.ecomV1OrderTransactionsV2InvoiceInfo; /** * Date and time of latest update. */ lastUpdated?: Date; /** * Line items ordered. */ lineItems?: Array; /** * Order number displayed in the owner's store (auto-generated). */ number?: number; /** * Order’s unique numeric ID. * Primarily used for sorting and filtering when crawling all orders. */ numericId?: string; /** * Current status of the payment. */ paymentStatus?: string; /** * Deprecated. */ read?: boolean; /** * Refund information. */ refunds?: Array; /** * Shipping information. */ shippingInfo?: Events.ecomV1OrderTransactionsShippingInfo; /** * Subscription information. */ subscriptionInfo?: Events.ecomV1OrderTransactionsSubscriptionInfo; /** * Totals for order's line items. */ totals?: Events.ecomV1OrderTransactionsTotals; /** * Weight unit used in this store. */ weightUnit?: string; }; type ecomV1OrderTransactionsOrderRefunded = { /** * Refunded order data. */ order?: Events.ecomV1OrderTransactionsOrder; /** * Refund ID. */ refundId?: string; }; type ecomV1OrderTransactionsOrderTransactions = { /** * Order ID. */ orderId?: string; /** * Payments to the merchant. */ payments?: Array; /** * Refunds to the buyer. */ refunds?: Array; }; type ecomV1OrderTransactionsOrderTransactionsPayments = { data: Events.ecomV1OrderTransactionsPaymentsUpdated; metadata: Events.ecomV1OrderTransactionsBackendEventMetadata; }; type ecomV1OrderTransactionsOrderTransactionsRefunded = { data: Events.ecomV1OrderTransactionsRefundCreated; metadata: Events.ecomV1OrderTransactionsBackendEventMetadata; }; type ecomV1OrderTransactionsPayment = { /** * Payment creation date and time. Defaults to current time when not provided. */ _createdDate?: Date; /** * Payment ID (auto-generated upon payment creation). */ _id?: string; /** * Payment modification date and time. */ _updatedDate?: Date; /** * Payment amount. */ amount?: Events.ecomV1OrderTransactionsPrice; /** * Gift card payment details. */ giftcardPaymentDetails?: Events.ecomV1OrderTransactionsGiftCardPaymentDetails; /** * Whether refunds are explicitly disabled. * True means this payment is not refundable. * False means this payment might be refunded (depending on the payment provider). */ refundDisabled?: boolean; /** * Regular payment details. */ regularPaymentDetails?: Events.ecomV1OrderTransactionsRegularPaymentDetails; }; type ecomV1OrderTransactionsPaymentAndOrderId = { /** * Order ID. */ orderId?: string; /** * Payment ID. */ paymentId?: string; }; type ecomV1OrderTransactionsPaymentPaymentDetailsOneOf = { /** * Gift card payment details. */ giftcardPaymentDetails?: Events.ecomV1OrderTransactionsGiftCardPaymentDetails; /** * Regular payment details. */ regularPaymentDetails?: Events.ecomV1OrderTransactionsRegularPaymentDetails; }; type ecomV1OrderTransactionsPaymentRefund = { /** * Refund amount. Not relevant for membership refunds. */ amount?: Events.ecomV1OrderTransactionsPrice; /** * Whether refund is made externally and manually (on the payment provider's side) * When false (default), the payment gateway will be called in order to make an actual refund, and then the payment will be marked as refunded. * When true, the payment will only be *marked* as refunded, and no actual refund will be performed. */ externalRefund?: boolean; /** * Specific payment within the order to refund */ paymentId?: string; }; type ecomV1OrderTransactionsPaymentsUpdated = { /** * Updated order transactions. */ orderTransactions?: Events.ecomV1OrderTransactionsOrderTransactions; /** * IDs of the updated payments. */ paymentIds?: Array; }; type ecomV1OrderTransactionsPickupAddress = { /** * Address */ addressLine1?: string; /** * City */ city?: string; /** * Country code (3 letters) */ country?: string; /** * State/District */ subdivision?: string; /** * ZIP/postal code */ zipCode?: string; }; type ecomV1OrderTransactionsPickupDetails = { /** * Deprecated (use billingInfo instead). */ buyerDetails?: Events.ecomV1OrderTransactionsBuyerDetails; /** * Pickup address. */ pickupAddress?: Events.ecomV1OrderTransactionsPickupAddress; /** * Store owner's pickup instructions. */ pickupInstructions?: string; }; type ecomV1OrderTransactionsPrice = { /** * Amount. */ amount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; }; type ecomV1OrderTransactionsRefund = { /** * Refund creation date and time. Defaults to current time when not provided. */ _createdDate?: Date; /** * Refund ID (auto-generated upon refund creation). */ _id?: string; /** * Business details. */ details?: Events.ecomV1OrderTransactionsRefundDetails; /** * Transaction refund details. */ transactions?: Array; }; type ecomV1OrderTransactionsRefundCreated = { /** * Personal note added to the email */ customMessage?: string; /** * Updated order transactions. */ orderTransactions?: Events.ecomV1OrderTransactionsOrderTransactions; /** * ID of the created refund. */ refundId?: string; /** * Refunded line items and quantities that are part of the created refund. */ refundItems?: Array; /** * How to restock items as part of this refund. */ restockInfo?: Events.ecomV1OrderTransactionsRestockInfo; /** * Should send a confirmation mail to the customer */ sendOrderRefundedEmail?: boolean; }; type ecomV1OrderTransactionsRefundDetails = { /** * Refunded line items and quantities. */ items?: Array; /** * Reason for refund, given by user (optional). */ reason?: string; /** * Whether shipping rate is also refunded. */ shippingIncluded?: boolean; }; type ecomV1OrderTransactionsRefundItem = { /** * ID of the line item being refunded. */ lineItemId?: string; /** * Line item quantity being refunded. */ quantity?: number; }; type ecomV1OrderTransactionsRefundTransaction = { /** * Refund amount. */ amount?: Events.ecomV1OrderTransactionsPrice; /** * Whether refund was made externally and manually (on the payment provider's side). */ externalRefund?: boolean; /** * ID of the payment gateway refund. */ gatewayRefundId?: string; /** * ID of the payment associated with this refund. */ paymentId?: string; /** * ID of the refund in the payment provider's system. */ providerRefundId?: string; /** * Refund status. */ refundStatus?: string; }; type ecomV1OrderTransactionsRefundability = { /** * Reason why payment is only refundable manually. */ manuallyRefundableReason?: string; /** * Reason why payment is not refundable. */ nonRefundableReason?: string; /** * Payment ID. */ paymentId?: string; /** * Link to payment provider dashboard. */ providerLink?: string; /** * Payment refundability status. */ refundabilityStatus?: string; }; type ecomV1OrderTransactionsRefundabilityAdditionalRefundabilityInfoOneOf = { /** * Reason why payment is only refundable manually. */ manuallyRefundableReason?: string; /** * Reason why payment is not refundable. */ nonRefundableReason?: string; }; type ecomV1OrderTransactionsRegularPaymentDetails = { /** * Transaction ID from payment gateway (e.g., Wix Payments, chargeId), what we used to call payment_gateway_transaction_id */ gatewayTransactionId?: string; /** * Whether the payment is/was made offline. For example, when using cash or when marked as paid in the Business Manager. */ offlinePayment?: boolean; /** * Payment method. Non-exhaustive list of supported values: * CreditCard, Alipay, AstropayCash, AstropayDBT, AstropayMBT, Bitcoin, BitPay, Cash, ConvenienceStore, EPay, Fake, Giropay, IDeal, InPerson, * Klarna, MercadoPago, Netpay, NordeaSolo, Offline, PagSeguro, PayEasy, PayPal, Paysafecard, Paysafecash, PointOfSale, Poli, * Privat24, Przelewy24, RapidTransfer, Sepa, Skrill, Sofort, Trustly,Neteller, Unionpay, UniPay, Yandex. */ paymentMethod?: string; /** * Wix Payment's order id */ paymentOrderId?: string; /** * Transaction ID in the payment provider's system (for example, PayPal, Square, Stripe). Does not exist for offline payments. */ providerTransactionId?: string; /** * Payment status. */ status?: string; }; type ecomV1OrderTransactionsRestockInfo = { /** * Restocked line items and quantities, only relevant for `SOME_ITEMS` type. */ items?: Array; /** * Restock policy type. */ type?: string; }; type ecomV1OrderTransactionsRestockItem = { /** * ID of the line item being restocked. */ lineItemId?: string; /** * Line item quantity being restocked. */ quantity?: number; }; type ecomV1OrderTransactionsShipmentDetails = { /** * Shipping destination address. */ address?: Events.ecomV1OrderTransactionsAddress; /** * Discount applied for shipping. */ discount?: string; /** * Price data. */ priceData?: Events.ecomV1OrderTransactionsShippingPriceData; /** * Tax applied for shipping. */ tax?: string; /** * Deprecated (use fulfillments instead). */ trackingInfo?: Events.ecomV1OrderTransactionsTrackingInfo; }; type ecomV1OrderTransactionsShippingInfo = { /** * Unique code of provided shipping option. For example, `"usps_std_overnight"`. */ code?: string; /** * Latest expected delivery date. */ deliverByDate?: Date; /** * Shipping option name. */ deliveryOption?: string; /** * Shipping option delivery time. */ estimatedDeliveryTime?: string; /** * Pickup details (when this object describes pickup). */ pickupDetails?: Events.ecomV1OrderTransactionsPickupDetails; /** * Shipment details (when this object describes shipment). */ shipmentDetails?: Events.ecomV1OrderTransactionsShipmentDetails; /** * Shipping region. */ shippingRegion?: string; }; type ecomV1OrderTransactionsShippingInfoDetailsOneOf = { /** * Pickup details (when this object describes pickup). */ pickupDetails?: Events.ecomV1OrderTransactionsPickupDetails; /** * Shipment details (when this object describes shipment). */ shipmentDetails?: Events.ecomV1OrderTransactionsShipmentDetails; }; type ecomV1OrderTransactionsShippingPriceData = { /** * Shipping price. */ price?: string; /** * Whether tax is included in the price. */ taxIncludedInPrice?: boolean; }; type ecomV1OrderTransactionsSnapshotMessage = { _id?: string; opType?: number; }; type ecomV1OrderTransactionsStreet = { /** * Street name */ name?: string; /** * Street number */ number?: string; }; type ecomV1OrderTransactionsSubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Current cycle number. For example, if the subscription is in the 3rd month of a 4-month subscription, the value will be `3`. */ cycleNumber?: number; /** * Subscription options info. */ subscriptionOptionInfo?: Events.ecomV1OrderTransactionsSubscriptionOptionInfo; /** * Subscription settings. */ subscriptionSettings?: Events.ecomV1OrderTransactionsSubscriptionSettings; }; type ecomV1OrderTransactionsSubscriptionOptionInfo = { /** * Subscription option description. */ description?: string; /** * Subscription option title. */ title?: string; }; type ecomV1OrderTransactionsSubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type ecomV1OrderTransactionsTotals = { /** * Total calculated discount value. */ discount?: string; /** * Total calculated gift card value. */ giftCard?: string; /** * Total number of line items. */ quantity?: number; /** * Total refund. */ refund?: string; /** * Total shipping price, before tax. */ shipping?: string; /** * Subtotal of all the line items, before tax. */ subtotal?: string; /** * Total tax. */ tax?: string; /** * Total price charged. */ total?: string; /** * Total items weight. */ weight?: string; }; type ecomV1OrderTransactionsTrackingInfo = { /** * Shipping provider */ shippingProvider?: string; /** * Tracking link */ trackingLink?: string; /** * Tracking number */ trackingNumber?: string; }; type ecomV1OrderTransactionsTriggerRefundRequest = { /** * Personal note added to the email */ customMessage?: string; /** * Business model of a refund */ details?: Events.ecomV1OrderTransactionsRefundDetails; /** * The order this refund related to */ orderId: string; /** * Refund operations information * Currently, only *one* payment refund is supported per request */ payments: Array; /** * How to restock items as part of this refund */ restockInfo?: Events.ecomV1OrderTransactionsRestockInfo; /** * Should send a confirmation mail to the customer */ sendOrderRefundedEmail?: boolean; }; type ecomV1OrderTransactionsTriggerRefundResponse = { /** * All order's transactions after the refunds were added */ orderTransactions?: Events.ecomV1OrderTransactionsOrderTransactions; /** * Created refund ID */ refundId?: string; }; type ecomV1OrderTransactionsUpdatePaymentStatusRequest = { /** * Order ID. */ orderId: string; /** * Payment ID. */ paymentId: string; /** * Payment status. */ status?: string; }; type ecomV1OrderTransactionsUpdatePaymentStatusResponse = { /** * Order ID and its associated transactions after update. */ orderTransactions?: Events.ecomV1OrderTransactionsOrderTransactions; }; type ecomV1OrderTransactionsV2InvoiceInfo = { /** * Invoice ID */ _id?: string; /** * Invoice source */ source?: string; }; type ecomV1OrderTransactionsV2Refund = { /** * Refund ID. */ _id?: string; /** * Refund amount. */ amount?: string; /** * Refund created timestamp. */ dateCreated?: Date; /** * Whether refund was made externally (on the payment provider's side). */ externalRefund?: boolean; /** * Payment provider transaction ID. Used to find refund transaction info on the payment provider's side. */ paymentProviderTransactionId?: string; /** * Reason for refund, given by user (optional). */ reason?: string; }; type ecomV1OrderTransactionsVatId = { /** * Customer's tax ID */ number?: string; /** * tax type */ type?: string; }; type ecomV1OrderTriggerSideEffectsFromLegacyData = { orderId?: string; ordersExperiments?: Events.ecomV1OrderOrdersExperiments; storeId?: string; }; type ecomV1OrderUnArchiveOrderRequest = { /** * Order ID. */ _id: string; }; type ecomV1OrderUnArchiveOrderResponse = { /** * Unarchived order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderUpdateActivityRequest = { /** * Order ID. */ _id: string; /** * Activity info. */ activity: Events.ecomV1OrderPublicActivity; /** * ID of the activity to update. */ activityId: string; }; type ecomV1OrderUpdateActivityResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderUpdateBillingContactDetailsRequest = { /** * Order ID. */ _id: string; /** * Contact details. */ addressContactDetails?: Events.ecomV1OrderFullAddressContactDetails; }; type ecomV1OrderUpdateBillingContactDetailsResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderUpdateBuyerInfoRequest = { /** * Order ID. */ _id: string; /** * Buyer info. */ buyerInfo?: Events.ecomV1OrderBuyerInfoUpdate; }; type ecomV1OrderUpdateBuyerInfoResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderUpdateLineItemsDescriptionLinesRequest = { /** * Order ID. */ _id: string; /** * Line items. */ lineItems: Array; }; type ecomV1OrderUpdateLineItemsDescriptionLinesResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderUpdateOrderShippingAddressRequest = { /** * Order ID. */ _id: string; /** * Shipping address and contact details to be updated. */ shippingAddress: Events.ecomV1OrderAddressWithContact; }; type ecomV1OrderUpdateOrderShippingAddressResponse = { /** * Updated order. */ order?: Events.ecomV1OrderOrder; }; type ecomV1OrderV1SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type ecomV1OrderV2BuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer type */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; /** * Deprecated (use identityType instead) */ type?: string; }; type ecomV1OrderV2SubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Current cycle number. For example, if the subscription is in the 3rd month of a 4-month subscription, the value will be `3`. */ cycleNumber?: number; /** * Subscription options info. */ subscriptionOptionInfo?: Events.ecomV1OrderSubscriptionOptionInfo; /** * Subscription settings. */ subscriptionSettings?: Events.ecomV1OrderV1SubscriptionSettings; }; type ecomV1OrderVatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; } /** * [Read more](https://www.wix.com/corvid/reference/wix-ecom-backend.Orders.html#) */ namespace Orders { type ActionEvent = { bodyAsJson?: string; }; type Activity = { /** * Activity creation date and time. */ _createdDate?: Date; /** * Activity ID. */ _id?: string; /** * Activity author's email. */ authorEmail?: string; /** * Custom activity details (optional). `activity.type` must be `CUSTOM_ACTIVITY`. */ customActivity?: Orders.CustomActivity; /** * Merchant comment details (optional). `activity.type` must be `MERCHANT_COMMENT`. */ merchantComment?: Orders.MerchantComment; /** * Additional info about order refunded activity (optional). `activity.type` must be `ORDER_REFUNDED`. */ orderRefunded?: Orders.OrderRefunded; /** * Activity type. */ type?: string; }; type ActivityContentOneOf = { /** * Custom activity details (optional). `activity.type` must be `CUSTOM_ACTIVITY`. */ customActivity?: Orders.CustomActivity; /** * Merchant comment details (optional). `activity.type` must be `MERCHANT_COMMENT`. */ merchantComment?: Orders.MerchantComment; /** * Additional info about order refunded activity (optional). `activity.type` must be `ORDER_REFUNDED`. */ orderRefunded?: Orders.OrderRefunded; }; type AddActivityRequest = { /** * Order ID. */ _id: string; /** * Activity info. */ activity: Orders.PublicActivity; }; type AddActivityResponse = { /** * ID of the added activity. * Use this ID to either [update](https://bo.wix.com/wix-docs/rest/ecommerce/orders/update-activity) or [delete](https://bo.wix.com/wix-docs/rest/ecommerce/orders/delete-activity) the activity. */ activityId?: string; /** * Updated order. */ order?: Orders.Order; }; type AddInternalActivityRequest = { /** * Order ID. */ _id: string; /** * Activity info. */ activity: Orders.InternalActivity; }; type AddInternalActivityResponse = { /** * ID of the added internal activity. * Use this ID to either [update](https://bo.wix.com/wix-docs/rest/ecommerce/orders/update-activity) or [delete](https://bo.wix.com/wix-docs/rest/ecommerce/orders/delete-activity) the activity. */ activityId?: string; /** * Updated order. */ order?: Orders.Order; }; type AdditionalFee = { /** * Additional fee's unique code for future processing. */ code?: string; /** * Name of additional fee. */ name?: string; /** * Additional fee's price. */ price?: Orders.Price; /** * SPI implementer's `appId`. */ providerAppId?: string; /** * Tax details. */ taxDetails?: Orders.ItemTaxFullDetails; }; type Address = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Orders.StreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type AddressWithContact = { /** * Address. */ address?: Orders.Address; /** * Contact details. */ contactDetails?: Orders.FullAddressContactDetails; }; type AggregateOrdersOptions = { /** * This is an object defining aggregation itself */ aggregation: Object; /** * Filter applied to original data */ filter?: Object; }; type AggregateOrdersRequest = { /** * This is an object defining aggregation itself */ aggregation: Object; /** * Filter applied to original data */ filter?: Object; }; type AggregateOrdersResponse = { aggregates?: Object; }; type ApiAddress = { /** * Address line 1 (free text) */ addressLine1?: string; /** * address line */ addressLine2?: string; /** * City name */ city?: string; /** * Company name */ company?: string; /** * Country code (2 letters) */ country?: string; /** * Email address */ email?: string; /** * Addressee name */ fullName?: Orders.FullName; /** * Phone number */ phone?: string; /** * Address line 1 (street) */ street?: Orders.Street; /** * State or district */ subdivision?: string; /** * Tax information (for Brazil only) */ vatId?: Orders.ApiVatId; /** * ZIP/postal code */ zipCode?: string; }; type ApiAddressAddressLine1OptionsOneOf = { /** * Address line 1 (free text) */ addressLine1?: string; /** * Address line 1 (street) */ street?: Orders.Street; }; type ApiVatId = { /** * Customer's tax ID */ number?: string; /** * tax type */ type?: string; }; type ApplicationError = { code?: string; data?: Object; description?: string; }; type AppliedCoupon = { /** * Coupon code */ code?: string; /** * Coupon ID */ couponId?: string; /** * Coupon name */ name?: string; }; type AppliedDiscount = { /** * Applied coupon info. */ coupon?: Orders.Coupon; /** * Automatic Discount */ discountRule?: Orders.DiscountRule; /** * Discount type. * * `"GLOBAL"` - discount applies to entire order. * * `"SPECIFIC-ITEMS"` - discount applies to specific items. * * `"SHIPPING"` - discount applies to shipping. For example, free shipping. */ discountType?: string; /** * IDs of line items discount applies to. */ lineItemIds?: Array; /** * Merchant discount. */ merchantDiscount?: Orders.MerchantDiscount; }; type AppliedDiscountDiscountSourceOneOf = { /** * Applied coupon info. */ coupon?: Orders.Coupon; /** * Automatic Discount */ discountRule?: Orders.DiscountRule; /** * Merchant discount. */ merchantDiscount?: Orders.MerchantDiscount; }; type ArchiveOrderRequest = { /** * Order ID. */ _id: string; }; type ArchiveOrderResponse = { /** * Archived order. */ order?: Orders.Order; }; type Balance = { /** * Balance amount, can be negative. Negative value signifies amount to be refunded * and can happen due to possible overcharge or modified manual order. */ amount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; }; type BalanceSummary = { balance?: Orders.Balance; }; type BillingInfo = { /** * Full billing address */ address?: Orders.ApiAddress; /** * Deprecated (use paymentProviderTransactionId instead) */ externalTransactionId?: string; /** * Payment date */ paidDate?: Date; /** * Transaction ID from payment gateway (e.g., Wix Payments) */ paymentGatewayTransactionId?: string; /** * Payment method used for this order */ paymentMethod?: string; /** * Transaction ID from payment provider (e.g., PayPal, Square, Stripe) transaction ID */ paymentProviderTransactionId?: string; /** * Whether order can be refunded by payment provider (manually or automatic) */ refundableByPaymentProvider?: boolean; }; type BulkActionMetadata = { /** * Number of items that couldn't be processed. */ totalFailures?: number; /** * Number of items that were successfully processed. */ totalSuccesses?: number; /** * Number of failures without details because detailed failure threshold was exceeded. */ undetailedFailures?: number; }; type BulkArchiveOrdersByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type BulkArchiveOrdersByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkArchiveOrdersOptions = { /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkArchiveOrdersRequest = { /** * IDs of orders to archive. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkArchiveOrdersResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkMarkAsFulfilledByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type BulkMarkAsFulfilledByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkMarkAsFulfilledOptions = { /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkMarkAsFulfilledRequest = { /** * IDs of orders to be marked as fulfilled. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkMarkAsFulfilledResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkMarkAsUnfulfilledByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type BulkMarkAsUnfulfilledByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkMarkAsUnfulfilledOptions = { /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkMarkAsUnfulfilledRequest = { /** * IDs of orders to be marked as not fulfilled. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkMarkAsUnfulfilledResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkMarkOrdersAsPaidRequest = { /** * IDs of orders to mark as paid. */ ids: Array; }; type BulkMarkOrdersAsPaidResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by the bulk action. * The Order entity within the results optimistically changes its payment status to paid, however this process is async. */ results?: Array; }; type BulkOrderResult = { /** * Updated item. Optional - returned only if requested with `return_full_entity` set to `true`. */ item?: Orders.Order; /** * Item metadata. */ itemMetadata?: Orders.ItemMetadata; }; type BulkUnArchiveOrdersByFilterRequest = { /** * Filter object. Learn more about supported filters [here](https://bo.wix.com/wix-docs/rest/ecommerce/orders/filter-and-sort). */ filter: Object; }; type BulkUnArchiveOrdersByFilterResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BulkUnArchiveOrdersOptions = { /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkUnArchiveOrdersRequest = { /** * IDs or orders to unarchive. */ ids: Array; /** * Whether to return the full updated order entities in the response. */ returnFullEntity?: boolean; }; type BulkUnArchiveOrdersResponse = { /** * Bulk action metadata. */ bulkActionMetadata?: Orders.BulkActionMetadata; /** * Items updated by bulk action. */ results?: Array; }; type BuyerInfo = { /** * Contact ID. Auto-created if one does not yet exist. For more information, see [Contacts API](https://dev.wix.com/api/rest/contacts/contacts/introduction). */ contactId?: string; /** * Buyer email address. */ email?: string; /** * Member ID (if site visitor is a site member). */ memberId?: string; /** * Visitor ID (if site visitor is not a member). */ visitorId?: string; }; type BuyerInfoIdOneOf = { /** * Member ID (if site visitor is a site member). */ memberId?: string; /** * Visitor ID (if site visitor is not a member). */ visitorId?: string; }; type BuyerInfoUpdate = { /** * Contact ID. */ contactId?: string; /** * Email associated with the buyer. */ email?: string; }; type Cancel = {}; type CancelOrderOptions = { /** * Custom note to be added to the email (optional). */ customMessage?: string; /** * Whether to restock all items in the order. */ restockAllItems?: boolean; /** * Whether to send an order canceled email to the buyer. */ sendOrderCanceledEmail?: boolean; }; type CancelOrderRequest = { /** * Order ID. */ _id: string; /** * Custom note to be added to the email (optional). */ customMessage?: string; /** * Whether to restock all items in the order. */ restockAllItems?: boolean; /** * Whether to send an order canceled email to the buyer. */ sendOrderCanceledEmail?: boolean; }; type CancelOrderResponse = { /** * Canceled order. */ order?: Orders.Order; }; type CatalogReference = { /** * App ID of the catalog the item comes from. For example, the Wix Stores `appId` is `"1380b703-ce81-ff05-f115-39571d94dfcd"`. */ appId?: string; /** * ID of the item within its catalog. For example, `productId` for Wix Stores. */ catalogItemId?: string; /** * Additional info in key:value form. For example, for a product variant from Wix Stores Catalog, `options` field would hold something like one of the following: * + `{"Size": "M", "Color": "Red"}` * + `{"variantId": ""}`. */ options?: Object; }; type ChannelInfo = { /** * Reference to an order ID from an external system. */ externalOrderId?: string; /** * URL to the order in the external system. */ externalOrderUrl?: string; /** * Sales channel that submitted the order. */ type?: string; }; type Color = { /** * Optional - HEX or RGB color code for display. */ code?: string; /** * Optional - Description line color name in site's default language. */ original?: string; /** * Optional - Translated description line color name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type Complete = {}; type ContinueSideEffectsFlowInLegacyData = { orderId?: string; ordersExperiments?: Orders.OrdersExperiments; storeId?: string; }; type Coupon = { /** * Coupon ID. */ _id?: string; /** * Coupon value. */ amount?: Orders.Price; /** * Coupon code. */ code?: string; /** * Coupon name. */ name?: string; }; type CreateOrderRequest = { /** * Order info. */ order: Orders.Order; }; type CreateOrderResponse = { /** * Newly created order. */ order?: Orders.Order; }; type CreatePaymentGatewayOrderRequest = { /** * eCom Order ID */ ecomOrderId: string; }; type CreatePaymentGatewayOrderResponse = { /** * ID of the order created in the payment gateway */ paymentGatewayOrderId?: string; }; type CreatedBy = { /** * App ID - when the order was created by an external application. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type CreatedByStringOneOf = { /** * App ID - when the order was created by an external application. */ appId?: string; /** * Member ID - when the order was created by a **logged in** site visitor. */ memberId?: string; /** * User ID - when the order was created by a Wix user on behalf of a buyer. * For example, via POS (point of service). */ userId?: string; /** * Visitor ID - when the order was created by a site visitor that was **not** logged in. */ visitorId?: string; }; type CursorPaging = { /** * Pointer to the next or previous page in the list of results. */ cursor?: string; /** * Number of items to load. */ limit?: number; }; type Cursors = { /** * Cursor pointing to next page in the list of results. */ next?: string; /** * Cursor pointing to previous page in the list of results. */ prev?: string; }; type CustomActivity = { /** * Additional data in key-value form. For example, `{ "Ticket number": "123456" }`. */ additionalData?: Record; /** * ID of the app that created the custom activity. */ appId?: string; /** * Custom activity type. For example, `"Ticket number set"`. */ type?: string; }; type CustomField = { /** * Custom field title. */ title?: string; /** * Translated custom field title. */ translatedTitle?: string; /** * Custom field value. */ value?: any; }; type DecrementData = { /** * Line item quantity being decremented. */ decrementBy?: number; /** * ID of the line item being decremented. */ lineItemId?: string; /** * Whether to restock the line item (triggers inventory update). */ restock?: boolean; }; type DecrementItemsQuantityRequest = { /** * Order ID */ _id: string; /** * Which items to decrement, and how much to decrement from each one */ decrementData: Array; }; type DecrementItemsQuantityResponse = { /** * Updated order data */ order?: Orders.Order; }; type DeleteActivityIdentifiers = { /** * Order ID. */ _id: string; /** * ID of the activity to delete. */ activityId: string; }; type DeleteActivityRequest = { /** * Order ID. */ _id: string; /** * ID of the activity to delete. */ activityId: string; }; type DeleteActivityResponse = { /** * Updated order. */ order?: Orders.Order; }; type DeliveryLogistics = { /** * Latest expected delivery date. */ deliverByDate?: Date; /** * Expected delivery time in free text. For example, `"3-5 business days"`. */ deliveryTime?: string; /** * Instructions for carrier. For example, `"Please knock on the door. If unanswered, please call contact number. Thanks."`. */ instructions?: string; /** * Pickup details. */ pickupDetails?: Orders.PickupDetails; /** * Shipping address and contact details. */ shippingDestination?: Orders.AddressWithContact; }; type DeliveryLogisticsAddressOneOf = { /** * Pickup details. */ pickupDetails?: Orders.PickupDetails; /** * Shipping address and contact details. */ shippingDestination?: Orders.AddressWithContact; }; type DescriptionLine = { /** * Description line color value. */ colorInfo?: Orders.Color; /** * Description line name. */ name?: Orders.DescriptionLineName; /** * Description line plain text value. */ plainText?: Orders.PlainTextValue; }; type DescriptionLineDescriptionLineValueOneOf = {}; type DescriptionLineName = { /** * Optional - Description line name in site's default language. */ original?: string; /** * Optional - Translated description line item according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type DescriptionLineValueOneOf = { /** * Description line color value. */ colorInfo?: Orders.Color; /** * Description line plain text value. */ plainText?: Orders.PlainTextValue; }; type DiffmatokyPayload = { compareChannel?: string; entityId?: string; errorInformation?: Orders.ErrorInformation; left?: string; right?: string; tags?: Array; }; type DigitalFile = { /** * Link expiration time and date. */ expirationDate?: Date; /** * ID of the secure file in media. */ fileId?: string; /** * Link will exist after the digital links have been generated on the order. */ link?: string; }; type DiscountRule = { /** * Discount rule ID */ _id?: string; /** * Discount value. */ amount?: Orders.Price; /** * Discount rule name */ name?: Orders.DiscountRuleName; }; type DiscountRuleName = { /** * Original discount rule name (in site's default language). */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type DomainEvent = { /** * random GUID so clients can tell if event was already handled */ _id?: string; actionEvent?: Orders.ActionEvent; createdEvent?: Orders.EntityCreatedEvent; deletedEvent?: Orders.EntityDeletedEvent; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** * The time of the event. Useful if there was a delay in dipatching */ eventTime?: Date; extendedFieldsUpdatedEvent?: Orders.ExtendedFieldsUpdatedEvent; /** * If present, indicates the action that triggered the event. */ originatedFrom?: string; /** * This is top level to ease client code dipatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean; updatedEvent?: Orders.EntityUpdatedEvent; }; type DomainEventBodyOneOf = { actionEvent?: Orders.ActionEvent; createdEvent?: Orders.EntityCreatedEvent; deletedEvent?: Orders.EntityDeletedEvent; extendedFieldsUpdatedEvent?: Orders.ExtendedFieldsUpdatedEvent; updatedEvent?: Orders.EntityUpdatedEvent; }; type DownloadLinkSent = {}; type EmailEdited = {}; type Empty = {}; type EntityCreatedEvent = { entityAsJson?: string; }; type EntityDeletedEvent = {}; type EntityUpdatedEvent = { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; }; type ErrorInformation = { stackTrace?: string; }; type ExtendedFieldsUpdatedEvent = { currentEntityAsJson?: string; }; type FulfillerEmailSent = {}; type FulfillmentStatusUpdated = { /** * the action that caused this update */ action?: string; /** * the new status (after the update) */ newFulfillmentStatus?: string; /** * The order that was updated */ order?: Orders.Order; /** * The previous status (before the update) */ previousFulfillmentStatus?: string; }; type FullAddressContactDetails = { /** * Company name. */ company?: string; /** * First name. */ firstName?: string; /** * Last name. */ lastName?: string; /** * Phone number. */ phone?: string; /** * Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set - UNSPECIFIED is not allowed. */ vatId?: Orders.VatId; }; type FullName = { /** * Customer's first name */ firstName?: string; /** * Customer's last name */ lastName?: string; }; type GetOrderRequest = { /** * ID of the order to retrieve. */ _id: string; }; type GetOrderResponse = { /** * The requested order. */ order?: Orders.Order; }; type GetPaymentCollectabilityStatusRequest = { /** * Ecom order ID. */ ecomOrderId: string; }; type GetPaymentCollectabilityStatusResponse = { /** * Collectable order amount */ amount?: Orders.Price; /** * Payment collectability status */ status?: string; }; type GetShipmentsRequest = { _id: string; }; type GetShipmentsResponse = { shipmentIds?: Array; }; type IndexingMessage = { _id?: string; opType?: number; requiredVersions?: Array; }; type InternalActivity = { /** * Internal activity creation date and time. */ _createdDate?: Date; /** * Internal activity ID. */ _id?: string; /** * Internal activity author's email. */ authorEmail?: string; /** * Download link was sent (relevant for orders with digital line items). */ downloadLinkSent?: Orders.DownloadLinkSent; /** * Order email was updated. */ emailEdited?: Orders.EmailEdited; /** * Email sent to fulfiller. */ fulfillerEmailSent?: Orders.FulfillerEmailSent; /** * Invoice was added to order. */ invoiceAdded?: Orders.InvoiceAdded; /** * Invoice sent to customer via email. */ invoiceSent?: Orders.InvoiceSent; /** * New exchange order created. */ newExchangeOrderCreated?: Orders.NewExchangeOrderCreated; /** * Order canceled. */ orderCanceled?: Orders.OrderCanceled; /** * Order created as a result of items exchange. */ orderCreatedFromExchange?: Orders.OrderCreatedFromExchange; /** * Order shipping status set as fulfilled. */ orderFulfilled?: Orders.OrderFulfilled; /** * Order shipping status set as not fulfilled. */ orderNotFulfilled?: Orders.OrderNotFulfilled; /** * Order paid. Either by the store owner (for offline orders), or when an online transaction was confirmed. */ orderPaid?: Orders.OrderPaid; /** * Order partially paid. During the checkout for orders with deposit items. */ orderPartiallyPaid?: Orders.OrderPartiallyPaid; /** * Order placed. */ orderPlaced?: Orders.OrderPlaced; /** * Order refunded. */ orderRefunded?: Orders.OrderRefunded; /** * Email notification for pickup sent. */ pickupReadyEmailSent?: Orders.PickupReadyEmailSent; /** * Shipping address was updated. */ shippingAddressEdited?: Orders.ShippingAddressEdited; /** * An email confirmation of order shipment was sent. */ shippingConfirmationEmailSent?: Orders.ShippingConfirmationEmailSent; /** * Shipping tracking link added to order. */ trackingLinkAdded?: Orders.TrackingLinkAdded; /** * Shipping tracking number added to order. */ trackingNumberAdded?: Orders.TrackingNumberAdded; /** * Shipping tracking number was edited. */ trackingNumberEdited?: Orders.TrackingNumberEdited; }; type InternalActivityContentOneOf = { /** * Download link was sent (relevant for orders with digital line items). */ downloadLinkSent?: Orders.DownloadLinkSent; /** * Order email was updated. */ emailEdited?: Orders.EmailEdited; /** * Email sent to fulfiller. */ fulfillerEmailSent?: Orders.FulfillerEmailSent; /** * Invoice was added to order. */ invoiceAdded?: Orders.InvoiceAdded; /** * Invoice sent to customer via email. */ invoiceSent?: Orders.InvoiceSent; /** * New exchange order created. */ newExchangeOrderCreated?: Orders.NewExchangeOrderCreated; /** * Order canceled. */ orderCanceled?: Orders.OrderCanceled; /** * Order created as a result of items exchange. */ orderCreatedFromExchange?: Orders.OrderCreatedFromExchange; /** * Order shipping status set as fulfilled. */ orderFulfilled?: Orders.OrderFulfilled; /** * Order shipping status set as not fulfilled. */ orderNotFulfilled?: Orders.OrderNotFulfilled; /** * Order paid. Either by the store owner (for offline orders), or when an online transaction was confirmed. */ orderPaid?: Orders.OrderPaid; /** * Order partially paid. During the checkout for orders with deposit items. */ orderPartiallyPaid?: Orders.OrderPartiallyPaid; /** * Order placed. */ orderPlaced?: Orders.OrderPlaced; /** * Order refunded. */ orderRefunded?: Orders.OrderRefunded; /** * Email notification for pickup sent. */ pickupReadyEmailSent?: Orders.PickupReadyEmailSent; /** * Shipping address was updated. */ shippingAddressEdited?: Orders.ShippingAddressEdited; /** * An email confirmation of order shipment was sent. */ shippingConfirmationEmailSent?: Orders.ShippingConfirmationEmailSent; /** * Shipping tracking link added to order. */ trackingLinkAdded?: Orders.TrackingLinkAdded; /** * Shipping tracking number added to order. */ trackingNumberAdded?: Orders.TrackingNumberAdded; /** * Shipping tracking number was edited. */ trackingNumberEdited?: Orders.TrackingNumberEdited; }; type InvoiceAdded = {}; type InvoiceSent = {}; type ItemMetadata = { /** * Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */ _id?: string; /** * Details about the error in case of failure. */ error?: Orders.ApplicationError; /** * Index of the item within the request array. Allows for correlation between request and response items. */ originalIndex?: number; /** * Whether the requested action was successful for this item. When `false`, the `error` field is populated. */ success?: boolean; }; type ItemTaxFullDetails = { /** * Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`. */ taxRate?: string; /** * Taxable amount of this line item. */ taxableAmount?: Orders.Price; /** * The calculated tax, based on the `taxableAmount` and `taxRate`. */ totalTax?: Orders.Price; }; type ItemType = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type ItemTypeItemTypeDataOneOf = { /** * Custom item type. */ custom?: string; /** * Preset item type. */ preset?: string; }; type LineItemExchangeData = { /** * ID of the exchanged line item. */ lineItemId?: string; /** * Line item quantity being exchanged. */ quantity?: number; }; type LineItemUpdate = { /** * Description lines' info. * If description line already exists for this name, it will be replaced. */ descriptionLines?: Array; /** * Line item ID. */ lineItemId?: string; }; type MarkAsFulfilledRequest = { /** * Order ID. */ _id: string; }; type MarkAsFulfilledResponse = { /** * Updated order. */ order?: Orders.Order; }; type MarkAsUnfulfilledRequest = { /** * Order ID. */ _id: string; }; type MarkAsUnfulfilledResponse = { /** * Updated order. */ order?: Orders.Order; }; type MarkOrderAsPaidRequest = { /** * Order ID. */ _id: string; }; type MarkOrderAsPaidResponse = { /** * Updated order. */ order?: Orders.Order; }; type MarkOrderAsSeenByHumanRequest = { /** * Order ID. */ _id: string; }; type MarkOrderAsSeenByHumanResponse = { /** * Updated order. */ order?: Orders.Order; }; type MerchantComment = { /** * Merchant comment message. */ message?: string; }; type MerchantDiscount = { /** * Discount amount. */ amount?: Orders.Price; /** * Discount description as free text (optional). */ description?: string; /** * Pre-defined discount reason (optional). * * `"ITEMS_EXCHANGE"` - exchange balance acquired as a result of items exchange. */ discountReason?: string; }; type MerchantDiscountMerchantDiscountReasonOneOf = { /** * Discount description as free text (optional). */ description?: string; /** * Pre-defined discount reason (optional). * * `"ITEMS_EXCHANGE"` - exchange balance acquired as a result of items exchange. */ discountReason?: string; }; type NewExchangeOrderCreated = { /** * ID of the new order created as a result of an exchange of items. */ exchangeOrderId?: string; /** * IDs of the items that were exchanged. */ lineItems?: Array; }; type Order = { /** * Date and time the order was created. */ _createdDate?: Date; /** * Order ID. */ _id?: string; /** * Date and time of order's latest update. */ _updatedDate?: Date; /** * Order activities. */ activities?: Array; /** * Additional fees applied to the order. */ additionalFees?: Array; /** * Applied discounts. */ appliedDiscounts?: Array; /** * Whether order is archived. */ archived?: boolean; /** * Order attribution source. */ attributionSource?: string; /** * Billing address and contact details. */ billingInfo?: Orders.AddressWithContact; /** * Buyer information. */ buyerInfo?: Orders.BuyerInfo; /** * Language for communication with the buyer. Defaults to the site language. * For a site that supports multiple languages, this is the language the buyer selected. */ buyerLanguage?: string; /** * [Buyer note](https://support.wix.com/en/article/wix-stores-viewing-buyer-notes) left by the customer. */ buyerNote?: string; /** * Information about the sales channel that submitted this order. */ channelInfo?: Orders.ChannelInfo; /** * Checkout ID. */ checkoutId?: string; /** * ID of the order's initiator. */ createdBy?: Orders.CreatedBy; /** * Currency used for pricing in this store. */ currency?: string; /** * Custom fields. */ customFields?: Array; /** * Order fulfillment status. */ fulfillmentStatus?: string; /** * Order line items. */ lineItems?: Array; /** * Order number displayed in the site owner's business manager (auto-generated). */ number?: string; /** * Order payment status. * + `NOT_PAID` - This can be an order made online, but not yet paid. In such cases `order.status` will be `INITIALIZED`. * + This status also applies when an offline order needs to be manually marked as paid. In such cases `order.status` will be `APPROVED`. * + `PAID` - All payments associated with this order are paid. For online payments: [`payment.regularPaymentDetails.status: APPROVED`](https://bo.wix.com/wix-docs/rest/ecommerce/order-payments/order-transactions-object). For gift cards: [`payment.giftCardPaymentDetails.voided: false`](https://bo.wix.com/wix-docs/rest/ecommerce/order-payments/order-transactions-object). * + `PARTIALLY_REFUNDED` - Order was refunded, but refund amount is less than order total price. * + `FULLY_REFUNDED` - Order fully refunded. Refund amount equals total price. * + `PENDING` - Payments received but not yet confirmed by the payment provider. * + `PARTIALLY_PAID` - At least one payment was received and approved, covering less than total price amount. */ paymentStatus?: string; /** * Order price summary. */ priceSummary?: Orders.PriceSummary; /** * Whether a human has seen the order. Set when an order is clicked on in the Business Manager. */ seenByAHuman?: boolean; /** * Shipping info and selected shipping option details. */ shippingInfo?: Orders.ShippingInformation; /** * Site language in which original values are shown. */ siteLanguage?: string; /** * Order status. * + `INITIALIZED` - Order was created, but not yet approved or declined. * + `APPROVED` - Order was approved. This happens when either the online payment succeeded or the order is an offline order. * + Once an order is approved, many side effects are triggered. For example, holding of stock in the inventory and sending of notification emails. * + `CANCELED` - Order was canceled by the user. */ status?: string; /** * Whether tax is included in line item prices. */ taxIncludedInPrices?: boolean; /** * Tax summary. */ taxSummary?: Orders.TaxSummary; /** * Weight measurement unit - defaults to site's weight unit. */ weightUnit?: string; }; type OrderApproved = { /** * The order that was updated */ order?: Orders.Order; }; type OrderCanceled = {}; type OrderCanceledEventOrderCanceled = { /** * Personal note added to the email */ customMessage?: string; /** * The order that was cancelled */ order?: Orders.Order; /** * Should restock all items on that order */ restockAllItems?: boolean; /** * Should send a confirmation mail to the customer */ sendOrderCanceledEmail?: boolean; }; type OrderCreated = { /** * Order archive status */ archived?: boolean; /** * Customer information */ buyerInfo?: Orders.V2BuyerInfo; /** * Currency used for pricing in this store */ currency?: string; /** * Order creation date */ dateCreated?: Date; /** * Order fulfillment status */ fulfillmentStatus?: string; /** * ID displayed in the owner's store (auto generated) */ number?: string; /** * Order ID (auto generated upon order creation) */ orderId?: string; /** * Order payment status */ paymentStatus?: string; /** * Whether the order was read by the store owner */ read?: boolean; /** * Totals for order's line items */ totals?: Orders.Totals; /** * Weight unit used in this store */ weightUnit?: string; }; type OrderCreatedFromExchange = { /** * ID of the original order for which the exchange happened. */ originalOrderId?: string; }; type OrderFulfilled = {}; type OrderItemsRestocked = { /** * The order which items were restocked */ order?: Orders.Order; /** * Restocked items and quantities */ restockItems?: Array; }; type OrderLineItem = { /** * Line item ID. */ _id?: string; /** * Catalog and item reference. Holds IDs for the item and the catalog it came from, as well as further optional info. */ catalogReference?: Orders.CatalogReference; /** * Item's price amount to be charged during checkout, relevant for items with payment option DEPOSIT_ONLINE */ depositAmount?: Orders.Price; /** * Line item description lines. Used for display purposes for the cart, checkout and order. */ descriptionLines?: Array; /** * Fulfiller ID. Field is empty when the line item is self-fulfilled. * To get fulfillment information, pass this order's ID to [List Fulfillments For Single Order](https://bo.wix.com/wix-docs/rest/ecommerce/order-fulfillments/list-fulfillments-for-single-order). */ fulfillerId?: string; /** * Line item image. */ image?: string; /** * Item type. Either a preset type or custom. */ itemType?: Orders.ItemType; /** * Type of selected payment option for current item. Defaults to `FULL_PAYMENT_ONLINE`. * + `FULL_PAYMENT_ONLINE` - The entire payment for this item happens as part of the checkout. * + `FULL_PAYMENT_OFFLINE` - The entire payment for this item happens after the checkout. For example, when using cash, check, or other offline payment methods. * + `MEMBERSHIP` - Payment for this item is done by charging a membership. When this option is used, `lineItem.price.amount` is 0. * + `DEPOSIT_ONLINE` - Partial payment for the given item to be paid upfront during the checkout. Eligible for catalog items with type `DEPOSIT_ONLINE` only. */ paymentOption?: string; /** * Physical properties of the item. When relevant, contains information such as SKU and item weight. */ physicalProperties?: Orders.PhysicalProperties; /** * Line item price after line item discounts for display purposes. */ price?: Orders.Price; /** * Line item price before line item discounts for display purposes. Defaults to `price` when not provided. */ priceBeforeDiscounts?: Orders.Price; /** * Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: Orders.PriceDescription; /** * Item name. * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: Orders.ProductName; /** * Line item quantity. */ quantity?: number; /** * quantity of inventory requested to be returned. Whether to restock or ignore the request is up the vertical. */ restockQuantity?: number; /** * Subscription info. */ subscriptionInfo?: Orders.SubscriptionInfo; /** * Tax details for this line item. */ taxDetails?: Orders.ItemTaxFullDetails; /** * Total discount for this line item's entire quantity. */ totalDiscount?: Orders.Price; /** * Total price after all discounts and tax. */ totalPriceAfterTax?: Orders.Price; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Orders.Price; }; type OrderNotFulfilled = {}; type OrderPaid = {}; type OrderPartiallyPaid = {}; type OrderPlaced = {}; type OrderRefunded = { /** * Refund amount. */ amount?: Orders.Price; /** * Whether order was refunded manually. For example, via payment provider or using cash. */ manual?: boolean; /** * Reason for refund. */ reason?: string; }; type OrdersExperiments = { epCommitTax?: boolean; moveBuyerOrderConfirmationEmailToEp?: boolean; moveMerchantEmailToEp?: boolean; producedByEpBridge?: boolean; }; type PaymentStatusUpdated = { /** * The order that was updated */ order?: Orders.Order; /** * The previous status (before the update) */ previousPaymentStatus?: string; }; type PhysicalProperties = { /** * Whether this line item is shippable. */ shippable?: boolean; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). */ sku?: string; /** * Line item weight. Measurement unit (KG or LB) is taken from `order.weightUnit`. */ weight?: number; }; type PickupAddress = { /** * Main address line (usually street name and number). */ addressLine1?: string; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. */ addressLine2?: string; /** * City name. */ city?: string; /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. */ country?: string; /** * Postal or zip code. */ postalCode?: string; /** * Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: Orders.StreetAddress; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. */ subdivision?: string; }; type PickupDetails = { /** * Pickup address. */ address?: Orders.PickupAddress; /** * Pickup method */ pickupMethod?: string; }; type PickupReadyEmailSent = {}; type PlainTextValue = { /** * Optional - Description line plain text value in site's default language. */ original?: string; /** * Optional - Translated description line plain text value according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type PlatformPaging = { /** * Number of items to load. */ limit?: number; /** * Number of items to skip in the current sort order. */ offset?: number; }; type PlatformPagingMetadata = { /** * The number of items returned in this response. */ count?: number; /** * Cursors to navigate through result pages. Returned if cursor paging was used. */ cursors?: Orders.Cursors; /** * The offset which was requested. Returned if offset paging was used. */ offset?: number; /** * The total number of items that match the query. Returned if offset paging was used. */ total?: number; }; type PlatformQuery = { /** * Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: Orders.CursorPaging; /** * Filter object. */ filter?: Object; /** * Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: Orders.PlatformPaging; /** * Sorting options. For example, `[{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}]`. */ sort?: Array; }; type PlatformQueryPagingMethodOneOf = { /** * Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: Orders.CursorPaging; /** * Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: Orders.PlatformPaging; }; type PreparePaymentCollectionRequest = { /** * Amount to collect */ amount: Orders.Price; /** * Ecom order ID. */ ecomOrderId: string; }; type PreparePaymentCollectionResponse = { /** * Payment gateway order id which is associated with given payment */ paymentGatewayOrderId?: string; }; type PreviewBuyerConfirmationEmailRequest = {}; type PreviewBuyerConfirmationEmailResponse = { emailPreview?: string; }; type PreviewBuyerPaymentsReceivedEmailRequest = {}; type PreviewBuyerPaymentsReceivedEmailResponse = { emailPreview?: string; }; type PreviewBuyerPickupConfirmationEmailRequest = {}; type PreviewBuyerPickupConfirmationEmailResponse = { emailPreview?: string; }; type PreviewCancelEmailOptions = { /** * Personal note added to the email (optional) */ customMessage?: string; }; type PreviewCancelEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; orderId: string; }; type PreviewCancelEmailResponse = { emailPreview?: string; }; type PreviewCancelRefundEmailOptions = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * Refund amount */ refundAmount?: Orders.Price; }; type PreviewCancelRefundEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; orderId: string; /** * Refund amount */ refundAmount?: Orders.Price; }; type PreviewCancelRefundEmailResponse = { emailPreview?: string; }; type PreviewEmailByTypeRequest = { /** * Suppoerted values: * - `'DOWNLOAD_LINKS'` * - `'ORDER_PLACED'` * - `'ORDER_READY_FOR_PICKUP'` * - `'ORDER_SHIPPED'` */ emailType: string; }; type PreviewEmailByTypeResponse = { emailPreview?: string; }; type PreviewRefundEmailOptions = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * Refund business details */ details?: Orders.RefundDetails; /** * Refund amount */ refundAmount: Orders.Price; }; type PreviewRefundEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * Refund business details */ details?: Orders.RefundDetails; orderId: string; /** * Refund amount */ refundAmount: Orders.Price; }; type PreviewRefundEmailResponse = { emailPreview?: string; }; type PreviewResendDownloadLinksEmailRequest = {}; type PreviewResendDownloadLinksEmailResponse = { emailPreview?: string; }; type PreviewShippingConfirmationEmailRequest = {}; type PreviewShippingConfirmationEmailResponse = { emailPreview?: string; }; type Price = { /** * Amount. */ amount?: string; /** * Amount formatted with currency symbol. */ formattedAmount?: string; }; type PriceDescription = { /** * Required** - Original price description (in site's default language). */ original?: string; /** * Optional - Translated product name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type PriceSummary = { /** * Total calculated discount value. */ discount?: Orders.Price; /** * Total shipping price, before discounts and before tax. */ shipping?: Orders.Price; /** * Subtotal of all the line items, before discounts and before tax. */ subtotal?: Orders.Price; /** * Total tax on this order. */ tax?: Orders.Price; /** * Order’s total price after discounts and tax. */ total?: Orders.Price; /** * Total price of additional fees. */ totalAdditionalFees?: Orders.Price; /** * Deprecated - use `total` instead. */ totalPrice?: Orders.Price; }; type ProductName = { /** * Required** - Original item name (in site's default language). */ original?: string; /** * Optional - Translated item name according to buyer language. Defaults to `original` when not provided. */ translated?: string; }; type PublicActivity = { /** * Custom activity details. */ customActivity?: Orders.CustomActivity; /** * Merchant commment. */ merchantComment?: Orders.MerchantComment; }; type PublicActivityContentOneOf = { /** * Custom activity details. */ customActivity?: Orders.CustomActivity; /** * Merchant commment. */ merchantComment?: Orders.MerchantComment; }; type QueryOrderRequest = { /** * Query options. */ query?: Orders.PlatformQuery; }; type QueryOrderResponse = { /** * Details on the paged set of results returned. */ metadata?: Orders.PlatformPagingMetadata; /** * List of orders. */ orders?: Array; }; type RefundDetails = { /** * Refunded line items and quantities. */ items?: Array; /** * Reason for refund, given by user (optional). */ reason?: string; /** * Whether shipping rate is also refunded. */ shippingIncluded?: boolean; }; type RefundItem = { /** * ID of the line item being refunded. */ lineItemId?: string; /** * Line item quantity being refunded. */ quantity?: number; }; type Reschedule = { executeAt?: Date; payload?: string; }; type RestockItem = { /** * ID of the line item being restocked. */ lineItemId?: string; /** * Line item quantity being restocked. */ quantity?: number; }; type SendBuyerConfirmationEmailRequest = { orderId: string; }; type SendBuyerConfirmationEmailResponse = {}; type SendBuyerPaymentsReceivedEmailRequest = { orderId: string; }; type SendBuyerPaymentsReceivedEmailResponse = {}; type SendBuyerPickupConfirmationEmailRequest = { orderId: string; }; type SendBuyerPickupConfirmationEmailResponse = {}; type SendBuyerShippingConfirmationEmailRequest = { orderId: string; }; type SendBuyerShippingConfirmationEmailResponse = {}; type SendCancelRefundEmailOptions = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * Refund amount */ refundAmount: Orders.Price; }; type SendCancelRefundEmailRequest = { /** * Personal note added to the email (optional) */ customMessage?: string; /** * The ID of order that is canceled/refunded */ orderId: string; /** * Refund amount */ refundAmount: Orders.Price; }; type SendCancelRefundEmailResponse = {}; type SendMerchantOrderReceivedNotificationRequest = { orderId: string; }; type SendMerchantOrderReceivedNotificationResponse = {}; type SendOrderPaymentReceivedEmail = { orderId?: string; storeId?: string; }; type ShippingAddressEdited = {}; type ShippingConfirmationEmailSent = {}; type ShippingInformation = { /** * App Def Id of external provider which was a source of shipping info */ carrierId?: string; /** * Unique code (or ID) of selected shipping option. For example, `"usps_std_overnight"``. */ code?: string; /** * Shipping costs. */ cost?: Orders.ShippingPrice; /** * Shipping logistics. */ logistics?: Orders.DeliveryLogistics; /** * Shipping region. */ region?: Orders.ShippingRegion; /** * Shipping option title. * For example, `"USPS Standard Overnight Delivery"`, `"Standard"` or `"First-Class Package International"`. */ title?: string; }; type ShippingPrice = { /** * Shipping discount before tax. */ discount?: Orders.Price; /** * Shipping price for display purposes. */ price?: Orders.Price; /** * Tax details. */ taxDetails?: Orders.ItemTaxFullDetails; /** * Shipping price after all discounts (if any exist), and after tax. */ totalPriceAfterTax?: Orders.Price; /** * Deprecated - please use `total_price_after_tax` minus `tax_details.total_tax` instead. */ totalPriceBeforeTax?: Orders.Price; }; type ShippingRegion = { /** * Name of shipping region. For example, `"Metropolitan London"`, or `"Outer Melbourne suburbs"`. */ name?: string; }; type SnapshotMessage = { _id?: string; opType?: number; }; type Sorting = { /** * Name of the field to sort by. */ fieldName?: string; /** * Sort order. */ order?: string; }; type Street = { /** * Street name */ name?: string; /** * Street number */ number?: string; }; type StreetAddress = { /** * Street name. */ name?: string; /** * Street number. */ number?: string; }; type SubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`. */ cycleNumber?: number; /** * Subscription option description. For example, `"1kg of selected coffee, once a month"`. */ subscriptionOptionDescription?: string; /** * Subscription option title. For example, `"Monthly coffee Subscription"`. */ subscriptionOptionTitle?: string; /** * Subscription detailed information. */ subscriptionSettings?: Orders.SubscriptionSettings; }; type SubscriptionOptionInfo = { /** * Subscription option description. */ description?: string; /** * Subscription option title. */ title?: string; }; type SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type Task = { executeAt?: Date; key?: Orders.TaskKey; payload?: string; }; type TaskAction = { cancel?: Orders.Cancel; complete?: Orders.Complete; reschedule?: Orders.Reschedule; }; type TaskActionActionOneOf = { cancel?: Orders.Cancel; complete?: Orders.Complete; reschedule?: Orders.Reschedule; }; type TaskKey = { appId?: string; instanceId?: string; subjectId?: string; }; type TaxSummary = { /** * Total tax. */ totalTax?: Orders.Price; }; type Totals = { /** * Total calculated discount value. */ discount?: string; /** * Total calculated gift card value. */ giftCard?: string; /** * Total number of line items. */ quantity?: number; /** * Total refund. */ refund?: string; /** * Total shipping price, before tax. */ shipping?: string; /** * Subtotal of all the line items, before tax. */ subtotal?: string; /** * Total tax. */ tax?: string; /** * Total price charged. */ total?: string; /** * Total items weight. */ weight?: string; }; type TrackingLinkAdded = {}; type TrackingNumberAdded = {}; type TrackingNumberEdited = {}; type TriggerSideEffectsFromLegacyData = { orderId?: string; ordersExperiments?: Orders.OrdersExperiments; storeId?: string; }; type UnArchiveOrderRequest = { /** * Order ID. */ _id: string; }; type UnArchiveOrderResponse = { /** * Unarchived order. */ order?: Orders.Order; }; type UpdateActivityIdentifiers = { /** * Order ID. */ _id: string; /** * ID of the activity to update. */ activityId: string; }; type UpdateActivityRequest = { /** * Order ID. */ _id: string; /** * Activity info. */ activity: Orders.PublicActivity; /** * ID of the activity to update. */ activityId: string; }; type UpdateActivityResponse = { /** * Updated order. */ order?: Orders.Order; }; type UpdateBillingContactDetailsOptions = { /** * Contact details. */ addressContactDetails?: Orders.FullAddressContactDetails; }; type UpdateBillingContactDetailsRequest = { /** * Order ID. */ _id: string; /** * Contact details. */ addressContactDetails?: Orders.FullAddressContactDetails; }; type UpdateBillingContactDetailsResponse = { /** * Updated order. */ order?: Orders.Order; }; type UpdateBuyerInfoOptions = { /** * Buyer info. */ buyerInfo?: Orders.BuyerInfoUpdate; }; type UpdateBuyerInfoRequest = { /** * Order ID. */ _id: string; /** * Buyer info. */ buyerInfo?: Orders.BuyerInfoUpdate; }; type UpdateBuyerInfoResponse = { /** * Updated order. */ order?: Orders.Order; }; type UpdateLineItemsDescriptionLinesRequest = { /** * Order ID. */ _id: string; /** * Line items. */ lineItems: Array; }; type UpdateLineItemsDescriptionLinesResponse = { /** * Updated order. */ order?: Orders.Order; }; type UpdateOrderShippingAddressOptions = { /** * Shipping address and contact details to be updated. */ shippingAddress: Orders.AddressWithContact; }; type UpdateOrderShippingAddressRequest = { /** * Order ID. */ _id: string; /** * Shipping address and contact details to be updated. */ shippingAddress: Orders.AddressWithContact; }; type UpdateOrderShippingAddressResponse = { /** * Updated order. */ order?: Orders.Order; }; type V1SubscriptionSettings = { /** * Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. */ billingCycles?: number; /** * Frequency of recurring payment. */ frequency?: string; }; type V2BuyerInfo = { /** * Wix customer ID */ _id?: string; /** * Customer's email address */ email?: string; /** * Customer's first name */ firstName?: string; /** * Customer type */ identityType?: string; /** * Customer's last name */ lastName?: string; /** * Customer's phone number */ phone?: string; /** * Deprecated (use identityType instead) */ type?: string; }; type V2SubscriptionInfo = { /** * Subscription ID. */ _id?: string; /** * Current cycle number. For example, if the subscription is in the 3rd month of a 4-month subscription, the value will be `3`. */ cycleNumber?: number; /** * Subscription options info. */ subscriptionOptionInfo?: Orders.SubscriptionOptionInfo; /** * Subscription settings. */ subscriptionSettings?: Orders.V1SubscriptionSettings; }; type VatId = { /** * Customer's tax ID */ _id?: string; /** * tax type */ type?: string; }; } }