import * as _wix_sdk_types from '@wix/sdk-types'; import { QuerySpec, Query, NonNullablePaths } from '@wix/sdk-types'; /** * A SubscriptionContract is a ... * You can ... * Read more about SubscriptionContracts * in this [article](). */ interface SubscriptionContract { /** * SubscriptionContract ID. * @format GUID * @readonly */ _id?: string | null; /** * Revision number, which increments by 1 each time the SubscriptionContract is updated. * To prevent conflicting changes, the current revision must be passed when updating the SubscriptionContract. * * Ignored when creating a SubscriptionOrderContract. * @readonly */ revision?: string | null; /** * Date and time the subscription contract was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format. * @readonly */ _createdDate?: Date | null; /** * Date and time the subscription contract was last updated in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format. * @readonly */ _updatedDate?: Date | null; /** * Subscription option description. For example, `"1kg of selected coffee, once a month"`. * @maxLength 500 * @deprecated Subscription option description. For example, `"1kg of selected coffee, once a month"`. * @replacedBy subscription_description * @targetRemovalDate 2025-10-01 */ description?: string | null; /** * Subscription detailed information. * @immutable */ subscriptionSettings?: V1SubscriptionSettings; /** * Order line items. * @minSize 1 * @maxSize 100 */ lineItems?: OrderLineItem[]; /** Buyer information. */ buyerInfo?: 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 | null; /** Weight measurement unit - defaults to site's weight unit. */ weightUnit?: WeightUnitWithLiterals; /** * Currency used for the pricing of this order in [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes) format. * @format CURRENCY * @immutable */ currency?: string | null; /** Multi-currency information of the subscription. conversionRate may reflect updated exchange rate on created order per recurring cycle. */ currencyConversionDetails?: CurrencyConversionDetails; /** * Whether tax is included in line item prices. * * Default: `false` * @immutable */ taxIncludedInPrices?: boolean; /** * Order price summary. * @readonly */ priceSummary?: PriceSummary; /** Summary of platform fees for this subscription contract, including totals by charge type and a breakdown of individual fees. */ platformFeeSummary?: PlatformFeeSummary; /** Billing address and contact details. */ billingInfo?: AddressWithContact; /** Shipping info and selected shipping option details. */ shippingInfo?: ShippingInformation; /** Applied discounts. */ appliedDiscounts?: AppliedDiscount[]; /** Information about the sales channel that submitted this order. */ channelInfo?: ChannelInfo; /** Custom fields. */ customFields?: CustomField[]; /** * Order recipient address and contact details. * * This field may differ from the address in `shippingInfo.logistics` when: * + The chosen shipping option is pickup point or store pickup. * + No shipping option is selected. */ recipientInfo?: AddressWithContact; /** * Custom field data for the subscription contract object. * * [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields) must be configured in the [app dashboard](https://dev.wix.com/dc3/my-apps/) before they can be accessed with API calls. */ extendedFields?: ExtendedFields; /** * Subscription option title. For example, `"Monthly coffee Subscription"`. * @maxLength 150 * @deprecated Subscription option title. For example, `"Monthly coffee Subscription"`. * @replacedBy subscription_title * @targetRemovalDate 2025-10-01 */ title?: string | null; /** * Additional fees applied to subscription contract. * @maxSize 100 */ additionalFees?: AdditionalFee[]; } interface V1SubscriptionDescription { /** * Subscription option description. * @maxLength 500 */ original?: string; /** * Translated subscription option description. * @maxLength 500 */ translated?: string | null; } interface V1SubscriptionSettings { /** Frequency of recurring payment. */ frequency?: SubscriptionFrequencyWithLiterals; /** * Number of frequency units in a billing cycle. For example, frequency `MONTH` with interval `3` means billing every 3 months. * @min 1 * @max 3650 */ interval?: number | null; /** Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. * @min 1 */ billingCycles?: number | null; /** Whether to allow the customer to cancel the subscription. */ enableCustomerCancellation?: boolean; /** Period until first cycle starts. If None => no free trial */ freeTrialPeriod?: V1FreeTrialPeriod; } declare enum SubscriptionFrequency { UNDEFINED = "UNDEFINED", DAY = "DAY", WEEK = "WEEK", MONTH = "MONTH", YEAR = "YEAR" } /** @enumType */ type SubscriptionFrequencyWithLiterals = SubscriptionFrequency | 'UNDEFINED' | 'DAY' | 'WEEK' | 'MONTH' | 'YEAR'; interface V1FreeTrialPeriod { /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */ frequency?: SubscriptionFrequencyWithLiterals; /** * Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial. * @min 1 * @max 3650 */ interval?: number; } interface V1BillingSettings { /** * Day of month (1-28) to anchor recurring billing to. When set, billing recurs on this day each cycle. Does not apply to weekly subscriptions. * @min 1 * @max 28 */ anchorDay?: number | null; } interface OrderLineItem { /** * Line item ID. * @immutable */ _id?: string; /** * Item name. * * + Stores - `product.name` * + Bookings - `service.info.name` * + Events - `ticket.name` */ productName?: ProductName; /** References to the line item's origin catalog. Empty for custom line items. */ catalogReference?: CatalogReference; /** * Line item quantity. * @min 1 * @max 100000 */ quantity?: number; /** * Total discount for this line item's entire quantity. * @readonly */ totalDiscount?: Price; /** * Line item description lines. Used for display purposes for the cart, checkout and order. * @maxSize 20 */ descriptionLines?: DescriptionLine[]; /** Line item image. */ image?: string; /** Physical properties of the item. When relevant, contains information such as SKU and item weight. */ physicalProperties?: PhysicalProperties; /** Item type. Either a preset type or custom. */ itemType?: ItemType; /** * Fulfiller ID. Field is empty when the line item is self-fulfilled. * To get fulfillment information, pass the order ID to [List Fulfillments For Single Order](https://dev.wix.com/docs/rest/api-reference/wix-e-commerce/order-fulfillments/list-fulfillments-for-single-order). * @format GUID */ fulfillerId?: string | null; /** * Number of items that were refunded. * @max 100000 */ refundQuantity?: number | null; /** * Number of items restocked. * * For a per-location breakdown, see `restockLocations`. * @max 100000 */ restockQuantity?: number | null; /** Line item price after line item discounts for display purposes. */ price?: Price; /** * Line item price before line item discounts for display purposes. Defaults to `price` when not provided. * @readonly */ priceBeforeDiscounts?: Price; /** * Total price after discounts, and before tax. * @readonly */ totalPriceBeforeTax?: Price; /** * Total price after all discounts and tax. * @readonly */ totalPriceAfterTax?: Price; /** * Type of selected payment option for current item. * * Default: `FULL_PAYMENT_ONLINE` */ paymentOption?: PaymentOptionTypeWithLiterals; /** * Deprecated. Use `taxInfo` instead. * This field will be removed on September 30, 2024. * Tax details for this line item. * @deprecated Deprecated. Use `taxInfo` instead. * This field will be removed on September 30, 2024. * Tax details for this line item. * @replacedBy tax_info * @targetRemovalDate 2024-09-30 */ taxDetails?: ItemTaxFullDetails; /** Represents all the relevant tax details for a specific line item. */ taxInfo?: LineItemTaxInfo; /** Digital file identifier, relevant only for items with type DIGITAL. */ digitalFile?: DigitalFile; /** Subscription info. */ subscriptionInfo?: SubscriptionInfo; /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". */ priceDescription?: PriceDescription; /** * Item's price amount to be charged during checkout. Relevant for items with a `paymentOption` value of `"DEPOSIT_ONLINE"`. * @readonly */ depositAmount?: Price; /** * Line item locations. * * The location's total quantity must not exceed the line item quantity. * @maxSize 5 */ locations?: LocationAndQuantity[]; /** Total price **after** catalog discounts and line item discounts. */ lineItemPrice?: Price; /** Address used for tax calculation. */ taxableAddress?: TaxableAddress; /** * Whether the price is not yet defined, and will be updated after the order is created. * * Default: `false` */ priceUndetermined?: boolean; /** * Custom extended fields for the line item object. * * [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields) must be configured in the app dashboard before they can be accessed with API calls. */ extendedFields?: ExtendedFields; /** * Modifier groups that were added to the item. * @readonly * @maxSize 10 */ modifierGroups?: ModifierGroup[]; } interface ProductName { /** * __Required.__ Item name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * * Min: 1 character. * Max: 200 characters. * @minLength 1 * @maxLength 200 */ original?: string; /** * Item name translated into the buyer's language. * * Min: 1 character. * Max: 400 characters. * Default: Same as `original`. * @minLength 1 * @maxLength 400 */ translated?: string | null; } /** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */ interface CatalogReference { /** * ID of the item within the catalog it belongs to. * @minLength 1 * @maxLength 36 */ catalogItemId?: string; /** * ID of the app providing the catalog. * * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). * * For items from Wix catalogs, the following values always apply: * + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"` * + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"` * + Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"` * @minLength 1 */ appId?: string; /** * Additional item details in `key:value` pairs. * * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items. * * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration) * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction). */ options?: Record | null; } interface Price { /** * Amount. * @decimalValue options { gte:0, lte:1000000000000000 } */ amount?: string; /** * Amount formatted with currency symbol. * @readonly */ formattedAmount?: string; } interface DescriptionLine extends DescriptionLineValueOneOf, DescriptionLineDescriptionLineValueOneOf { /** Description line plain text value. */ plainText?: PlainTextValue; /** Description line color value. */ colorInfo?: Color; /** Description line name. */ name?: DescriptionLineName; } /** @oneof */ interface DescriptionLineValueOneOf { /** Description line plain text value. */ plainText?: PlainTextValue; /** Description line color value. */ colorInfo?: Color; } /** @oneof */ interface DescriptionLineDescriptionLineValueOneOf { } interface DescriptionLineName { /** * Description line name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * @maxLength 100 */ original?: string; /** * Description line name translated into the buyer's language. * * Default: Same as `original`. * @maxLength 200 */ translated?: string | null; } interface PlainTextValue { /** * Description line plain text value in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * @maxLength 600 */ original?: string; /** * Description line plain text value translated into the buyer's language. * * Default: Same as `original`. * @maxLength 600 */ translated?: string | null; } interface Color { /** * Description line color name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * @maxLength 500 */ original?: string; /** * Description line color name translated into the buyer's language. * * Default: Same as `original`. * @maxLength 500 */ translated?: string | null; /** HEX or RGB color code for display. */ code?: string | null; } declare enum DescriptionLineType { /** Unrecognized type. */ UNRECOGNISED = "UNRECOGNISED", /** Plain text type. */ PLAIN_TEXT = "PLAIN_TEXT", /** Color type. */ COLOR = "COLOR" } /** @enumType */ type DescriptionLineTypeWithLiterals = DescriptionLineType | 'UNRECOGNISED' | 'PLAIN_TEXT' | 'COLOR'; interface FocalPoint { /** X-coordinate of the focal point. */ x?: number; /** Y-coordinate of the focal point. */ y?: number; /** crop by height */ height?: number | null; /** crop by width */ width?: number | null; } interface PhysicalProperties { /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */ weight?: number | null; /** * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). * @maxLength 40 */ sku?: string | null; /** Whether this line item is shippable. */ shippable?: boolean; } interface Dimensions { /** * Length. Measurement unit is handled at the system level (metric/imperial). * @decimalValue options { gte:0, lte:999999999, maxScale:6 } */ length?: string | null; /** * Width. Measurement unit is handled at the system level (metric/imperial). * @decimalValue options { gte:0, lte:999999999, maxScale:6 } */ width?: string | null; /** * Height. Measurement unit is handled at the system level (metric/imperial). * @decimalValue options { gte:0, lte:999999999, maxScale:6 } */ height?: string | null; /** Unit of measurement for dimensions (length, width, height). */ unit?: DimensionsUnitWithLiterals; } declare enum DimensionsUnit { UNKNOWN_DIMENSIONS_UNIT = "UNKNOWN_DIMENSIONS_UNIT", /** Millimeters. */ MM = "MM", /** Centimeters. */ CM = "CM", /** Meters. */ M = "M", /** Inches. */ IN = "IN", /** Feet. */ FT = "FT", /** Yards. */ YD = "YD" } /** @enumType */ type DimensionsUnitWithLiterals = DimensionsUnit | 'UNKNOWN_DIMENSIONS_UNIT' | 'MM' | 'CM' | 'M' | 'IN' | 'FT' | 'YD'; interface ItemType extends ItemTypeItemTypeDataOneOf { /** Preset item type. */ preset?: ItemTypePresetWithLiterals; /** Custom item type. When none of the preset types are suitable, specifies the custom type. */ custom?: string; } /** @oneof */ interface ItemTypeItemTypeDataOneOf { /** Preset item type. */ preset?: ItemTypePresetWithLiterals; /** Custom item type. When none of the preset types are suitable, specifies the custom type. */ custom?: string; } declare enum ItemTypePreset { UNRECOGNISED = "UNRECOGNISED", PHYSICAL = "PHYSICAL", DIGITAL = "DIGITAL", GIFT_CARD = "GIFT_CARD", SERVICE = "SERVICE" } /** @enumType */ type ItemTypePresetWithLiterals = ItemTypePreset | 'UNRECOGNISED' | 'PHYSICAL' | 'DIGITAL' | 'GIFT_CARD' | 'SERVICE'; /** Quantity of items restocked at a specific location. */ interface RestockLocation { /** * ID of the location where items were restocked. * @format GUID */ locationId?: string; /** * Number of items restocked at this location. * @min 1 * @max 100000 */ quantity?: number; } /** Type of selected payment option for catalog item */ declare enum PaymentOptionType { /** The entire payment for this item happens as part of the checkout. */ FULL_PAYMENT_ONLINE = "FULL_PAYMENT_ONLINE", /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */ FULL_PAYMENT_OFFLINE = "FULL_PAYMENT_OFFLINE", /** Payment for this item is done by charging a membership. Any remaining amount not covered by the membership, such as item modifiers, is paid online. */ MEMBERSHIP = "MEMBERSHIP", /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */ DEPOSIT_ONLINE = "DEPOSIT_ONLINE", /** Payment for this item can only be done by charging a membership and must be manually redeemed in the dashboard by the site admin. When selected, `price` is `0`. */ MEMBERSHIP_OFFLINE = "MEMBERSHIP_OFFLINE", /** * Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline. * @documentationMaturity preview */ MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER = "MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER" } /** @enumType */ type PaymentOptionTypeWithLiterals = PaymentOptionType | 'FULL_PAYMENT_ONLINE' | 'FULL_PAYMENT_OFFLINE' | 'MEMBERSHIP' | 'DEPOSIT_ONLINE' | 'MEMBERSHIP_OFFLINE' | 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER'; interface ItemTaxFullDetails { /** Taxable amount of this line item. */ taxableAmount?: Price; /** * Tax rate percentage, as a decimal numeral between 0 and 1. For example, `"0.13"`. * @decimalValue options { gte:0, maxScale:6 } */ taxRate?: string; /** The calculated tax, based on the `taxableAmount` and `taxRate`. */ totalTax?: Price; } interface LineItemTaxInfo { /** Calculated tax, based on `taxable_amount` and `tax_rate`. */ taxAmount?: Price; /** Amount for which tax is calculated. */ taxableAmount?: Price; /** * Tax rate %, as a decimal point. * @format DECIMAL_VALUE * @decimalValue options { gte:0, maxScale:6 } */ taxRate?: string | null; /** * Tax group ID. * @format GUID */ taxGroupId?: string | null; /** Indicates whether the price already includes tax. */ taxIncludedInPrice?: boolean; /** * Tax information for a line item. * @maxSize 7 */ taxBreakdown?: LineItemTaxBreakdown[]; } /** * TaxBreakdown represents tax information for a line item. * It holds the tax amount and the tax rate for each tax authority that apply on the line item. */ interface LineItemTaxBreakdown { /** * Jurisdiction that taxes were calculated for. For example, "New York", or "Quebec". * @maxLength 200 */ jurisdiction?: string | null; /** * Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000. * @format DECIMAL_VALUE * @decimalValue options { gte:0, maxScale:6 } */ rate?: string | null; /** Amount of tax calculated for this line item. */ taxAmount?: Price; /** * The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc. * @maxLength 200 */ taxType?: string | null; /** * The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc. * This name should be explicit enough to allow the merchant to understand what tax was calculated. * @maxLength 200 */ taxName?: string | null; /** Type of jurisdiction that taxes were calculated for. */ jurisdictionType?: JurisdictionTypeWithLiterals; /** Non-taxable amount of the line item price. */ nonTaxableAmount?: Price; /** Taxable amount of the line item price. */ taxableAmount?: Price; } /** JurisdictionType represents the type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */ declare enum JurisdictionType { UNDEFINED = "UNDEFINED", COUNTRY = "COUNTRY", STATE = "STATE", COUNTY = "COUNTY", CITY = "CITY", SPECIAL = "SPECIAL" } /** @enumType */ type JurisdictionTypeWithLiterals = JurisdictionType | 'UNDEFINED' | 'COUNTRY' | 'STATE' | 'COUNTY' | 'CITY' | 'SPECIAL'; interface DigitalFile { /** * ID of the secure file in media. * @minLength 1 * @maxLength 100 */ fileId?: string; /** * Link will exist after the digital links have been generated on the order. * @format WEB_URL * @minLength 1 * @maxLength 2000 */ link?: string | null; /** * Link expiration time and date. * @readonly */ expirationDate?: Date | null; } interface SubscriptionInfo { /** * Subscription ID. * @format GUID */ _id?: string | null; /** Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`. */ cycleNumber?: number; /** * Subscription option title. For example, `"Monthly coffee Subscription"`. * @maxLength 150 * @deprecated Subscription option title. For example, `"Monthly coffee Subscription"`. * @replacedBy title * @targetRemovalDate 2025-10-01 */ subscriptionOptionTitle?: string; /** * Subscription option description. For example, `"1kg of selected coffee, once a month"`. * @maxLength 500 * @deprecated Subscription option description. For example, `"1kg of selected coffee, once a month"`. * @replacedBy description * @targetRemovalDate 2025-10-01 */ subscriptionOptionDescription?: string | null; /** * Subscription detailed information. * @immutable */ subscriptionSettings?: SubscriptionSettings; /** * Description of the charges that will be applied for subscription. * @maxLength 1000 */ chargesDescription?: string | null; } interface SubscriptionTitle { /** * Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * @minLength 1 * @maxLength 150 */ original?: string; /** * Subscription option name translated into the buyer's language. * * Default: Same as `original`. * @minLength 1 * @maxLength 150 */ translated?: string | null; } interface SubscriptionDescription { /** * Subscription option description. * @maxLength 500 */ original?: string; /** * Translated subscription option description. * @maxLength 500 */ translated?: string | null; } interface SubscriptionSettings { /** Frequency of recurring payment. */ frequency?: V2SubscriptionFrequencyWithLiterals; /** * Number of frequency units in a billing cycle. For example, frequency `MONTH` with interval `3` means billing every 3 months. * @min 1 * @max 3650 */ interval?: number | null; /** Whether subscription is renewed automatically at the end of each period. */ autoRenewal?: boolean; /** * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`. * @min 1 */ billingCycles?: number | null; /** Whether to allow the customer to cancel the subscription. */ enableCustomerCancellation?: boolean; /** Period until first cycle starts. If None => no free trial */ freeTrialPeriod?: FreeTrialPeriod; } /** Frequency unit of recurring payment */ declare enum V2SubscriptionFrequency { UNDEFINED = "UNDEFINED", DAY = "DAY", WEEK = "WEEK", MONTH = "MONTH", YEAR = "YEAR" } /** @enumType */ type V2SubscriptionFrequencyWithLiterals = V2SubscriptionFrequency | 'UNDEFINED' | 'DAY' | 'WEEK' | 'MONTH' | 'YEAR'; interface FreeTrialPeriod { /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */ frequency?: V2SubscriptionFrequencyWithLiterals; /** * Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial. * @min 1 * @max 3650 */ interval?: number; } interface BillingSettings { /** * Day of month (1-28) to anchor recurring billing to. When set, billing recurs on this day each cycle. Does not apply to weekly subscriptions. * @min 1 * @max 28 */ anchorDay?: number | null; } interface BillingAdjustment { /** The type of adjustment. */ type?: AdjustmentTypeWithLiterals; /** Summary of the prorated adjustment amount. */ priceSummary?: BillingAdjustmentPriceSummary; } declare enum AdjustmentType { /** Adjustment increases the total amount due to changes like covering extra billing days. Typically results in an additional fee. */ EXTRA_CHARGE = "EXTRA_CHARGE", /** Adjustment reduces the total amount due to changes like covering fewer billing days. Typically results in a credit or discount. */ CREDIT = "CREDIT" } /** @enumType */ type AdjustmentTypeWithLiterals = AdjustmentType | 'EXTRA_CHARGE' | 'CREDIT'; interface BillingAdjustmentPriceSummary { /** Subtotal of adjustment, before tax. */ subtotal?: Price; /** Tax on adjustment. */ tax?: Price; /** Total price after tax. */ total?: Price; } interface PriceDescription { /** * __Required.__ Price description in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * @minLength 1 * @maxLength 100 */ original?: string; /** * Price description translated into the buyer's language. * * Default: Same as `original`. * @minLength 1 * @maxLength 100 */ translated?: string | null; } interface LocationAndQuantity { /** * Location id in the associated owner app. * @format GUID */ _id?: string; /** * Location owner app, if not provided then the site business info locations will be used. * @format GUID * @deprecated Location owner app, if not provided then the site business info locations will be used. * @targetRemovalDate 2025-03-01 */ appId?: string | null; /** * Quantity for specific location. * @min 1 * @max 100000 */ quantity?: number; /** * Location name. * @maxLength 500 * @readonly */ name?: string | null; } interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf { /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */ addressType?: TaxableAddressTypeWithLiterals; } /** @oneof */ interface TaxableAddressTaxableAddressDataOneOf { /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */ addressType?: TaxableAddressTypeWithLiterals; } declare enum TaxableAddressType { BUSINESS = "BUSINESS", BILLING = "BILLING", SHIPPING = "SHIPPING" } /** @enumType */ type TaxableAddressTypeWithLiterals = TaxableAddressType | 'BUSINESS' | 'BILLING' | 'SHIPPING'; interface ExtendedFields { /** * Extended field data. Each key corresponds to the namespace of the app that created the extended fields. * The value of each key is structured according to the schema defined when the extended fields were configured. * * You can only access fields for which you have the appropriate permissions. * * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields). */ namespaces?: Record>; } interface ModifierGroup { /** * Modifier group ID. * @minLength 1 * @maxLength 36 */ _id?: string; /** Modifier group name. */ name?: TranslatableString; /** * List of modifiers in this group. * @minSize 1 * @maxSize 10 */ modifiers?: ItemModifier[]; } interface TranslatableString { /** * __Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * * Min: 1 character. * Max: 200 characters. * @minLength 1 * @maxLength 200 */ original?: string; /** * String translated into the buyer's language. * * Min: 1 character. * Max: 400 characters. * Default: Same as `original`. * @minLength 1 * @maxLength 400 */ translated?: string | null; } interface ItemModifier { /** * Modifier ID. * @minLength 1 * @maxLength 36 */ _id?: string; /** * The quantity of this modifier. * @min 1 * @max 100000 */ quantity?: number | null; /** Primary display label for the modifier. */ label?: TranslatableString; /** Additional details. */ details?: TranslatableString; /** The price of the modifier. */ price?: Price; } /** Buyer information. */ interface BuyerInfo extends BuyerInfoIdOneOf { /** * Visitor ID. Returned when the buyer isn't a logged-in site member. * @format GUID */ visitorId?: string; /** * Member ID. Returned when the buyer is a logged-in site member. * @format GUID */ memberId?: string; /** * Contact ID. Automatically created if one doesn't exist. For more information, see [Contacts API](https://dev.wix.com/docs/api-reference/crm/members-contacts/contacts/contacts/contact-v4/introduction). * @format GUID */ contactId?: string | null; /** * Buyer's email address. * @format EMAIL */ email?: string | null; } /** @oneof */ interface BuyerInfoIdOneOf { /** * Visitor ID. Returned when the buyer isn't a logged-in site member. * @format GUID */ visitorId?: string; /** * Member ID. Returned when the buyer is a logged-in site member. * @format GUID */ memberId?: string; } declare enum WeightUnit { /** Weight unit can't be classified due to an error. */ UNSPECIFIED_WEIGHT_UNIT = "UNSPECIFIED_WEIGHT_UNIT", /** Kilograms. */ KG = "KG", /** Pounds. */ LB = "LB" } /** @enumType */ type WeightUnitWithLiterals = WeightUnit | 'UNSPECIFIED_WEIGHT_UNIT' | 'KG' | 'LB'; interface CurrencyConversionDetails { /** * Currency used for the pricing of this order, in [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217#List_of_ISO_4217_currency_codes) format. * * This currency is used to calculate the pricing before conversion to the buyer's payment currency. * @readonly * @immutable * @format CURRENCY */ originalCurrency?: string | null; /** * The rate used for converting the original currency to the currency used for payment. * @readonly * @immutable * @decimalValue options { gt:0, lte:1000000000000000 } */ conversionRate?: string | null; } interface PriceSummary { /** Subtotal of all line items, before discounts and before tax. */ subtotal?: Price; /** Total shipping price, before discounts and before tax. */ shipping?: Price; /** Total tax applied to the order. */ tax?: Price; /** Total discount amount applied to the order. */ discount?: Price; /** Order's total price after discounts and tax. */ total?: Price; /** Total additional fees before tax. */ totalAdditionalFees?: Price; } interface PlatformFeeSummary { /** Total sum of all platform fees. */ total?: Price; /** Total amount of platform fees with `PASS_ON` charge type. */ totalPassOn?: Price; /** Total amount of platform fees with `ABSORBED` charge type. */ totalAbsorbed?: Price; /** * Specific information about each platform fee. * @maxSize 300 */ fees?: PlatformFee[]; } interface PlatformFee { /** Platform fee name. */ name?: TranslatableString; /** Platform fee amount. */ amount?: Price; /** * ID of the line item the platform fee applies to. * @format GUID */ lineItemId?: string; /** Platform fee charge type. */ chargeType?: ChargeTypeWithLiterals; /** * Percentage rate charged as platform fee. * The fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%. * @format DECIMAL_VALUE * @decimalValue options { gt:0, lte:1, maxScale:4 } */ percentageRate?: string; } declare enum ChargeType { /** * Platform fee passed on to buyer. * * This type increases the order total, and is visible to the buyer and merchant as an additional fee. */ PASS_ON = "PASS_ON", /** * Platform fee absorbed by merchant. * * This type does not increase the order total, and is only visible to the merchant. */ ABSORBED = "ABSORBED" } /** @enumType */ type ChargeTypeWithLiterals = ChargeType | 'PASS_ON' | 'ABSORBED'; /** Billing Info and shipping details */ interface AddressWithContact { /** Address. */ address?: Address; /** Contact details. */ contactDetails?: FullAddressContactDetails; } /** Physical address */ interface Address { /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. * @format COUNTRY */ country?: string | null; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. * @maxLength 50 */ subdivision?: string | null; /** * City name. * @maxLength 50 */ city?: string | null; /** * Postal or zip code. * @maxLength 50 */ postalCode?: string | null; /** Street address. */ streetAddress?: StreetAddress; /** * Main address line (usually street name and number). * @maxLength 150 */ addressLine1?: string | null; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. * @maxLength 100 */ addressLine2?: string | null; /** Geocode object containing latitude and longitude coordinates. */ location?: AddressLocation; /** * Country's full name. * @readonly */ countryFullname?: string | null; /** * Subdivision full-name. * @readonly */ subdivisionFullname?: string | null; } interface StreetAddress { /** Street number. */ number?: string; /** Street name. */ name?: string; } interface AddressLocation { /** Address latitude. */ latitude?: number | null; /** Address longitude. */ longitude?: number | null; } /** Full contact details for an address */ interface FullAddressContactDetails { /** * First name. * @maxLength 100 */ firstName?: string | null; /** * Last name. * @maxLength 100 */ lastName?: string | null; /** * Phone number. * @format PHONE */ phone?: string | null; /** * Company name. * @maxLength 1000 */ company?: string | null; /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */ vatId?: VatId; } interface VatId { /** Customer's tax ID. */ _id?: string; /** * Tax type. * * Supported values: * + `CPF`: for individual tax payers * + `CNPJ`: for corporations */ type?: VatTypeWithLiterals; } /** tax info types */ declare enum VatType { UNSPECIFIED = "UNSPECIFIED", /** CPF - for individual tax payers. */ CPF = "CPF", /** CNPJ - for corporations */ CNPJ = "CNPJ" } /** @enumType */ type VatTypeWithLiterals = VatType | 'UNSPECIFIED' | 'CPF' | 'CNPJ'; interface ShippingInformation { /** * App Def Id of external provider which was a source of shipping info * @minLength 1 * @maxLength 100 */ carrierId?: string | null; /** * Unique code (or ID) of selected shipping option. For example, `"usps_std_overnight"`. * @minLength 1 * @maxLength 100 */ code?: string | null; /** * Shipping option title. * For example, `"USPS Standard Overnight Delivery"`, `"Standard"` or `"First-Class Package International"`. * @maxLength 250 */ title?: string; /** Shipping logistics. */ logistics?: DeliveryLogistics; /** Shipping costs. */ cost?: ShippingPrice; /** Shipping region. */ region?: ShippingRegion; } interface DeliveryLogistics extends DeliveryLogisticsAddressOneOf { /** Shipping destination address and contact details. For pickup orders, this contains the pickup location address, not the recipient's address. */ shippingDestination?: AddressWithContact; /** Pickup details for store pickup or pickup point orders. */ pickupDetails?: PickupDetails; /** * Expected delivery time in free text. For example, `"3-5 business days"`. * @maxLength 500 */ deliveryTime?: string | null; /** * Instructions for the carrier. For example, `"Please knock on the door. If unanswered, please call contact number."`. * @maxLength 1000 */ instructions?: string | null; /** * Deprecated - Latest expected delivery date and time in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format. * @deprecated */ deliverByDate?: Date | null; /** Expected delivery time slot with start and end times. */ deliveryTimeSlot?: DeliveryTimeSlot; } /** @oneof */ interface DeliveryLogisticsAddressOneOf { /** Shipping destination address and contact details. For pickup orders, this contains the pickup location address, not the recipient's address. */ shippingDestination?: AddressWithContact; /** Pickup details for store pickup or pickup point orders. */ pickupDetails?: PickupDetails; } interface PickupDetails { /** Pickup address. */ address?: PickupAddress; /** Pickup method */ pickupMethod?: PickupMethodWithLiterals; } /** Physical address */ interface PickupAddress { /** * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. * @format COUNTRY */ country?: string | null; /** * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. * @maxLength 50 */ subdivision?: string | null; /** * City name. * @maxLength 1000 */ city?: string | null; /** * Postal or zip code. * @maxLength 1000 */ postalCode?: string | null; /** Street address object, with number, name, and apartment number in separate fields. */ streetAddress?: StreetAddress; /** * Main address line (usually street name and number). * @maxLength 1000 */ addressLine1?: string | null; /** * Free text providing more detailed address info. Usually contains apt, suite, floor. * @maxLength 1000 */ addressLine2?: string | null; /** * Country's full name. * @readonly */ countryFullname?: string | null; /** * Subdivision full-name. * @readonly */ subdivisionFullname?: string | null; } declare enum PickupMethod { STORE_PICKUP = "STORE_PICKUP", PICKUP_POINT = "PICKUP_POINT" } /** @enumType */ type PickupMethodWithLiterals = PickupMethod | 'STORE_PICKUP' | 'PICKUP_POINT'; interface DeliveryTimeSlot { /** Delivery slot starting time. */ from?: Date | null; /** Delivery slot ending time. */ to?: Date | null; } interface ShippingPrice { /** Shipping price for display purposes. */ price?: Price; /** * Total price of shipping after discounts (when relevant), and before tax. * @readonly */ totalPriceBeforeTax?: Price; /** * Shipping price after all discounts (if any exist), and after tax. * @readonly */ totalPriceAfterTax?: Price; /** * Tax details. * @deprecated Tax details. * @replacedBy tax_info * @targetRemovalDate 2026-03-30 */ taxDetails?: ItemTaxFullDetails; /** Represents all the relevant tax details for a shipping. */ taxInfo?: LineItemTaxInfo; /** * Shipping discount before tax. * @readonly */ discount?: Price; } interface ShippingRegion { /** * Name of shipping region. For example, `"Metropolitan London"`, or `"Outer Melbourne suburbs"`. * @maxLength 100 */ name?: string | null; } interface OrderTaxInfo { /** Calculated tax, added from line items. */ totalTax?: Price; /** * The summary of the tax breakdown for all the line items. It will hold for each tax name, the aggregated tax amount paid for it and the tax rate. * @maxSize 50 */ taxBreakdown?: OrderTaxBreakdown[]; /** * Whether the order is exempt from tax calculations. * * Default: `false` * @readonly */ taxExempt?: boolean | null; } /** * The summary of the tax breakdown for all the line items. It will hold for each tax name, the aggregated tax amount paid for it and the tax rate. * Tax breakdown is the tax amount split to the tax authorities that applied on the line item. */ interface OrderTaxBreakdown { /** * The name of the tax against which this tax amount was calculated. * @maxLength 200 */ taxName?: string; /** * The type of tax that was calculated. Depends on the company's nexus settings as well as the jurisdiction's tax laws. * @maxLength 200 */ taxType?: string; /** * The name of the jurisdiction in which this tax detail applies. * @maxLength 200 */ jurisdiction?: string; /** The type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */ jurisdictionType?: JurisdictionTypeWithLiterals; /** * The rate at which this tax detail was calculated. * @format DECIMAL_VALUE * @decimalValue options { gte:0, maxScale:6 } */ rate?: string; /** The sum of all the tax from line items that calculated by the tax identifiers. */ aggregatedTaxAmount?: Price; } interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf { /** Coupon applied by the customer. */ coupon?: Coupon; /** Discount applied manually by the merchant. */ merchantDiscount?: MerchantDiscount; /** Automatic discount applied by the system based on configured discount rules. */ discountRule?: DiscountRule; discountType?: DiscountTypeWithLiterals; /** * __Deprecated.__ Use `lineItemDiscounts` instead. * * IDs of line items the discount applies to. * @format GUID * @maxSize 300 * @deprecated __Deprecated.__ Use `lineItemDiscounts` instead. * * IDs of line items the discount applies to. * @replacedBy line_item_discounts * @targetRemovalDate 2024-10-30 */ lineItemIds?: string[]; /** * Discount ID. * @format GUID * @immutable */ _id?: string | null; /** * Line items the discount applies to, including the discount amount for each. * @maxSize 300 */ lineItemDiscounts?: LineItemDiscount[]; } /** @oneof */ interface AppliedDiscountDiscountSourceOneOf { /** Coupon applied by the customer. */ coupon?: Coupon; /** Discount applied manually by the merchant. */ merchantDiscount?: MerchantDiscount; /** Automatic discount applied by the system based on configured discount rules. */ discountRule?: DiscountRule; } /** Type of discount. */ declare enum DiscountType { /** Discount applies to the entire order. */ GLOBAL = "GLOBAL", /** Discount applies to specific items. */ SPECIFIC_ITEMS = "SPECIFIC_ITEMS", /** Discount applies to shipping. For example, free shipping. */ SHIPPING = "SHIPPING" } /** @enumType */ type DiscountTypeWithLiterals = DiscountType | 'GLOBAL' | 'SPECIFIC_ITEMS' | 'SHIPPING'; /** Coupon */ interface Coupon { /** Coupon ID. */ _id?: string; /** Coupon code. */ code?: string; /** Coupon name. */ name?: string; /** Coupon value. */ amount?: Price; } /** Discount applied manually by the merchant through the dashboard. */ interface MerchantDiscount extends MerchantDiscountMerchantDiscountReasonOneOf { /** Predefined discount reason. */ discountReason?: DiscountReasonWithLiterals; /** * Custom discount description as free text. * @maxLength 200 */ description?: string | null; /** Discount amount. */ amount?: Price; } /** @oneof */ interface MerchantDiscountMerchantDiscountReasonOneOf { /** Predefined discount reason. */ discountReason?: DiscountReasonWithLiterals; /** * Custom discount description as free text. * @maxLength 200 */ description?: string | null; } /** Predefined reason for the discount. */ declare enum DiscountReason { /** Unknown discount reason. */ UNSPECIFIED = "UNSPECIFIED", /** Balance adjustment resulting from an item exchange. */ EXCHANGED_ITEMS = "EXCHANGED_ITEMS", /** Proportional discount for a shortened subscription billing cycle. Applied when a subscription's billing date is moved earlier, reducing the cycle length. */ BILLING_ADJUSTMENT = "BILLING_ADJUSTMENT" } /** @enumType */ type DiscountReasonWithLiterals = DiscountReason | 'UNSPECIFIED' | 'EXCHANGED_ITEMS' | 'BILLING_ADJUSTMENT'; interface DiscountRule { /** * Discount rule ID * @format GUID */ _id?: string; /** Discount rule name */ name?: DiscountRuleName; /** Discount value. */ amount?: Price; } interface DiscountRuleName { /** * Original discount rule name (in site's default language). * @minLength 1 * @maxLength 256 */ original?: string; /** * Translated discount rule name according to buyer language. Defaults to `original` when not provided. * @minLength 1 * @maxLength 500 */ translated?: string | null; } interface LineItemDiscount { /** * Line item ID. * @format GUID */ _id?: string; /** Total discount amount for this line item. */ totalDiscount?: Price; } interface ItemCombination { /** * The number of times this exact combination of items (with the specified quantities) was applied together in the order. * @min 1 * @max 100000 */ count?: number; /** * Line items that participated together in this combination. * @minSize 1 * @maxSize 100 */ lineItems?: ItemCombinationLineItem[]; } interface ItemCombinationLineItem { /** * The unique ID of the line item to which this discount applies. * @format GUID */ lineItemId?: string; /** Total discount amount for all units (quantity) of this line item in this combination. */ discountAmount?: Price; /** * Number of units from this line item that participated in a single combination. * @min 1 * @max 100000 */ quantity?: number; } interface ChannelInfo { /** * Sales channel that submitted the order. * * When creating an order via the API to record an external order, use the channel type that matches the original source. If no matching type exists, use `OTHER_PLATFORM`. */ type?: ChannelTypeWithLiterals; /** * Reference to an order ID from an external system. Relevant when recording orders from external platforms. * @maxLength 100 */ externalOrderId?: string | null; /** * URL to the order in the external system. Relevant when recording orders from external platforms. * @maxLength 300 */ externalOrderUrl?: string | null; } declare enum ChannelType { /** Unspecified sales channel. This value is not supported. */ UNSPECIFIED = "UNSPECIFIED", /** A web client. */ WEB = "WEB", /** [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). */ POS = "POS", /** [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). */ EBAY = "EBAY", /** [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). */ AMAZON = "AMAZON", /** Other sales platform. */ OTHER_PLATFORM = "OTHER_PLATFORM", /** [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). */ WIX_APP_STORE = "WIX_APP_STORE", /** Wix Invoices app in [your dashboard](https://www.wix.com/my-account/site-selector/?buttonText=Select%20Site&title=Select%20a%20Site&autoSelectOnSingleSite=true&actionUrl=https:%2F%2Fwww.wix.com%2Fdashboard%2F%7B%7BmetaSiteId%7D%7D%2Finvoices/settings/general-settings) */ WIX_INVOICES = "WIX_INVOICES", /** Wix merchant backoffice. */ BACKOFFICE_MERCHANT = "BACKOFFICE_MERCHANT", /** Wish sales channel. */ WISH = "WISH", /** [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). */ CLASS_PASS = "CLASS_PASS", /** Global-E sales channel. */ GLOBAL_E = "GLOBAL_E", /** [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). */ FACEBOOK = "FACEBOOK", /** [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). */ ETSY = "ETSY", /** [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). */ TIKTOK = "TIKTOK", /** [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). */ FAIRE_COM = "FAIRE_COM", /** PayPal Agentic Checkout sales channel. */ PAYPAL_AGENTIC_CHECKOUT = "PAYPAL_AGENTIC_CHECKOUT", /** Stripe Agentic Checkout sales channel. */ STRIPE_AGENTIC_CHECKOUT = "STRIPE_AGENTIC_CHECKOUT" } /** @enumType */ type ChannelTypeWithLiterals = ChannelType | 'UNSPECIFIED' | 'WEB' | 'POS' | 'EBAY' | 'AMAZON' | 'OTHER_PLATFORM' | 'WIX_APP_STORE' | 'WIX_INVOICES' | 'BACKOFFICE_MERCHANT' | 'WISH' | 'CLASS_PASS' | 'GLOBAL_E' | 'FACEBOOK' | 'ETSY' | 'TIKTOK' | 'FAIRE_COM' | 'PAYPAL_AGENTIC_CHECKOUT' | 'STRIPE_AGENTIC_CHECKOUT'; interface CustomField { /** Custom field value. */ value?: any; /** * Custom field title. * @minLength 1 * @maxLength 500 */ title?: string; /** * Translated custom field title. * @minLength 1 * @maxLength 500 */ translatedTitle?: string | null; } interface V1SubscriptionTitle { /** * Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions#request-envelope). * @minLength 1 * @maxLength 150 */ original?: string; /** * Subscription option name translated into the buyer's language. * * Default: Same as `original`. * @minLength 1 * @maxLength 150 */ translated?: string | null; } interface AdditionalFee { /** * Additional fee's unique code for future processing. * @minLength 1 * @maxLength 100 */ code?: string | null; /** * Name of additional fee. * @minLength 1 * @maxLength 50 */ name?: string; /** Additional fee's price. */ price?: Price; /** * Tax details. * @deprecated Tax details. * @replacedBy tax_info * @targetRemovalDate 2026-03-30 */ taxDetails?: ItemTaxFullDetails; /** Represents all the relevant tax details for additional fee. */ taxInfo?: LineItemTaxInfo; /** * SPI implementer's `appId`. * @format GUID */ providerAppId?: string | null; /** Additional fee's price before tax. */ priceBeforeTax?: Price; /** Additional fee's price after tax. */ priceAfterTax?: Price; /** * Additional fee's id. * @format GUID * @immutable */ _id?: string; /** * Optional - Line items associated with this additional fee. * If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order. * @format GUID */ lineItemIds?: string[]; /** Specifies the entity that added the additional fee. */ source?: AdditionalFeeSourceWithLiterals; } declare enum AdditionalFeeSource { /** The additional fee was added by an additional fee service plugin. */ SERVICE_PLUGIN = "SERVICE_PLUGIN", /** The additional fee was added to the item by a catalog or custom line item. */ ITEM = "ITEM", /** The additional fee was added manually on request. */ MANUAL = "MANUAL", /** The additional fee was added by the shipping provider. */ SHIPPING = "SHIPPING", /** The additional fee was added by the Wix eCommerce platform. */ PLATFORM = "PLATFORM" } /** @enumType */ type AdditionalFeeSourceWithLiterals = AdditionalFeeSource | 'SERVICE_PLUGIN' | 'ITEM' | 'MANUAL' | 'SHIPPING' | 'PLATFORM'; interface Location { /** * Location ID. * Learn more about the [Wix Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction). * @format GUID */ _id?: string; /** * Location name. * @minLength 1 * @maxLength 500 * @readonly */ name?: string; } interface SubscriptionContractSettings { /** Indicates which coupon calculation model was used when creating this contract. */ specificItemsCouponBehavior?: SpecificItemsCouponBehaviorWithLiterals; } declare enum SpecificItemsCouponBehavior { /** Coupon calculation behavior was not specified. */ UNDEFINED_COUPON_BEHAVIOR = "UNDEFINED_COUPON_BEHAVIOR", /** Item subtotal includes coupon discount. */ ITEM_SUBTOTAL_INCLUDES_DISCOUNT = "ITEM_SUBTOTAL_INCLUDES_DISCOUNT", /** * Legacy flow. * Discount is applied as to specific items after subtotal calculation. */ LEGACY_ITEM_SUBTOTAL_DOES_NOT_INCLUDE_DISCOUNT = "LEGACY_ITEM_SUBTOTAL_DOES_NOT_INCLUDE_DISCOUNT" } /** @enumType */ type SpecificItemsCouponBehaviorWithLiterals = SpecificItemsCouponBehavior | 'UNDEFINED_COUPON_BEHAVIOR' | 'ITEM_SUBTOTAL_INCLUDES_DISCOUNT' | 'LEGACY_ITEM_SUBTOTAL_DOES_NOT_INCLUDE_DISCOUNT'; /** Triggered when a subscription contract has been canceled before its designated end date. */ interface SubscriptionContractCanceled { /** The subscription contract that was canceled. */ subscriptionContract?: SubscriptionContract; /** Who initiated the cancellation. */ initiator?: ActionInitiatorWithLiterals; /** Reason for cancellation. */ reason?: string | null; } declare enum ActionInitiator { UNKNOWN_ACTION_INITIATOR = "UNKNOWN_ACTION_INITIATOR", BUSINESS = "BUSINESS", CUSTOMER = "CUSTOMER", SYSTEM = "SYSTEM", PAYMENT_FAILURE = "PAYMENT_FAILURE" } /** @enumType */ type ActionInitiatorWithLiterals = ActionInitiator | 'UNKNOWN_ACTION_INITIATOR' | 'BUSINESS' | 'CUSTOMER' | 'SYSTEM' | 'PAYMENT_FAILURE'; /** Triggered when a subscription contract has expired after completing all billing cycles. */ interface SubscriptionContractExpired { /** The subscription contract that expired. */ subscriptionContract?: SubscriptionContract; } interface CreateSubscriptionContractRequest { /** SubscriptionContract to be created. */ subscriptionContract?: SubscriptionContract; } interface CreateSubscriptionContractResponse { /** The created SubscriptionContract. */ subscriptionContract?: SubscriptionContract; } interface GetSubscriptionContractRequest { /** * ID of the SubscriptionContract to retrieve. * @format GUID */ subscriptionContractId: string; } interface GetSubscriptionContractResponse { /** The requested SubscriptionContract. */ subscriptionContract?: SubscriptionContract; } interface UpdateSubscriptionContractRequest { /** SubscriptionContract to be updated, may be partial. */ subscriptionContract?: SubscriptionContract; } interface UpdateSubscriptionContractResponse { /** Updated SubscriptionContract. */ subscriptionContract?: SubscriptionContract; } interface QuerySubscriptionContractsRequest { /** WQL expression. */ query?: CursorQuery; } interface CursorQuery extends CursorQueryPagingMethodOneOf { /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: CursorPaging; /** * Filter object in the following format: * `"filter" : { * "fieldName1": "value1", * "fieldName2":{"$operator":"value2"} * }` * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains` * Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section). */ filter?: Record | null; /** * Sort object in the following format: * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` * Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section). * @maxSize 5 */ sort?: Sorting[]; } /** @oneof */ interface CursorQueryPagingMethodOneOf { /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: CursorPaging; } interface Sorting { /** * Name of the field to sort by. * @maxLength 512 */ fieldName?: string; /** Sort order. */ order?: SortOrderWithLiterals; } declare enum SortOrder { ASC = "ASC", DESC = "DESC" } /** @enumType */ type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC'; interface CursorPaging { /** * Maximum number of items to return in the results. * @max 100 */ limit?: number | null; /** * Pointer to the next or previous page in the list of results. * * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response. * Not relevant for the first request. * @maxLength 16000 */ cursor?: string | null; } interface QuerySubscriptionContractsResponse { /** List of SubscriptionContracts. */ subscriptionContracts?: SubscriptionContract[]; /** Paging metadata */ pagingMetadata?: CursorPagingMetadata; } interface CursorPagingMetadata { /** Number of items returned in the response. */ count?: number | null; /** Cursor strings that point to the next page, previous page, or both. */ cursors?: Cursors; /** * Whether there are more pages to retrieve following the current page. * * + `true`: Another page of results can be retrieved. * + `false`: This is the last page. */ hasNext?: boolean | null; } interface Cursors { /** * Cursor string pointing to the next page in the list of results. * @maxLength 16000 */ next?: string | null; /** * Cursor pointing to the previous page in the list of results. * @maxLength 16000 */ prev?: string | null; } interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; /** Event ID. With this ID you can easily spot duplicated events and ignore them. */ _id?: string; /** * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities. * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`. */ entityFqdn?: string; /** * Event action name, placed at the top level to make it easier for users to dispatch messages. * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`. */ slug?: string; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ triggeredByAnonymizeRequest?: boolean | null; /** If present, indicates the action that triggered the event. */ originatedFrom?: string | null; /** * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number. * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it. */ entityEventSequence?: string | null; } /** @oneof */ interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } interface EntityCreatedEvent { entity?: string; } interface RestoreInfo { deletedDate?: Date | null; } interface 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. */ currentEntity?: string; } interface EntityDeletedEvent { /** Entity that was deleted. */ deletedEntity?: string | null; } interface ActionEvent { body?: string; } interface Empty { } interface BulkCreateSubscriptionContractsRequest { /** * List of SubscriptionContracts to create. * @minSize 1 * @maxSize 100 */ subscriptionContracts?: SubscriptionContract[]; /** * Whether to return the full subscription contract entities in the response. * * Default: `false` */ returnEntity?: boolean; } interface BulkCreateSubscriptionContractsResponse { /** * Results of the contract created operation. * @minSize 1 * @maxSize 100 */ results?: BulkSubscriptionContractResult[]; /** Bulk action metadata. */ bulkActionMetadata?: BulkActionMetadata; } interface BulkSubscriptionContractResult { /** Metadata about a single update operation. */ itemMetadata?: ItemMetadata; /** * Created subscription contract. * * Only present if `returnEntity` was `true`. */ item?: SubscriptionContract; } interface ItemMetadata { /** * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed. * @format GUID */ _id?: string | null; /** Index of the item within the request array. Allows for correlation between request and response items. */ originalIndex?: number; /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */ success?: boolean; /** Details about the error in case of failure. */ error?: ApplicationError; } interface ApplicationError { /** Error code. */ code?: string; /** Description of the error. */ description?: string; /** Data related to the error. */ data?: Record | null; } interface BulkActionMetadata { /** Number of items that were successfully processed. */ totalSuccesses?: number; /** Number of items that couldn't be processed. */ totalFailures?: number; /** Number of failures without details because detailed failure threshold was exceeded. */ undetailedFailures?: number; } interface BulkUpdateSubscriptionContractsRequest { /** * List of SubscriptionContracts to update. * @minSize 1 * @maxSize 100 */ subscriptionContracts?: MaskedSubscriptionContract[]; /** * Whether to return the full subscription contract entities in the response. * * Default: `false` */ returnEntity?: boolean; } interface MaskedSubscriptionContract { /** Subscription contract to be updated. */ subscriptionContract?: SubscriptionContract; } interface BulkUpdateSubscriptionContractsResponse { /** * Results of the contract updated operation. * @minSize 1 * @maxSize 100 */ results?: BulkSubscriptionContractResult[]; /** Metadata about the bulk operation. */ bulkActionMetadata?: BulkActionMetadata; } interface MessageEnvelope { /** * App instance ID. * @format GUID */ instanceId?: string | null; /** * Event type. * @maxLength 150 */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; /** Details related to the account */ accountInfo?: AccountInfo; } interface IdentificationData extends IdentificationDataIdOneOf { /** * ID of a site visitor that has not logged in to the site. * @format GUID */ anonymousVisitorId?: string; /** * ID of a site visitor that has logged in to the site. * @format GUID */ memberId?: string; /** * ID of a Wix user (site owner, contributor, etc.). * @format GUID */ wixUserId?: string; /** * ID of an app. * @format GUID */ appId?: string; /** @readonly */ identityType?: WebhookIdentityTypeWithLiterals; } /** @oneof */ interface IdentificationDataIdOneOf { /** * ID of a site visitor that has not logged in to the site. * @format GUID */ anonymousVisitorId?: string; /** * ID of a site visitor that has logged in to the site. * @format GUID */ memberId?: string; /** * ID of a Wix user (site owner, contributor, etc.). * @format GUID */ wixUserId?: string; /** * ID of an app. * @format GUID */ appId?: string; } declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } /** @enumType */ type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP'; interface AccountInfo { /** * ID of the Wix account associated with the event. * @format GUID */ accountId?: string | null; /** * ID of the parent Wix account. Only included when accountId belongs to a child account. * @format GUID */ parentAccountId?: string | null; /** * ID of the Wix site associated with the event. Only included when the event is tied to a specific site. * @format GUID */ siteId?: string | null; } interface BaseEventMetadata { /** * App instance ID. * @format GUID */ instanceId?: string | null; /** * Event type. * @maxLength 150 */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Details related to the account */ accountInfo?: AccountInfo; } interface EventMetadata extends BaseEventMetadata { /** Event ID. With this ID you can easily spot duplicated events and ignore them. */ _id?: string; /** * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities. * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`. */ entityFqdn?: string; /** * Event action name, placed at the top level to make it easier for users to dispatch messages. * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`. */ slug?: string; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ triggeredByAnonymizeRequest?: boolean | null; /** If present, indicates the action that triggered the event. */ originatedFrom?: string | null; /** * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number. * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it. */ entityEventSequence?: string | null; accountInfo?: AccountInfoMetadata; } interface AccountInfoMetadata { /** ID of the Wix account associated with the event */ accountId: string; /** ID of the Wix site associated with the event. Only included when the event is tied to a specific site. */ siteId?: string; /** ID of the parent Wix account. Only included when 'accountId' belongs to a child account. */ parentAccountId?: string; } interface SubscriptionContractCreatedEnvelope { entity: SubscriptionContract; metadata: EventMetadata; } /** @permissionScope Manage Stores - all permissions * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES * @permissionScope Read eCommerce - all read permissions * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionScope Manage eCommerce - all permissions * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ * @webhook * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_created * @slug created * @documentationMaturity preview */ declare function onSubscriptionContractCreated(handler: (event: SubscriptionContractCreatedEnvelope) => void | Promise): void; interface SubscriptionContractDeletedEnvelope { metadata: EventMetadata; } /** @permissionScope Manage Stores - all permissions * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES * @permissionScope Read eCommerce - all read permissions * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionScope Manage eCommerce - all permissions * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ * @webhook * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_deleted * @slug deleted * @documentationMaturity preview */ declare function onSubscriptionContractDeleted(handler: (event: SubscriptionContractDeletedEnvelope) => void | Promise): void; interface SubscriptionContractUpdatedEnvelope { entity: SubscriptionContract; metadata: EventMetadata; /** @hidden */ modifiedFields: Record; } /** @permissionScope Manage Stores - all permissions * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES * @permissionScope Read eCommerce - all read permissions * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM * @permissionScope Manage Restaurants - all permissions * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES * @permissionScope Manage eCommerce - all permissions * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ * @webhook * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_updated * @slug updated * @documentationMaturity preview */ declare function onSubscriptionContractUpdated(handler: (event: SubscriptionContractUpdatedEnvelope) => void | Promise): void; /** * Retrieves a SubscriptionContract. * @param subscriptionContractId - ID of the SubscriptionContract to retrieve. * @public * @documentationMaturity preview * @requiredField subscriptionContractId * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ * @applicableIdentity APP * @returns The requested SubscriptionContract. * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.GetSubscriptionContract */ declare function getSubscriptionContract(subscriptionContractId: string): Promise>; /** * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1]. * * Up to 300 SubscriptionContracts can be returned per request. * * To learn how to query SubscriptionContracts, see [API Query Language][2]. * * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language * @public * @documentationMaturity preview * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ * @applicableIdentity APP * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts */ declare function querySubscriptionContracts(): SubscriptionContractsQueryBuilder; interface QueryCursorResult { cursors: Cursors; hasNext: () => boolean; hasPrev: () => boolean; length: number; pageSize: number; } interface SubscriptionContractsQueryResult extends QueryCursorResult { items: SubscriptionContract[]; query: SubscriptionContractsQueryBuilder; next: () => Promise; prev: () => Promise; } interface SubscriptionContractsQueryBuilder { /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ eq: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ ne: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ ge: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ gt: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ le: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ lt: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `string`. * @param string - String to compare against. Case-insensitive. * @documentationMaturity preview */ startsWith: (propertyName: '_id' | 'buyerInfo.contactId', value: string) => SubscriptionContractsQueryBuilder; /** @param propertyName - Property whose value is compared with `values`. * @param values - List of values to compare against. * @documentationMaturity preview */ hasSome: (propertyName: '_id' | 'buyerInfo.contactId', value: any[]) => SubscriptionContractsQueryBuilder; /** @documentationMaturity preview */ in: (propertyName: '_id' | 'buyerInfo.contactId', value: any) => SubscriptionContractsQueryBuilder; /** @documentationMaturity preview */ exists: (propertyName: '_id' | 'buyerInfo.contactId', value: boolean) => SubscriptionContractsQueryBuilder; /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. * @documentationMaturity preview */ ascending: (...propertyNames: Array<'_id' | 'buyerInfo.contactId'>) => SubscriptionContractsQueryBuilder; /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. * @documentationMaturity preview */ descending: (...propertyNames: Array<'_id' | 'buyerInfo.contactId'>) => SubscriptionContractsQueryBuilder; /** @param limit - Number of items to return, which is also the `pageSize` of the results object. * @documentationMaturity preview */ limit: (limit: number) => SubscriptionContractsQueryBuilder; /** @param cursor - A pointer to specific record * @documentationMaturity preview */ skipTo: (cursor: string) => SubscriptionContractsQueryBuilder; /** @documentationMaturity preview */ find: () => Promise; } /** * @hidden * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts * @requiredField query */ declare function typedQuerySubscriptionContracts(query: SubscriptionContractQuery): Promise>; interface SubscriptionContractQuerySpec extends QuerySpec { paging: 'cursor'; wql: [ { fields: ['_id', 'buyerInfo.contactId']; operators: '*'; sort: 'BOTH'; } ]; } type CommonQueryWithEntityContext = Query; type SubscriptionContractQuery = { /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: { /** Maximum number of items to return in the results. @max: 100 */ limit?: NonNullable['limit'] | null; /** Pointer to the next or previous page in the list of results. Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response. Not relevant for the first request. @maxLength: 16000 */ cursor?: NonNullable['cursor'] | null; }; /** Filter object in the following format: `"filter" : { "fieldName1": "value1", "fieldName2":{"$operator":"value2"} }` Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains` Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section). */ filter?: CommonQueryWithEntityContext['filter'] | null; /** Sort object in the following format: `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section). @maxSize: 5 */ sort?: { /** Name of the field to sort by. @maxLength: 512 */ fieldName?: NonNullable[number]['fieldName']; /** Sort order. */ order?: NonNullable[number]['order']; }[]; }; declare const utils: { query: { QueryBuilder: () => _wix_sdk_types.QueryBuilder; Filter: _wix_sdk_types.FilterFactory; Sort: _wix_sdk_types.SortFactory; }; }; export { type AccountInfo, type AccountInfoMetadata, type ActionEvent, ActionInitiator, type ActionInitiatorWithLiterals, type AdditionalFee, AdditionalFeeSource, type AdditionalFeeSourceWithLiterals, type Address, type AddressLocation, type AddressWithContact, AdjustmentType, type AdjustmentTypeWithLiterals, type ApplicationError, type AppliedDiscount, type AppliedDiscountDiscountSourceOneOf, type BaseEventMetadata, type BillingAdjustment, type BillingAdjustmentPriceSummary, type BillingSettings, type BulkActionMetadata, type BulkCreateSubscriptionContractsRequest, type BulkCreateSubscriptionContractsResponse, type BulkSubscriptionContractResult, type BulkUpdateSubscriptionContractsRequest, type BulkUpdateSubscriptionContractsResponse, type BuyerInfo, type BuyerInfoIdOneOf, type CatalogReference, type ChannelInfo, ChannelType, type ChannelTypeWithLiterals, ChargeType, type ChargeTypeWithLiterals, type Color, type CommonQueryWithEntityContext, type Coupon, type CreateSubscriptionContractRequest, type CreateSubscriptionContractResponse, type CurrencyConversionDetails, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type CustomField, type DeliveryLogistics, type DeliveryLogisticsAddressOneOf, type DeliveryTimeSlot, type DescriptionLine, type DescriptionLineDescriptionLineValueOneOf, type DescriptionLineName, DescriptionLineType, type DescriptionLineTypeWithLiterals, type DescriptionLineValueOneOf, type DigitalFile, type Dimensions, DimensionsUnit, type DimensionsUnitWithLiterals, DiscountReason, type DiscountReasonWithLiterals, type DiscountRule, type DiscountRuleName, DiscountType, type DiscountTypeWithLiterals, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EventMetadata, type ExtendedFields, type FocalPoint, type FreeTrialPeriod, type FullAddressContactDetails, type GetSubscriptionContractRequest, type GetSubscriptionContractResponse, type IdentificationData, type IdentificationDataIdOneOf, type ItemCombination, type ItemCombinationLineItem, type ItemMetadata, type ItemModifier, type ItemTaxFullDetails, type ItemType, type ItemTypeItemTypeDataOneOf, ItemTypePreset, type ItemTypePresetWithLiterals, JurisdictionType, type JurisdictionTypeWithLiterals, type LineItemDiscount, type LineItemTaxBreakdown, type LineItemTaxInfo, type Location, type LocationAndQuantity, type MaskedSubscriptionContract, type MerchantDiscount, type MerchantDiscountMerchantDiscountReasonOneOf, type MessageEnvelope, type ModifierGroup, type OrderLineItem, type OrderTaxBreakdown, type OrderTaxInfo, PaymentOptionType, type PaymentOptionTypeWithLiterals, type PhysicalProperties, type PickupAddress, type PickupDetails, PickupMethod, type PickupMethodWithLiterals, type PlainTextValue, type PlatformFee, type PlatformFeeSummary, type Price, type PriceDescription, type PriceSummary, type ProductName, type QuerySubscriptionContractsRequest, type QuerySubscriptionContractsResponse, type RestockLocation, type RestoreInfo, type ShippingInformation, type ShippingPrice, type ShippingRegion, SortOrder, type SortOrderWithLiterals, type Sorting, SpecificItemsCouponBehavior, type SpecificItemsCouponBehaviorWithLiterals, type StreetAddress, type SubscriptionContract, type SubscriptionContractCanceled, type SubscriptionContractCreatedEnvelope, type SubscriptionContractDeletedEnvelope, type SubscriptionContractExpired, type SubscriptionContractQuery, type SubscriptionContractQuerySpec, type SubscriptionContractSettings, type SubscriptionContractUpdatedEnvelope, type SubscriptionContractsQueryBuilder, type SubscriptionContractsQueryResult, type SubscriptionDescription, SubscriptionFrequency, type SubscriptionFrequencyWithLiterals, type SubscriptionInfo, type SubscriptionSettings, type SubscriptionTitle, type TaxableAddress, type TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, type TaxableAddressTypeWithLiterals, type TranslatableString, type UpdateSubscriptionContractRequest, type UpdateSubscriptionContractResponse, type V1BillingSettings, type V1FreeTrialPeriod, type V1SubscriptionDescription, type V1SubscriptionSettings, type V1SubscriptionTitle, V2SubscriptionFrequency, type V2SubscriptionFrequencyWithLiterals, type VatId, VatType, type VatTypeWithLiterals, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, WeightUnit, type WeightUnitWithLiterals, getSubscriptionContract, onSubscriptionContractCreated, onSubscriptionContractDeleted, onSubscriptionContractUpdated, querySubscriptionContracts, typedQuerySubscriptionContracts, utils };