@wix/auto_sdk_ecom_subscription-contracts 1.0.84 → 1.0.85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +9 -0
- package/build/cjs/index.typings.js.map +1 -1
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +9 -0
- package/build/es/index.typings.mjs.map +1 -1
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +9 -0
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +9 -0
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/package.json +2 -2
package/build/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../index.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.ts"],"sourcesContent":["export * from './src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js';\n","import { renameKeysFromRESTResponseToSDKResponse } from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { transformRESTAddressToSDKAddress } from '@wix/sdk-runtime/transformations/address';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTImageToSDKImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { EventDefinition, HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n QuerySubscriptionContractsResponse,\n SubscriptionContract,\n SubscriptionContractCreatedEnvelope,\n SubscriptionContractDeletedEnvelope,\n SubscriptionContractQuery,\n SubscriptionContractUpdatedEnvelope,\n SubscriptionContractsQueryBuilder,\n getSubscriptionContract as universalGetSubscriptionContract,\n querySubscriptionContracts as universalQuerySubscriptionContracts,\n typedQuerySubscriptionContracts as universalTypedQuerySubscriptionContracts,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/ecom' };\n\nexport function getSubscriptionContract(\n httpClient: HttpClient\n): GetSubscriptionContractSignature {\n return (subscriptionContractId: string) =>\n universalGetSubscriptionContract(\n subscriptionContractId,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetSubscriptionContractSignature {\n /**\n * Retrieves a SubscriptionContract.\n * @param - ID of the SubscriptionContract to retrieve.\n * @returns The requested SubscriptionContract.\n */\n (subscriptionContractId: string): Promise<\n NonNullablePaths<\n SubscriptionContract,\n | `subscriptionSettings.frequency`\n | `subscriptionSettings.autoRenewal`\n | `subscriptionSettings.enableCustomerCancellation`\n | `subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionSettings.freeTrialPeriod.interval`\n | `lineItems`\n | `lineItems.${number}._id`\n | `lineItems.${number}.productName.original`\n | `lineItems.${number}.catalogReference.catalogItemId`\n | `lineItems.${number}.catalogReference.appId`\n | `lineItems.${number}.quantity`\n | `lineItems.${number}.totalDiscount.amount`\n | `lineItems.${number}.totalDiscount.formattedAmount`\n | `lineItems.${number}.physicalProperties.shippable`\n | `lineItems.${number}.itemType.preset`\n | `lineItems.${number}.itemType.custom`\n | `lineItems.${number}.paymentOption`\n | `lineItems.${number}.taxDetails.taxRate`\n | `lineItems.${number}.taxInfo.taxIncludedInPrice`\n | `lineItems.${number}.digitalFile.fileId`\n | `lineItems.${number}.subscriptionInfo.cycleNumber`\n | `lineItems.${number}.subscriptionInfo.subscriptionOptionTitle`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.frequency`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.autoRenewal`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.enableCustomerCancellation`\n | `lineItems.${number}.priceDescription.original`\n | `lineItems.${number}.taxableAddress.addressType`\n | `lineItems.${number}.priceUndetermined`\n | `buyerInfo.visitorId`\n | `buyerInfo.memberId`\n | `weightUnit`\n | `taxIncludedInPrices`\n | `billingInfo.address.streetAddress.number`\n | `billingInfo.address.streetAddress.name`\n | `billingInfo.contactDetails.vatId._id`\n | `billingInfo.contactDetails.vatId.type`\n | `shippingInfo.title`\n | `shippingInfo.logistics.pickupDetails.pickupMethod`\n | `appliedDiscounts`\n | `appliedDiscounts.${number}.coupon._id`\n | `appliedDiscounts.${number}.coupon.code`\n | `appliedDiscounts.${number}.coupon.name`\n | `appliedDiscounts.${number}.merchantDiscount.discountReason`\n | `appliedDiscounts.${number}.discountRule._id`\n | `appliedDiscounts.${number}.discountRule.name.original`\n | `appliedDiscounts.${number}.discountType`\n | `channelInfo.type`\n | `customFields`\n | `customFields.${number}.title`\n | `additionalFees`\n | `additionalFees.${number}.name`\n | `additionalFees.${number}._id`,\n 6\n >\n >;\n}\n\nexport function querySubscriptionContracts(\n httpClient: HttpClient\n): QuerySubscriptionContractsSignature {\n return () =>\n universalQuerySubscriptionContracts(\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface QuerySubscriptionContractsSignature {\n /**\n * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].\n *\n * Up to 300 SubscriptionContracts can be returned per request.\n *\n * To learn how to query SubscriptionContracts, see [API Query Language][2].\n *\n * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging\n * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language\n */\n (): SubscriptionContractsQueryBuilder;\n}\n\nexport function typedQuerySubscriptionContracts(\n httpClient: HttpClient\n): TypedQuerySubscriptionContractsSignature {\n return (query: SubscriptionContractQuery) =>\n universalTypedQuerySubscriptionContracts(\n query,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface TypedQuerySubscriptionContractsSignature {\n /** */\n (query: SubscriptionContractQuery): Promise<\n NonNullablePaths<\n QuerySubscriptionContractsResponse,\n | `subscriptionContracts`\n | `subscriptionContracts.${number}.subscriptionSettings.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.autoRenewal`\n | `subscriptionContracts.${number}.subscriptionSettings.enableCustomerCancellation`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.interval`\n | `subscriptionContracts.${number}.buyerInfo.visitorId`\n | `subscriptionContracts.${number}.buyerInfo.memberId`\n | `subscriptionContracts.${number}.weightUnit`\n | `subscriptionContracts.${number}.taxIncludedInPrices`\n | `subscriptionContracts.${number}.shippingInfo.title`\n | `subscriptionContracts.${number}.channelInfo.type`,\n 6\n >\n >;\n}\n\nexport const onSubscriptionContractCreated = EventDefinition(\n 'wix.ecom.subscription_contracts.v1.subscription_contract_created',\n true,\n (event: SubscriptionContractCreatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'entity.subscriptionSettings.startDate' },\n { path: 'entity.lineItems.digitalFile.expirationDate' },\n {\n path: 'entity.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'entity.shippingInfo.logistics.deliverByDate' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.from' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.to' },\n { path: 'metadata.eventTime' },\n ],\n },\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'entity.lineItems.image' }],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [{ path: 'entity.lineItems.physicalProperties.weight' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'entity.billingInfo.address' },\n {\n path: 'entity.shippingInfo.logistics.shippingDestination.address',\n },\n { path: 'entity.shippingInfo.logistics.pickupDetails.address' },\n { path: 'entity.recipientInfo.address' },\n ],\n },\n ])\n )\n)<SubscriptionContractCreatedEnvelope>();\nexport const onSubscriptionContractDeleted = EventDefinition(\n 'wix.ecom.subscription_contracts.v1.subscription_contract_deleted',\n true,\n (event: SubscriptionContractDeletedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'undefined.createdDate' },\n { path: 'undefined.updatedDate' },\n { path: 'undefined.subscriptionSettings.startDate' },\n { path: 'undefined.lineItems.digitalFile.expirationDate' },\n {\n path: 'undefined.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'undefined.shippingInfo.logistics.deliverByDate' },\n { path: 'undefined.shippingInfo.logistics.deliveryTimeSlot.from' },\n { path: 'undefined.shippingInfo.logistics.deliveryTimeSlot.to' },\n { path: 'metadata.eventTime' },\n ],\n },\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'undefined.lineItems.image' }],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [{ path: 'undefined.lineItems.physicalProperties.weight' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'undefined.billingInfo.address' },\n {\n path: 'undefined.shippingInfo.logistics.shippingDestination.address',\n },\n { path: 'undefined.shippingInfo.logistics.pickupDetails.address' },\n { path: 'undefined.recipientInfo.address' },\n ],\n },\n ])\n )\n)<SubscriptionContractDeletedEnvelope>();\nexport const onSubscriptionContractUpdated = EventDefinition(\n 'wix.ecom.subscription_contracts.v1.subscription_contract_updated',\n true,\n (event: SubscriptionContractUpdatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'entity.subscriptionSettings.startDate' },\n { path: 'entity.lineItems.digitalFile.expirationDate' },\n {\n path: 'entity.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'entity.shippingInfo.logistics.deliverByDate' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.from' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.to' },\n { path: 'metadata.eventTime' },\n { path: 'modifiedFields.createdDate' },\n { path: 'modifiedFields.updatedDate' },\n { path: 'modifiedFields.subscriptionSettings.startDate' },\n { path: 'modifiedFields.lineItems.digitalFile.expirationDate' },\n {\n path: 'modifiedFields.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'modifiedFields.shippingInfo.logistics.deliverByDate' },\n {\n path: 'modifiedFields.shippingInfo.logistics.deliveryTimeSlot.from',\n },\n {\n path: 'modifiedFields.shippingInfo.logistics.deliveryTimeSlot.to',\n },\n ],\n },\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [\n { path: 'entity.lineItems.image' },\n { path: 'modifiedFields.lineItems.image' },\n ],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n { path: 'entity.lineItems.physicalProperties.weight' },\n { path: 'modifiedFields.lineItems.physicalProperties.weight' },\n ],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'entity.billingInfo.address' },\n {\n path: 'entity.shippingInfo.logistics.shippingDestination.address',\n },\n { path: 'entity.shippingInfo.logistics.pickupDetails.address' },\n { path: 'entity.recipientInfo.address' },\n { path: 'modifiedFields.billingInfo.address' },\n {\n path: 'modifiedFields.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'modifiedFields.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'modifiedFields.recipientInfo.address' },\n ],\n },\n ])\n )\n)<SubscriptionContractUpdatedEnvelope>();\n\nexport {\n AccountInfo,\n ActionEvent,\n AdditionalFee,\n AdditionalFeeSource,\n Address,\n AddressLocation,\n AddressWithContact,\n AdjustmentType,\n ApplicationError,\n AppliedDiscount,\n AppliedDiscountDiscountSourceOneOf,\n BaseEventMetadata,\n BillingAdjustment,\n BillingAdjustmentPriceSummary,\n BulkActionMetadata,\n BulkCreateSubscriptionContractsRequest,\n BulkCreateSubscriptionContractsResponse,\n BulkSubscriptionContractResult,\n BulkUpdateSubscriptionContractsRequest,\n BulkUpdateSubscriptionContractsResponse,\n BuyerInfo,\n BuyerInfoIdOneOf,\n CatalogReference,\n ChannelInfo,\n ChannelType,\n ChargeType,\n Color,\n Coupon,\n CreateSubscriptionContractRequest,\n CreateSubscriptionContractResponse,\n CurrencyConversionDetails,\n CursorPaging,\n CursorPagingMetadata,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Cursors,\n CustomField,\n DeliveryLogistics,\n DeliveryLogisticsAddressOneOf,\n DeliveryTimeSlot,\n DescriptionLine,\n DescriptionLineDescriptionLineValueOneOf,\n DescriptionLineName,\n DescriptionLineType,\n DescriptionLineValueOneOf,\n DigitalFile,\n DiscountReason,\n DiscountRule,\n DiscountRuleName,\n DiscountType,\n DomainEvent,\n DomainEventBodyOneOf,\n Empty,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n EventMetadata,\n ExtendedFields,\n FocalPoint,\n FreeTrialPeriod,\n FullAddressContactDetails,\n GetSubscriptionContractRequest,\n GetSubscriptionContractResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemCombination,\n ItemCombinationLineItem,\n ItemMetadata,\n ItemModifier,\n ItemTaxFullDetails,\n ItemType,\n ItemTypeItemTypeDataOneOf,\n ItemTypePreset,\n JurisdictionType,\n LineItemDiscount,\n LineItemTaxBreakdown,\n LineItemTaxInfo,\n Location,\n LocationAndQuantity,\n MaskedSubscriptionContract,\n MerchantDiscount,\n MerchantDiscountMerchantDiscountReasonOneOf,\n MessageEnvelope,\n ModifierGroup,\n OrderLineItem,\n OrderTaxBreakdown,\n OrderTaxInfo,\n PaymentOptionType,\n PhysicalProperties,\n PickupAddress,\n PickupDetails,\n PickupMethod,\n PlainTextValue,\n PlatformFee,\n PlatformFeeSummary,\n Price,\n PriceDescription,\n PriceSummary,\n ProductName,\n QuerySubscriptionContractsRequest,\n QuerySubscriptionContractsResponse,\n RestoreInfo,\n ShippingInformation,\n ShippingPrice,\n ShippingRegion,\n SortOrder,\n Sorting,\n StreetAddress,\n SubscriptionContract,\n SubscriptionContractCreatedEnvelope,\n SubscriptionContractDeletedEnvelope,\n SubscriptionContractQuerySpec,\n SubscriptionContractUpdatedEnvelope,\n SubscriptionContractsQueryBuilder,\n SubscriptionContractsQueryResult,\n SubscriptionDescription,\n SubscriptionFrequency,\n SubscriptionInfo,\n SubscriptionSettings,\n SubscriptionTitle,\n TaxableAddress,\n TaxableAddressTaxableAddressDataOneOf,\n TaxableAddressType,\n TranslatableString,\n UpdateSubscriptionContractRequest,\n UpdateSubscriptionContractResponse,\n V1FreeTrialPeriod,\n V1SubscriptionDescription,\n V1SubscriptionSettings,\n V1SubscriptionTitle,\n V2SubscriptionFrequency,\n VatId,\n VatType,\n WebhookIdentityType,\n WeightUnit,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport { queryBuilder } from '@wix/sdk-runtime/query-builder';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport {\n HttpClient,\n HttpResponse,\n NonNullablePaths,\n QuerySpec,\n Query as QuerySdkType,\n} from '@wix/sdk-types';\nimport * as ambassadorWixEcomSubscriptionContractsV1SubscriptionContract from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js';\n// @ts-ignore\nimport { transformRESTAddressToSDKAddress } from '@wix/sdk-runtime/transformations/address';\nimport { transformRESTImageToSDKImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\n\n/**\n * A SubscriptionContract is a ...\n * You can ...\n * Read more about SubscriptionContracts\n * in this [article](<LINK_TO_KB_ARTICLE>).\n */\nexport interface SubscriptionContract {\n /**\n * SubscriptionContract ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Revision number, which increments by 1 each time the SubscriptionContract is updated.\n * To prevent conflicting changes, the current revision must be passed when updating the SubscriptionContract.\n *\n * Ignored when creating a SubscriptionOrderContract.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the subscription contract was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * 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.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @maxLength 500\n * @deprecated Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @replacedBy subscription_description\n * @targetRemovalDate 2025-10-01\n */\n description?: string | null;\n /**\n * Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @internal\n */\n subscriptionDescription?: V1SubscriptionDescription;\n /**\n * Subscription detailed information.\n * @immutable\n */\n subscriptionSettings?: V1SubscriptionSettings;\n /**\n * Order line items.\n * @minSize 1\n * @maxSize 1\n */\n lineItems?: OrderLineItem[];\n /** Buyer information. */\n buyerInfo?: BuyerInfo;\n /**\n * Language for communication with the buyer. Defaults to the site language.\n * For a site that supports multiple languages, this is the language the buyer selected.\n */\n buyerLanguage?: string | null;\n /** Weight measurement unit - defaults to site's weight unit. */\n weightUnit?: WeightUnitWithLiterals;\n /**\n * 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.\n * @format CURRENCY\n * @immutable\n */\n currency?: string | null;\n /** Multi-currency information of the subscription. conversionRate may reflect updated exchange rate on created order per recurring cycle. */\n currencyConversionDetails?: CurrencyConversionDetails;\n /**\n * Whether tax is included in line item prices.\n *\n * Default: `false`\n * @immutable\n */\n taxIncludedInPrices?: boolean;\n /**\n * Order price summary.\n * @readonly\n */\n priceSummary?: PriceSummary;\n /**\n * Summary of all platform fees added to the order.\n * @internal\n */\n platformFeeSummary?: PlatformFeeSummary;\n /** Billing address and contact details. */\n billingInfo?: AddressWithContact;\n /** Shipping info and selected shipping option details. */\n shippingInfo?: ShippingInformation;\n /** Applied discounts. */\n appliedDiscounts?: AppliedDiscount[];\n /** Information about the sales channel that submitted this order. */\n channelInfo?: ChannelInfo;\n /** Custom fields. */\n customFields?: CustomField[];\n /**\n * Order recipient address and contact details.\n *\n * This field may differ from the address in `shippingInfo.logistics` when:\n * + The chosen shipping option is pickup point or store pickup.\n * + No shipping option is selected.\n */\n recipientInfo?: AddressWithContact;\n /**\n * Custom field data for the subscription contract object.\n *\n * [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.\n */\n extendedFields?: ExtendedFields;\n /**\n * Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @maxLength 150\n * @deprecated Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @replacedBy subscription_title\n * @targetRemovalDate 2025-10-01\n */\n title?: string | null;\n /**\n * Subscription title. For example, `\"Monthly coffee Subscription\"`.\n * @internal\n */\n subscriptionTitle?: V1SubscriptionTitle;\n /**\n * Additional fees applied to subscription contract.\n * @maxSize 100\n */\n additionalFees?: AdditionalFee[];\n}\n\nexport interface V1SubscriptionDescription {\n /**\n * Subscription option description.\n * @maxLength 500\n */\n original?: string;\n /**\n * Translated subscription option description.\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface V1SubscriptionSettings {\n /** Frequency of recurring payment. */\n frequency?: SubscriptionFrequencyWithLiterals;\n /**\n * Interval of recurring payment.\n * @min 1\n * @max 3650\n */\n interval?: number | null;\n /** Whether subscription is renewed automatically at the end of each period. */\n autoRenewal?: boolean;\n /**\n * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`.\n * @min 1\n */\n billingCycles?: number | null;\n /** Whether to allow the customer to cancel the subscription. */\n enableCustomerCancellation?: boolean;\n /** Period until first cycle starts. If None => no free trial */\n freeTrialPeriod?: V1FreeTrialPeriod;\n /**\n * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.\n * @internal\n */\n startDate?: Date | null;\n}\n\nexport enum SubscriptionFrequency {\n UNDEFINED = 'UNDEFINED',\n DAY = 'DAY',\n WEEK = 'WEEK',\n MONTH = 'MONTH',\n YEAR = 'YEAR',\n}\n\n/** @enumType */\nexport type SubscriptionFrequencyWithLiterals =\n | SubscriptionFrequency\n | 'UNDEFINED'\n | 'DAY'\n | 'WEEK'\n | 'MONTH'\n | 'YEAR';\n\nexport interface V1FreeTrialPeriod {\n /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */\n frequency?: SubscriptionFrequencyWithLiterals;\n /**\n * interval of period\n * @min 1\n * @max 3650\n */\n interval?: number;\n}\n\nexport interface OrderLineItem {\n /**\n * Line item ID.\n * @immutable\n */\n _id?: string;\n /**\n * Item name.\n * + Stores - `product.name`\n * + Bookings - `service.info.name`\n * + Events - `ticket.name`\n */\n productName?: ProductName;\n /**\n * References to the line item's origin catalog.\n * This field may be empty in the case of a custom line item.\n */\n catalogReference?: CatalogReference;\n /**\n * Line item quantity.\n * @min 1\n * @max 100000\n */\n quantity?: number;\n /**\n * Total discount for this line item's entire quantity.\n * @readonly\n */\n totalDiscount?: Price;\n /**\n * Line item description lines. Used for display purposes for the cart, checkout and order.\n * @maxSize 20\n */\n descriptionLines?: DescriptionLine[];\n /** Line item image. */\n image?: string;\n /** Physical properties of the item. When relevant, contains information such as SKU and item weight. */\n physicalProperties?: PhysicalProperties;\n /** Item type. Either a preset type or custom. */\n itemType?: ItemType;\n /**\n * Fulfiller ID. Field is empty when the line item is self-fulfilled.\n * 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).\n * @format GUID\n */\n fulfillerId?: string | null;\n /**\n * Number of items that were refunded.\n * @max 100000\n */\n refundQuantity?: number | null;\n /**\n * Number of items restocked.\n * @max 100000\n */\n restockQuantity?: number | null;\n /** Line item price after line item discounts for display purposes. */\n price?: Price;\n /**\n * Line item price before line item discounts for display purposes. Defaults to `price` when not provided.\n * @readonly\n */\n priceBeforeDiscounts?: Price;\n /**\n * Total price after discounts, and before tax.\n * @readonly\n */\n totalPriceBeforeTax?: Price;\n /**\n * Total price after all discounts and tax.\n * @readonly\n */\n totalPriceAfterTax?: Price;\n /**\n * Type of selected payment option for current item.\n *\n * Default: `FULL_PAYMENT_ONLINE`\n */\n paymentOption?: PaymentOptionTypeWithLiterals;\n /**\n * Deprecated. Use `taxInfo` instead.\n * This field will be removed on September 30, 2024.\n * Tax details for this line item.\n * @deprecated Deprecated. Use `taxInfo` instead.\n * This field will be removed on September 30, 2024.\n * Tax details for this line item.\n * @replacedBy tax_info\n * @targetRemovalDate 2024-09-30\n */\n taxDetails?: ItemTaxFullDetails;\n /** Represents all the relevant tax details for a specific line item. */\n taxInfo?: LineItemTaxInfo;\n /** Digital file identifier, relevant only for items with type DIGITAL. */\n digitalFile?: DigitalFile;\n /** Subscription info. */\n subscriptionInfo?: SubscriptionInfo;\n /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - \"Starts at $67\". */\n priceDescription?: PriceDescription;\n /**\n * Item's price amount to be charged during checkout. Relevant for items with a `paymentOption` value of `\"DEPOSIT_ONLINE\"`.\n * @readonly\n */\n depositAmount?: Price;\n /**\n * Line item locations.\n *\n * The location's total quantity must not exceed the line item quantity.\n * @maxSize 5\n */\n locations?: LocationAndQuantity[];\n /** Total price **after** catalog discounts and line item discounts. */\n lineItemPrice?: Price;\n /** Address used for tax calculation. */\n taxableAddress?: TaxableAddress;\n /**\n * ID of the app managing the inventory.\n * @internal\n * @format GUID\n */\n inventoryAppId?: string | null;\n /**\n * Whether the price is not yet defined, and will be updated after the order is created.\n *\n * Default: `false`\n */\n priceUndetermined?: boolean;\n /**\n * Custom extended fields for the line item object.\n *\n * [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.\n */\n extendedFields?: ExtendedFields;\n /**\n * Modifier groups that were added to the item.\n * @readonly\n * @maxSize 10\n */\n modifierGroups?: ModifierGroup[];\n /**\n * Line item ID in external systems.\n * @internal\n * @minLength 1\n * @maxLength 64\n * @immutable\n */\n externalLineItemId?: string | null;\n}\n\nexport interface ProductName {\n /**\n * __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).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * Item name translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in key:value pairs. Use this optional field to provide more specificity with item selection. The `options` field values differ depending on which catalog is providing the items.\n *\n * For products and variants from a Wix Stores catalog, learn more about [eCommerce integration](https://dev.wix.com/docs/rest/business-solutions/stores/catalog/e-commerce-integration).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface Price {\n /**\n * Amount.\n * @decimalValue options { gte:0, lte:1000000000000000 }\n */\n amount?: string;\n /**\n * Amount formatted with currency symbol.\n * @readonly\n */\n formattedAmount?: string;\n}\n\nexport interface DescriptionLine\n extends DescriptionLineValueOneOf,\n DescriptionLineDescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n /** Description line name. */\n name?: DescriptionLineName;\n /**\n * Whether the description line originates from a modifier.\n * @internal\n * @deprecated Whether the description line originates from a modifier.\n * @replacedBy none\n * @targetRemovalDate 2025-12-31\n */\n modifierDescriptionLine?: boolean;\n}\n\n/** @oneof */\nexport interface DescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n}\n\n/** @oneof */\nexport interface DescriptionLineDescriptionLineValueOneOf {}\n\nexport interface DescriptionLineName {\n /**\n * 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).\n * @maxLength 100\n */\n original?: string;\n /**\n * Description line name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 200\n */\n translated?: string | null;\n}\n\nexport interface PlainTextValue {\n /**\n * 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).\n * @maxLength 600\n */\n original?: string;\n /**\n * Description line plain text value translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 600\n */\n translated?: string | null;\n}\n\nexport interface Color {\n /**\n * 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).\n * @maxLength 500\n */\n original?: string;\n /**\n * Description line color name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 500\n */\n translated?: string | null;\n /** HEX or RGB color code for display. */\n code?: string | null;\n}\n\nexport enum DescriptionLineType {\n /** Unrecognized type. */\n UNRECOGNISED = 'UNRECOGNISED',\n /** Plain text type. */\n PLAIN_TEXT = 'PLAIN_TEXT',\n /** Color type. */\n COLOR = 'COLOR',\n}\n\n/** @enumType */\nexport type DescriptionLineTypeWithLiterals =\n | DescriptionLineType\n | 'UNRECOGNISED'\n | 'PLAIN_TEXT'\n | 'COLOR';\n\nexport interface FocalPoint {\n /** X-coordinate of the focal point. */\n x?: number;\n /** Y-coordinate of the focal point. */\n y?: number;\n /** crop by height */\n height?: number | null;\n /** crop by width */\n width?: number | null;\n}\n\nexport interface PhysicalProperties {\n /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */\n weight?: number | null;\n /**\n * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).\n * @maxLength 40\n */\n sku?: string | null;\n /** Whether this line item is shippable. */\n shippable?: boolean;\n}\n\nexport interface ItemType extends ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePresetWithLiterals;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\n/** @oneof */\nexport interface ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePresetWithLiterals;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\nexport enum ItemTypePreset {\n UNRECOGNISED = 'UNRECOGNISED',\n PHYSICAL = 'PHYSICAL',\n DIGITAL = 'DIGITAL',\n GIFT_CARD = 'GIFT_CARD',\n SERVICE = 'SERVICE',\n}\n\n/** @enumType */\nexport type ItemTypePresetWithLiterals =\n | ItemTypePreset\n | 'UNRECOGNISED'\n | 'PHYSICAL'\n | 'DIGITAL'\n | 'GIFT_CARD'\n | 'SERVICE';\n\n/** Type of selected payment option for catalog item */\nexport enum PaymentOptionType {\n /** The entire payment for this item happens as part of the checkout. */\n FULL_PAYMENT_ONLINE = 'FULL_PAYMENT_ONLINE',\n /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */\n FULL_PAYMENT_OFFLINE = 'FULL_PAYMENT_OFFLINE',\n /** 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. */\n MEMBERSHIP = 'MEMBERSHIP',\n /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */\n DEPOSIT_ONLINE = 'DEPOSIT_ONLINE',\n /** 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`. */\n MEMBERSHIP_OFFLINE = 'MEMBERSHIP_OFFLINE',\n /**\n * Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline.\n * @documentationMaturity preview\n */\n MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER = 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER',\n}\n\n/** @enumType */\nexport type PaymentOptionTypeWithLiterals =\n | PaymentOptionType\n | 'FULL_PAYMENT_ONLINE'\n | 'FULL_PAYMENT_OFFLINE'\n | 'MEMBERSHIP'\n | 'DEPOSIT_ONLINE'\n | 'MEMBERSHIP_OFFLINE'\n | 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER';\n\nexport interface ItemTaxFullDetails {\n /** Taxable amount of this line item. */\n taxableAmount?: Price;\n /**\n * Tax rate percentage, as a decimal numeral between 0 and 1. For example, `\"0.13\"`.\n * @decimalValue options { gte:0, maxScale:6 }\n */\n taxRate?: string;\n /** The calculated tax, based on the `taxableAmount` and `taxRate`. */\n totalTax?: Price;\n /**\n * Amount that was exempt from tax calculations.\n * @internal\n */\n exemptAmount?: Price;\n}\n\nexport interface LineItemTaxInfo {\n /** Calculated tax, based on `taxable_amount` and `tax_rate`. */\n taxAmount?: Price;\n /** Amount for which tax is calculated. */\n taxableAmount?: Price;\n /**\n * Tax rate %, as a decimal point.\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, maxScale:6 }\n */\n taxRate?: string | null;\n /**\n * Tax group ID.\n * @format GUID\n */\n taxGroupId?: string | null;\n /** Indicates whether the price already includes tax. */\n taxIncludedInPrice?: boolean;\n /**\n * Tax information for a line item.\n * @maxSize 7\n */\n taxBreakdown?: LineItemTaxBreakdown[];\n /**\n * Amount of the line item price that was exempt from tax.\n * @internal\n */\n exemptAmount?: Price;\n}\n\n/**\n * TaxBreakdown represents tax information for a line item.\n * It holds the tax amount and the tax rate for each tax authority that apply on the line item.\n */\nexport interface LineItemTaxBreakdown {\n /**\n * Jurisdiction that taxes were calculated for. For example, \"New York\", or \"Quebec\".\n * @maxLength 200\n */\n jurisdiction?: string | null;\n /**\n * Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000.\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, maxScale:6 }\n */\n rate?: string | null;\n /** Amount of tax calculated for this line item. */\n taxAmount?: Price;\n /**\n * The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, \"Sales Tax\", \"Income Tax\", \"Value Added Tax\", etc.\n * @maxLength 200\n */\n taxType?: string | null;\n /**\n * The name of the tax against which this tax amount was calculated. For example, \"NY State Sales Tax\", \"Quebec GST\", etc.\n * This name should be explicit enough to allow the merchant to understand what tax was calculated.\n * @maxLength 200\n */\n taxName?: string | null;\n /** Type of jurisdiction that taxes were calculated for. */\n jurisdictionType?: JurisdictionTypeWithLiterals;\n /** Non-taxable amount of the line item price. */\n nonTaxableAmount?: Price;\n /** Taxable amount of the line item price. */\n taxableAmount?: Price;\n /**\n * Amount of the line item price that was exempt from this authority.\n * @internal\n */\n exemptAmount?: Price;\n}\n\n/** JurisdictionType represents the type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */\nexport enum JurisdictionType {\n UNDEFINED = 'UNDEFINED',\n COUNTRY = 'COUNTRY',\n STATE = 'STATE',\n COUNTY = 'COUNTY',\n CITY = 'CITY',\n SPECIAL = 'SPECIAL',\n}\n\n/** @enumType */\nexport type JurisdictionTypeWithLiterals =\n | JurisdictionType\n | 'UNDEFINED'\n | 'COUNTRY'\n | 'STATE'\n | 'COUNTY'\n | 'CITY'\n | 'SPECIAL';\n\nexport interface DigitalFile {\n /**\n * ID of the secure file in media.\n * @minLength 1\n * @maxLength 100\n */\n fileId?: string;\n /**\n * Link will exist after the digital links have been generated on the order.\n * @format WEB_URL\n * @minLength 1\n * @maxLength 2000\n */\n link?: string | null;\n /**\n * Link expiration time and date.\n * @readonly\n */\n expirationDate?: Date | null;\n}\n\nexport interface SubscriptionInfo {\n /**\n * Subscription ID.\n * @format GUID\n */\n _id?: string | null;\n /** Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`. */\n cycleNumber?: number;\n /**\n * Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @maxLength 150\n * @deprecated Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @replacedBy title\n * @targetRemovalDate 2025-10-01\n */\n subscriptionOptionTitle?: string;\n /**\n * Subscription title. For example, `\"Monthly coffee Subscription\"`.\n * @internal\n */\n title?: SubscriptionTitle;\n /**\n * Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @maxLength 500\n * @deprecated Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @replacedBy description\n * @targetRemovalDate 2025-10-01\n */\n subscriptionOptionDescription?: string | null;\n /**\n * Subscription description. For example, `\"1kg of selected coffee, once a month\"`.\n * @internal\n */\n description?: SubscriptionDescription;\n /**\n * Subscription detailed information.\n * @immutable\n */\n subscriptionSettings?: SubscriptionSettings;\n /**\n * Description of the charges that will be applied for subscription.\n * @maxLength 1000\n */\n chargesDescription?: string | null;\n /**\n * Details of the billing adjustment applied to the current subscription cycle due to a shift in the subscription’s billing date.\n * @internal\n */\n billingAdjustment?: BillingAdjustment;\n}\n\nexport interface SubscriptionTitle {\n /**\n * 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).\n * @minLength 1\n * @maxLength 150\n */\n original?: string;\n /**\n * Subscription option name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 150\n */\n translated?: string | null;\n}\n\nexport interface SubscriptionDescription {\n /**\n * Subscription option description.\n * @maxLength 500\n */\n original?: string;\n /**\n * Translated subscription option description.\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface SubscriptionSettings {\n /** Frequency of recurring payment. */\n frequency?: V2SubscriptionFrequencyWithLiterals;\n /**\n * Interval of recurring payment.\n * @min 1\n * @max 3650\n */\n interval?: number | null;\n /** Whether subscription is renewed automatically at the end of each period. */\n autoRenewal?: boolean;\n /**\n * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`.\n * @min 1\n */\n billingCycles?: number | null;\n /** Whether to allow the customer to cancel the subscription. */\n enableCustomerCancellation?: boolean;\n /** Period until first cycle starts. If None => no free trial */\n freeTrialPeriod?: FreeTrialPeriod;\n /**\n * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.\n * @internal\n */\n startDate?: Date | null;\n}\n\n/** Frequency unit of recurring payment */\nexport enum V2SubscriptionFrequency {\n UNDEFINED = 'UNDEFINED',\n DAY = 'DAY',\n WEEK = 'WEEK',\n MONTH = 'MONTH',\n YEAR = 'YEAR',\n}\n\n/** @enumType */\nexport type V2SubscriptionFrequencyWithLiterals =\n | V2SubscriptionFrequency\n | 'UNDEFINED'\n | 'DAY'\n | 'WEEK'\n | 'MONTH'\n | 'YEAR';\n\nexport interface FreeTrialPeriod {\n /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */\n frequency?: V2SubscriptionFrequencyWithLiterals;\n /**\n * interval of period\n * @min 1\n * @max 3650\n */\n interval?: number;\n}\n\nexport interface BillingAdjustment {\n /** The type of adjustment. */\n type?: AdjustmentTypeWithLiterals;\n /** Summary of the prorated adjustment amount. */\n priceSummary?: BillingAdjustmentPriceSummary;\n}\n\nexport enum AdjustmentType {\n UNKNOWN_ADJUSTMENT_TYPE = 'UNKNOWN_ADJUSTMENT_TYPE',\n /** Adjustment increases the total amount due to changes like covering extra billing days. Typically results in an additional fee. */\n EXTRA_CHARGE = 'EXTRA_CHARGE',\n /** Adjustment reduces the total amount due to changes like covering fewer billing days. Typically results in a credit or discount. */\n CREDIT = 'CREDIT',\n}\n\n/** @enumType */\nexport type AdjustmentTypeWithLiterals =\n | AdjustmentType\n | 'UNKNOWN_ADJUSTMENT_TYPE'\n | 'EXTRA_CHARGE'\n | 'CREDIT';\n\nexport interface BillingAdjustmentPriceSummary {\n /** Subtotal of adjustment, before tax. */\n subtotal?: Price;\n /** Tax on adjustment. */\n tax?: Price;\n /** Total price after tax. */\n total?: Price;\n}\n\nexport interface PriceDescription {\n /**\n * __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).\n * @minLength 1\n * @maxLength 100\n */\n original?: string;\n /**\n * Price description translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 100\n */\n translated?: string | null;\n}\n\nexport interface LocationAndQuantity {\n /**\n * Location id in the associated owner app.\n * @format GUID\n */\n _id?: string;\n /**\n * Location owner app, if not provided then the site business info locations will be used.\n * @format GUID\n * @deprecated Location owner app, if not provided then the site business info locations will be used.\n * @targetRemovalDate 2025-03-01\n */\n appId?: string | null;\n /**\n * Quantity for specific location.\n * @min 1\n * @max 100000\n */\n quantity?: number;\n /**\n * Location name.\n * @maxLength 500\n * @readonly\n */\n name?: string | null;\n}\n\nexport interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressTypeWithLiterals;\n}\n\nexport enum TaxableAddressType {\n UNKNOWN_TAXABLE_ADDRESS = 'UNKNOWN_TAXABLE_ADDRESS',\n BUSINESS = 'BUSINESS',\n BILLING = 'BILLING',\n SHIPPING = 'SHIPPING',\n}\n\n/** @enumType */\nexport type TaxableAddressTypeWithLiterals =\n | TaxableAddressType\n | 'UNKNOWN_TAXABLE_ADDRESS'\n | 'BUSINESS'\n | 'BILLING'\n | 'SHIPPING';\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\nexport interface ModifierGroup {\n /**\n * Modifier group ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /** Modifier group name. */\n name?: TranslatableString;\n /**\n * List of modifiers in this group.\n * @minSize 1\n * @maxSize 10\n */\n modifiers?: ItemModifier[];\n}\n\nexport interface TranslatableString {\n /**\n * __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).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * String translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\nexport interface ItemModifier {\n /**\n * Modifier ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /**\n * The quantity of this modifier.\n * @min 1\n * @max 100000\n */\n quantity?: number | null;\n /** Primary display label for the modifier. */\n label?: TranslatableString;\n /** Additional details. */\n details?: TranslatableString;\n /** The price of the modifier. */\n price?: Price;\n}\n\n/** Buyer Info */\nexport interface BuyerInfo extends BuyerInfoIdOneOf {\n /**\n * Visitor ID (if site visitor is not a member).\n * @format GUID\n */\n visitorId?: string;\n /**\n * Member ID (if site visitor is a site member).\n * @format GUID\n */\n memberId?: string;\n /**\n * 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).\n * @format GUID\n */\n contactId?: string | null;\n /**\n * Buyer email address.\n * @format EMAIL\n */\n email?: string | null;\n}\n\n/** @oneof */\nexport interface BuyerInfoIdOneOf {\n /**\n * Visitor ID (if site visitor is not a member).\n * @format GUID\n */\n visitorId?: string;\n /**\n * Member ID (if site visitor is a site member).\n * @format GUID\n */\n memberId?: string;\n}\n\nexport enum WeightUnit {\n /** Weight unit can't be classified due to an error. */\n UNSPECIFIED_WEIGHT_UNIT = 'UNSPECIFIED_WEIGHT_UNIT',\n /** Kilograms. */\n KG = 'KG',\n /** Pounds. */\n LB = 'LB',\n}\n\n/** @enumType */\nexport type WeightUnitWithLiterals =\n | WeightUnit\n | 'UNSPECIFIED_WEIGHT_UNIT'\n | 'KG'\n | 'LB';\n\nexport interface CurrencyConversionDetails {\n /**\n * 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.\n *\n * This currency is used to calculate the pricing before conversion to the buyer's payment currency.\n * @readonly\n * @immutable\n * @format CURRENCY\n */\n originalCurrency?: string | null;\n /**\n * The rate used for converting the original currency to the currency used for payment.\n * @readonly\n * @immutable\n * @decimalValue options { gt:0, lte:1000000000000000 }\n */\n conversionRate?: string | null;\n}\n\nexport interface PriceSummary {\n /** Subtotal of all the line items, before discounts and before tax. */\n subtotal?: Price;\n /** Total shipping price, before discounts and before tax. */\n shipping?: Price;\n /** Total tax on this order. */\n tax?: Price;\n /** Total calculated discount value. */\n discount?: Price;\n /** Order’s total price after discounts and tax. */\n total?: Price;\n /** Total price of additional fees before tax. */\n totalAdditionalFees?: Price;\n}\n\nexport interface PlatformFeeSummary {\n /** Total sum of all platform fees. */\n total?: Price;\n /** Total amount of platform fees with `PASS_ON` charge type. */\n totalPassOn?: Price;\n /** Total amount of platform fees with `ABSORBED` charge type. */\n totalAbsorbed?: Price;\n /**\n * Specific information about each platform fee.\n * @maxSize 300\n */\n fees?: PlatformFee[];\n}\n\nexport interface PlatformFee {\n /** Platform fee name. */\n name?: TranslatableString;\n /** Platform fee amount. */\n amount?: Price;\n /**\n * ID of the line item the platform fee applies to.\n * @format GUID\n */\n lineItemId?: string;\n /** Platform fee charge type. */\n chargeType?: ChargeTypeWithLiterals;\n /**\n * Percentage rate charged as platform fee.\n * The fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%.\n * @format DECIMAL_VALUE\n * @decimalValue options { gt:0, lte:1, maxScale:4 }\n */\n percentageRate?: string;\n}\n\nexport enum ChargeType {\n UNKNOWN_CHARGE_TYPE = 'UNKNOWN_CHARGE_TYPE',\n /**\n * Platform fee passed on to buyer.\n *\n * This type increases the order total, and is visible to the buyer and merchant as an additional fee.\n */\n PASS_ON = 'PASS_ON',\n /**\n * Platform fee absorbed by merchant.\n *\n * This type does not increase the order total, and is only visible to the merchant.\n */\n ABSORBED = 'ABSORBED',\n}\n\n/** @enumType */\nexport type ChargeTypeWithLiterals =\n | ChargeType\n | 'UNKNOWN_CHARGE_TYPE'\n | 'PASS_ON'\n | 'ABSORBED';\n\n/** Billing Info and shipping details */\nexport interface AddressWithContact {\n /** Address. */\n address?: Address;\n /** Contact details. */\n contactDetails?: FullAddressContactDetails;\n}\n\n/** Physical address */\nexport interface Address {\n /**\n * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.\n * @format COUNTRY\n */\n country?: string | null;\n /**\n * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.\n * @maxLength 50\n */\n subdivision?: string | null;\n /**\n * City name.\n * @maxLength 50\n */\n city?: string | null;\n /**\n * Postal or zip code.\n * @maxLength 50\n */\n postalCode?: string | null;\n /** Street address. */\n streetAddress?: StreetAddress;\n /**\n * Main address line (usually street name and number).\n * @maxLength 150\n */\n addressLine1?: string | null;\n /**\n * Free text providing more detailed address info. Usually contains apt, suite, floor.\n * @maxLength 100\n */\n addressLine2?: string | null;\n /** Geocode object containing latitude and longitude coordinates. */\n location?: AddressLocation;\n /**\n * Country's full name.\n * @readonly\n */\n countryFullname?: string | null;\n /**\n * Subdivision full-name.\n * @readonly\n */\n subdivisionFullname?: string | null;\n}\n\nexport interface StreetAddress {\n /** Street number. */\n number?: string;\n /** Street name. */\n name?: string;\n}\n\nexport interface AddressLocation {\n /** Address latitude. */\n latitude?: number | null;\n /** Address longitude. */\n longitude?: number | null;\n}\n\n/** Full contact details for an address */\nexport interface FullAddressContactDetails {\n /**\n * First name.\n * @maxLength 100\n */\n firstName?: string | null;\n /**\n * Last name.\n * @maxLength 100\n */\n lastName?: string | null;\n /**\n * Phone number.\n * @format PHONE\n */\n phone?: string | null;\n /**\n * Company name.\n * @maxLength 1000\n */\n company?: string | null;\n /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */\n vatId?: VatId;\n}\n\nexport interface VatId {\n /** Customer's tax ID. */\n _id?: string;\n /**\n * Tax type.\n *\n * Supported values:\n * + `CPF`: for individual tax payers\n * + `CNPJ`: for corporations\n */\n type?: VatTypeWithLiterals;\n}\n\n/** tax info types */\nexport enum VatType {\n UNSPECIFIED = 'UNSPECIFIED',\n /** CPF - for individual tax payers. */\n CPF = 'CPF',\n /** CNPJ - for corporations */\n CNPJ = 'CNPJ',\n}\n\n/** @enumType */\nexport type VatTypeWithLiterals = VatType | 'UNSPECIFIED' | 'CPF' | 'CNPJ';\n\nexport interface ShippingInformation {\n /**\n * App Def Id of external provider which was a source of shipping info\n * @minLength 1\n * @maxLength 100\n */\n carrierId?: string | null;\n /**\n * Unique code (or ID) of selected shipping option. For example, `\"usps_std_overnight\"`.\n * @minLength 1\n * @maxLength 100\n */\n code?: string | null;\n /**\n * Shipping option title.\n * For example, `\"USPS Standard Overnight Delivery\"`, `\"Standard\"` or `\"First-Class Package International\"`.\n * @maxLength 250\n */\n title?: string;\n /** Shipping logistics. */\n logistics?: DeliveryLogistics;\n /** Shipping costs. */\n cost?: ShippingPrice;\n /** Shipping region. */\n region?: ShippingRegion;\n}\n\nexport interface DeliveryLogistics extends DeliveryLogisticsAddressOneOf {\n /** Shipping address and contact details. */\n shippingDestination?: AddressWithContact;\n /** Pickup details. */\n pickupDetails?: PickupDetails;\n /**\n * Expected delivery time in free text. For example, `\"3-5 business days\"`.\n * @maxLength 500\n */\n deliveryTime?: string | null;\n /**\n * Instructions for carrier. For example, `\"Please knock on the door. If unanswered, please call contact number. Thanks.\"`.\n * @maxLength 1000\n */\n instructions?: string | null;\n /**\n * Deprecated - Latest expected delivery date and time in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * @deprecated\n */\n deliverByDate?: Date | null;\n /** Expected delivery time. */\n deliveryTimeSlot?: DeliveryTimeSlot;\n}\n\n/** @oneof */\nexport interface DeliveryLogisticsAddressOneOf {\n /** Shipping address and contact details. */\n shippingDestination?: AddressWithContact;\n /** Pickup details. */\n pickupDetails?: PickupDetails;\n}\n\nexport interface PickupDetails {\n /** Pickup address. */\n address?: PickupAddress;\n /** Pickup method */\n pickupMethod?: PickupMethodWithLiterals;\n}\n\n/** Physical address */\nexport interface PickupAddress {\n /**\n * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.\n * @format COUNTRY\n */\n country?: string | null;\n /**\n * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.\n * @maxLength 50\n */\n subdivision?: string | null;\n /**\n * City name.\n * @maxLength 1000\n */\n city?: string | null;\n /**\n * Postal or zip code.\n * @maxLength 1000\n */\n postalCode?: string | null;\n /** Street address object, with number, name, and apartment number in separate fields. */\n streetAddress?: StreetAddress;\n /**\n * Main address line (usually street name and number).\n * @maxLength 1000\n */\n addressLine1?: string | null;\n /**\n * Free text providing more detailed address info. Usually contains apt, suite, floor.\n * @maxLength 1000\n */\n addressLine2?: string | null;\n /**\n * Country's full name.\n * @readonly\n */\n countryFullname?: string | null;\n /**\n * Subdivision full-name.\n * @readonly\n */\n subdivisionFullname?: string | null;\n}\n\nexport enum PickupMethod {\n UNKNOWN_METHOD = 'UNKNOWN_METHOD',\n STORE_PICKUP = 'STORE_PICKUP',\n PICKUP_POINT = 'PICKUP_POINT',\n}\n\n/** @enumType */\nexport type PickupMethodWithLiterals =\n | PickupMethod\n | 'UNKNOWN_METHOD'\n | 'STORE_PICKUP'\n | 'PICKUP_POINT';\n\nexport interface DeliveryTimeSlot {\n /** Delivery slot starting time. */\n from?: Date | null;\n /** Delivery slot ending time. */\n to?: Date | null;\n}\n\nexport interface ShippingPrice {\n /** Shipping price for display purposes. */\n price?: Price;\n /**\n * Total price of shipping after discounts (when relevant), and before tax.\n * @readonly\n */\n totalPriceBeforeTax?: Price;\n /**\n * Shipping price after all discounts (if any exist), and after tax.\n * @readonly\n */\n totalPriceAfterTax?: Price;\n /**\n * Tax details.\n * @deprecated Tax details.\n * @replacedBy tax_info\n * @targetRemovalDate 2026-03-30\n */\n taxDetails?: ItemTaxFullDetails;\n /** Represents all the relevant tax details for a shipping. */\n taxInfo?: LineItemTaxInfo;\n /**\n * Shipping discount before tax.\n * @readonly\n */\n discount?: Price;\n}\n\nexport interface ShippingRegion {\n /**\n * Name of shipping region. For example, `\"Metropolitan London\"`, or `\"Outer Melbourne suburbs\"`.\n * @maxLength 100\n */\n name?: string | null;\n}\n\nexport interface OrderTaxInfo {\n /** Calculated tax, added from line items. */\n totalTax?: Price;\n /**\n * 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.\n * @maxSize 50\n */\n taxBreakdown?: OrderTaxBreakdown[];\n /**\n * Whether the order is exempt from tax calculations.\n *\n * Default: `false`\n * @readonly\n */\n taxExempt?: boolean | null;\n /**\n * The total amount that was exempt from tax calculations.\n * @internal\n * @readonly\n */\n totalExempt?: Price;\n}\n\n/**\n * 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.\n * Tax breakdown is the tax amount split to the tax authorities that applied on the line item.\n */\nexport interface OrderTaxBreakdown {\n /**\n * The name of the tax against which this tax amount was calculated.\n * @maxLength 200\n */\n taxName?: string;\n /**\n * The type of tax that was calculated. Depends on the company's nexus settings as well as the jurisdiction's tax laws.\n * @maxLength 200\n */\n taxType?: string;\n /**\n * The name of the jurisdiction in which this tax detail applies.\n * @maxLength 200\n */\n jurisdiction?: string;\n /** The type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */\n jurisdictionType?: JurisdictionTypeWithLiterals;\n /**\n * The rate at which this tax detail was calculated.\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, maxScale:6 }\n */\n rate?: string;\n /** The sum of all the tax from line items that calculated by the tax identifiers. */\n aggregatedTaxAmount?: Price;\n /**\n * The aggregated exempt amount from all line items for tax identifiers.\n * @internal\n */\n aggregatedExemptAmount?: Price;\n}\n\nexport interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {\n /** Applied coupon info. */\n coupon?: Coupon;\n /** Merchant discount. */\n merchantDiscount?: MerchantDiscount;\n /** Automatic Discount */\n discountRule?: DiscountRule;\n /**\n * Discount type.\n * * `\"GLOBAL\"` - discount applies to entire order.\n * * `\"SPECIFIC-ITEMS\"` - discount applies to specific items.\n * * `\"SHIPPING\"` - discount applies to shipping. For example, free shipping.\n */\n discountType?: DiscountTypeWithLiterals;\n /**\n * IDs of line items discount applies to.\n * Deprecated. Use `line_item_discounts` instead.\n * @format GUID\n * @maxSize 1\n * @deprecated IDs of line items discount applies to.\n * Deprecated. Use `line_item_discounts` instead.\n * @replacedBy line_item_discounts\n * @targetRemovalDate 2024-10-30\n */\n lineItemIds?: string[];\n /**\n * Discount id.\n * @format GUID\n * @immutable\n */\n _id?: string | null;\n /**\n * Number of subscription billing cycles the discount applies to.\n * If None and discount is linked to subscription line item, it applies to all cycles.\n * @internal\n * @min 1\n * @max 999\n */\n subscriptionCycles?: number | null;\n /**\n * A list of item combinations for this applied discount.\n * Each entry represents a unique combination of line items that triggered\n * or received this discount, along with how many times that combination was applied together.\n * Relevant ONLY for BXGY and Quantity-based promotions.\n * In BXGY the combination will contain the \"X\" items with discount amount of 0.\n * @internal\n * @maxSize 1000\n */\n itemCombinations?: ItemCombination[];\n}\n\n/** @oneof */\nexport interface AppliedDiscountDiscountSourceOneOf {\n /** Applied coupon info. */\n coupon?: Coupon;\n /** Merchant discount. */\n merchantDiscount?: MerchantDiscount;\n /** Automatic Discount */\n discountRule?: DiscountRule;\n}\n\nexport enum DiscountType {\n GLOBAL = 'GLOBAL',\n SPECIFIC_ITEMS = 'SPECIFIC_ITEMS',\n SHIPPING = 'SHIPPING',\n}\n\n/** @enumType */\nexport type DiscountTypeWithLiterals =\n | DiscountType\n | 'GLOBAL'\n | 'SPECIFIC_ITEMS'\n | 'SHIPPING';\n\n/** Coupon */\nexport interface Coupon {\n /** Coupon ID. */\n _id?: string;\n /** Coupon code. */\n code?: string;\n /** Coupon name. */\n name?: string;\n /** Coupon value. */\n amount?: Price;\n}\n\nexport interface MerchantDiscount\n extends MerchantDiscountMerchantDiscountReasonOneOf {\n /**\n * Pre-defined discount reason (optional).\n * * `\"ITEMS_EXCHANGE\"` - exchange balance acquired as a result of items exchange.\n */\n discountReason?: DiscountReasonWithLiterals;\n /**\n * Discount description as free text (optional).\n * @maxLength 200\n */\n description?: string | null;\n /** Discount amount. */\n amount?: Price;\n /**\n * Discount percentage.\n * @internal\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, lte:100, maxScale:2 }\n */\n percentage?: string | null;\n}\n\n/** @oneof */\nexport interface MerchantDiscountMerchantDiscountReasonOneOf {\n /**\n * Pre-defined discount reason (optional).\n * * `\"ITEMS_EXCHANGE\"` - exchange balance acquired as a result of items exchange.\n */\n discountReason?: DiscountReasonWithLiterals;\n /**\n * Discount description as free text (optional).\n * @maxLength 200\n */\n description?: string | null;\n}\n\nexport enum DiscountReason {\n UNSPECIFIED = 'UNSPECIFIED',\n EXCHANGED_ITEMS = 'EXCHANGED_ITEMS',\n BILLING_ADJUSTMENT = 'BILLING_ADJUSTMENT',\n}\n\n/** @enumType */\nexport type DiscountReasonWithLiterals =\n | DiscountReason\n | 'UNSPECIFIED'\n | 'EXCHANGED_ITEMS'\n | 'BILLING_ADJUSTMENT';\n\nexport interface DiscountRule {\n /**\n * Discount rule ID\n * @format GUID\n */\n _id?: string;\n /** Discount rule name */\n name?: DiscountRuleName;\n /** Discount value. */\n amount?: Price;\n}\n\nexport interface DiscountRuleName {\n /**\n * Original discount rule name (in site's default language).\n * @minLength 1\n * @maxLength 256\n */\n original?: string;\n /**\n * Translated discount rule name according to buyer language. Defaults to `original` when not provided.\n * @minLength 1\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface LineItemDiscount {\n /**\n * ID of line item the discount applies to.\n * @format GUID\n */\n _id?: string;\n /** Total discount for this line item. */\n totalDiscount?: Price;\n}\n\nexport interface ItemCombination {\n /**\n * The number of times this exact combination of items (with the specified quantities) was applied together in the order.\n * @min 1\n * @max 100000\n */\n count?: number;\n /**\n * Line items that participated together in this combination.\n * @minSize 1\n * @maxSize 100\n */\n lineItems?: ItemCombinationLineItem[];\n}\n\nexport interface ItemCombinationLineItem {\n /**\n * The unique ID of the line item to which this discount applies.\n * @format GUID\n */\n lineItemId?: string;\n /** Total discount amount for all units (quantity) of this line item in this combination. */\n discountAmount?: Price;\n /**\n * Number of units from this line item that participated in a single combination.\n * @min 1\n * @max 100000\n */\n quantity?: number;\n}\n\nexport interface ChannelInfo {\n /** Sales channel that submitted the order. */\n type?: ChannelTypeWithLiterals;\n /**\n * Reference to an order ID from an external system.\n * @maxLength 100\n */\n externalOrderId?: string | null;\n /**\n * URL to the order in the external system.\n * @maxLength 300\n */\n externalOrderUrl?: string | null;\n}\n\nexport enum ChannelType {\n /** Unspecified sales channel. This value is not supported. */\n UNSPECIFIED = 'UNSPECIFIED',\n /** A web client. */\n WEB = 'WEB',\n /** [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). */\n POS = 'POS',\n /** [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). */\n EBAY = 'EBAY',\n /** [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). */\n AMAZON = 'AMAZON',\n /** Other sales platform. */\n OTHER_PLATFORM = 'OTHER_PLATFORM',\n /** [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). */\n WIX_APP_STORE = 'WIX_APP_STORE',\n /** 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) */\n WIX_INVOICES = 'WIX_INVOICES',\n /** Wix merchant backoffice. */\n BACKOFFICE_MERCHANT = 'BACKOFFICE_MERCHANT',\n /** Wish sales channel. */\n WISH = 'WISH',\n /** [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). */\n CLASS_PASS = 'CLASS_PASS',\n /** Global-E sales channel. */\n GLOBAL_E = 'GLOBAL_E',\n /** [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). */\n FACEBOOK = 'FACEBOOK',\n /** [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). */\n ETSY = 'ETSY',\n /** [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). */\n TIKTOK = 'TIKTOK',\n /** [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). */\n FAIRE_COM = 'FAIRE_COM',\n /** PayPal Agentic Checkout sales channel. */\n PAYPAL_AGENTIC_CHECKOUT = 'PAYPAL_AGENTIC_CHECKOUT',\n}\n\n/** @enumType */\nexport type ChannelTypeWithLiterals =\n | ChannelType\n | 'UNSPECIFIED'\n | 'WEB'\n | 'POS'\n | 'EBAY'\n | 'AMAZON'\n | 'OTHER_PLATFORM'\n | 'WIX_APP_STORE'\n | 'WIX_INVOICES'\n | 'BACKOFFICE_MERCHANT'\n | 'WISH'\n | 'CLASS_PASS'\n | 'GLOBAL_E'\n | 'FACEBOOK'\n | 'ETSY'\n | 'TIKTOK'\n | 'FAIRE_COM'\n | 'PAYPAL_AGENTIC_CHECKOUT';\n\nexport interface CustomField {\n /** Custom field value. */\n value?: any;\n /**\n * Custom field title.\n * @minLength 1\n * @maxLength 500\n */\n title?: string;\n /**\n * Translated custom field title.\n * @minLength 1\n * @maxLength 500\n */\n translatedTitle?: string | null;\n}\n\nexport interface V1SubscriptionTitle {\n /**\n * 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).\n * @minLength 1\n * @maxLength 150\n */\n original?: string;\n /**\n * Subscription option name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 150\n */\n translated?: string | null;\n}\n\nexport interface AdditionalFee {\n /**\n * Additional fee's unique code for future processing.\n * @minLength 1\n * @maxLength 100\n */\n code?: string | null;\n /**\n * Name of additional fee.\n * @minLength 1\n * @maxLength 50\n */\n name?: string;\n /** Additional fee's price. */\n price?: Price;\n /**\n * Tax details.\n * @deprecated Tax details.\n * @replacedBy tax_info\n * @targetRemovalDate 2026-03-30\n */\n taxDetails?: ItemTaxFullDetails;\n /** Represents all the relevant tax details for additional fee. */\n taxInfo?: LineItemTaxInfo;\n /**\n * SPI implementer's `appId`.\n * @format GUID\n */\n providerAppId?: string | null;\n /** Additional fee's price before tax. */\n priceBeforeTax?: Price;\n /** Additional fee's price after tax. */\n priceAfterTax?: Price;\n /**\n * Additional fee's id.\n * @format GUID\n * @immutable\n */\n _id?: string;\n /**\n * Optional - Line items associated with this additional fee.\n * If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order.\n * @format GUID\n */\n lineItemIds?: string[];\n /**\n * Number of subscription billing cycles the additional fee applies to.\n * If None and additional fee is linked to subscription line item, it applies to all cycles.\n * @internal\n * @min 1\n * @max 999\n */\n subscriptionCycles?: number | null;\n /**\n * Specifies the entity that added the additional fee.\n * @internal\n */\n source?: AdditionalFeeSourceWithLiterals;\n}\n\nexport enum AdditionalFeeSource {\n UNKNOWN_ADDITIONAL_FEE_SOURCE = 'UNKNOWN_ADDITIONAL_FEE_SOURCE',\n /** The additional fee was added by an additional fee service plugin. */\n SERVICE_PLUGIN = 'SERVICE_PLUGIN',\n /** The additional fee was added to the item by a catalog or custom line item. */\n ITEM = 'ITEM',\n /** The additional fee was added manually on request. */\n MANUAL = 'MANUAL',\n /** The additional fee was added by the shipping provider. */\n SHIPPING = 'SHIPPING',\n /** The additional fee was added by the Wix eCommerce platform. */\n PLATFORM = 'PLATFORM',\n}\n\n/** @enumType */\nexport type AdditionalFeeSourceWithLiterals =\n | AdditionalFeeSource\n | 'UNKNOWN_ADDITIONAL_FEE_SOURCE'\n | 'SERVICE_PLUGIN'\n | 'ITEM'\n | 'MANUAL'\n | 'SHIPPING'\n | 'PLATFORM';\n\nexport interface Location {\n /**\n * Location ID.\n * Learn more about the [Wix Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).\n * @format GUID\n */\n _id?: string;\n /**\n * Location name.\n * @minLength 1\n * @maxLength 500\n * @readonly\n */\n name?: string;\n}\n\nexport interface CreateSubscriptionContractRequest {\n /** SubscriptionContract to be created. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface CreateSubscriptionContractResponse {\n /** The created SubscriptionContract. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface GetSubscriptionContractRequest {\n /**\n * ID of the SubscriptionContract to retrieve.\n * @format GUID\n */\n subscriptionContractId: string;\n}\n\nexport interface GetSubscriptionContractResponse {\n /** The requested SubscriptionContract. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface UpdateSubscriptionContractRequest {\n /** SubscriptionContract to be updated, may be partial. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface UpdateSubscriptionContractResponse {\n /** Updated SubscriptionContract. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface QuerySubscriptionContractsRequest {\n /** WQL expression. */\n query?: CursorQuery;\n}\n\nexport interface CursorQuery extends CursorQueryPagingMethodOneOf {\n /** 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`. */\n cursorPaging?: CursorPaging;\n /**\n * Filter object in the following format:\n * `\"filter\" : {\n * \"fieldName1\": \"value1\",\n * \"fieldName2\":{\"$operator\":\"value2\"}\n * }`\n * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`\n * Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).\n */\n filter?: Record<string, any> | null;\n /**\n * Sort object in the following format:\n * `[{\"fieldName\":\"sortField1\",\"order\":\"ASC\"},{\"fieldName\":\"sortField2\",\"order\":\"DESC\"}]`\n * Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section).\n * @maxSize 5\n */\n sort?: Sorting[];\n}\n\n/** @oneof */\nexport interface CursorQueryPagingMethodOneOf {\n /** 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`. */\n cursorPaging?: CursorPaging;\n}\n\nexport interface Sorting {\n /**\n * Name of the field to sort by.\n * @maxLength 512\n */\n fieldName?: string;\n /** Sort order. */\n order?: SortOrderWithLiterals;\n}\n\nexport enum SortOrder {\n ASC = 'ASC',\n DESC = 'DESC',\n}\n\n/** @enumType */\nexport type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';\n\nexport interface CursorPaging {\n /**\n * Maximum number of items to return in the results.\n * @max 100\n */\n limit?: number | null;\n /**\n * Pointer to the next or previous page in the list of results.\n *\n * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n * Not relevant for the first request.\n * @maxLength 16000\n */\n cursor?: string | null;\n}\n\nexport interface QuerySubscriptionContractsResponse {\n /** List of SubscriptionContracts. */\n subscriptionContracts?: SubscriptionContract[];\n /** Paging metadata */\n pagingMetadata?: CursorPagingMetadata;\n}\n\nexport interface CursorPagingMetadata {\n /** Number of items returned in the response. */\n count?: number | null;\n /** Cursor strings that point to the next page, previous page, or both. */\n cursors?: Cursors;\n /**\n * Whether there are more pages to retrieve following the current page.\n *\n * + `true`: Another page of results can be retrieved.\n * + `false`: This is the last page.\n */\n hasNext?: boolean | null;\n}\n\nexport interface Cursors {\n /**\n * Cursor string pointing to the next page in the list of results.\n * @maxLength 16000\n */\n next?: string | null;\n /**\n * Cursor pointing to the previous page in the list of results.\n * @maxLength 16000\n */\n prev?: string | null;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * 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.\n * 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.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface Empty {}\n\nexport interface BulkCreateSubscriptionContractsRequest {\n /**\n * List of SubscriptionContracts to create.\n * @minSize 1\n * @maxSize 100\n */\n subscriptionContracts?: SubscriptionContract[];\n /**\n * Whether to return the full subscription contract entities in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface BulkCreateSubscriptionContractsResponse {\n /**\n * Results of the contract created operation.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkSubscriptionContractResult[];\n /** Bulk action metadata. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface BulkSubscriptionContractResult {\n /** Metadata about a single update operation. */\n itemMetadata?: ItemMetadata;\n /**\n * Created subscription contract.\n *\n * Only present if `returnEntity` was `true`.\n */\n item?: SubscriptionContract;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateSubscriptionContractsRequest {\n /**\n * List of SubscriptionContracts to update.\n * @minSize 1\n * @maxSize 100\n */\n subscriptionContracts?: MaskedSubscriptionContract[];\n /**\n * Whether to return the full subscription contract entities in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface MaskedSubscriptionContract {\n /** Subscription contract to be updated. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface BulkUpdateSubscriptionContractsResponse {\n /**\n * Results of the contract updated operation.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkSubscriptionContractResult[];\n /** Metadata about the bulk operation. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\nexport interface BaseEventMetadata {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n}\n\nexport interface EventMetadata extends BaseEventMetadata {\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * 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.\n * 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.\n */\n entityEventSequence?: string | null;\n}\n\nexport interface SubscriptionContractCreatedEnvelope {\n entity: SubscriptionContract;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Read eCommerce - all read permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @webhook\n * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_created\n * @slug created\n * @documentationMaturity preview\n */\nexport declare function onSubscriptionContractCreated(\n handler: (event: SubscriptionContractCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface SubscriptionContractDeletedEnvelope {\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Read eCommerce - all read permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @webhook\n * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_deleted\n * @slug deleted\n * @documentationMaturity preview\n */\nexport declare function onSubscriptionContractDeleted(\n handler: (event: SubscriptionContractDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface SubscriptionContractUpdatedEnvelope {\n entity: SubscriptionContract;\n metadata: EventMetadata;\n /** @hidden */\n modifiedFields: Record<string, any>;\n}\n\n/** @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Read eCommerce - all read permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @webhook\n * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_updated\n * @slug updated\n * @documentationMaturity preview\n */\nexport declare function onSubscriptionContractUpdated(\n handler: (event: SubscriptionContractUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Retrieves a SubscriptionContract.\n * @param subscriptionContractId - ID of the SubscriptionContract to retrieve.\n * @public\n * @documentationMaturity preview\n * @requiredField subscriptionContractId\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @applicableIdentity APP\n * @returns The requested SubscriptionContract.\n * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.GetSubscriptionContract\n */\nexport async function getSubscriptionContract(\n subscriptionContractId: string\n): Promise<\n NonNullablePaths<\n SubscriptionContract,\n | `subscriptionSettings.frequency`\n | `subscriptionSettings.autoRenewal`\n | `subscriptionSettings.enableCustomerCancellation`\n | `subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionSettings.freeTrialPeriod.interval`\n | `lineItems`\n | `lineItems.${number}._id`\n | `lineItems.${number}.productName.original`\n | `lineItems.${number}.catalogReference.catalogItemId`\n | `lineItems.${number}.catalogReference.appId`\n | `lineItems.${number}.quantity`\n | `lineItems.${number}.totalDiscount.amount`\n | `lineItems.${number}.totalDiscount.formattedAmount`\n | `lineItems.${number}.physicalProperties.shippable`\n | `lineItems.${number}.itemType.preset`\n | `lineItems.${number}.itemType.custom`\n | `lineItems.${number}.paymentOption`\n | `lineItems.${number}.taxDetails.taxRate`\n | `lineItems.${number}.taxInfo.taxIncludedInPrice`\n | `lineItems.${number}.digitalFile.fileId`\n | `lineItems.${number}.subscriptionInfo.cycleNumber`\n | `lineItems.${number}.subscriptionInfo.subscriptionOptionTitle`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.frequency`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.autoRenewal`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.enableCustomerCancellation`\n | `lineItems.${number}.priceDescription.original`\n | `lineItems.${number}.taxableAddress.addressType`\n | `lineItems.${number}.priceUndetermined`\n | `buyerInfo.visitorId`\n | `buyerInfo.memberId`\n | `weightUnit`\n | `taxIncludedInPrices`\n | `billingInfo.address.streetAddress.number`\n | `billingInfo.address.streetAddress.name`\n | `billingInfo.contactDetails.vatId._id`\n | `billingInfo.contactDetails.vatId.type`\n | `shippingInfo.title`\n | `shippingInfo.logistics.pickupDetails.pickupMethod`\n | `appliedDiscounts`\n | `appliedDiscounts.${number}.coupon._id`\n | `appliedDiscounts.${number}.coupon.code`\n | `appliedDiscounts.${number}.coupon.name`\n | `appliedDiscounts.${number}.merchantDiscount.discountReason`\n | `appliedDiscounts.${number}.discountRule._id`\n | `appliedDiscounts.${number}.discountRule.name.original`\n | `appliedDiscounts.${number}.discountType`\n | `channelInfo.type`\n | `customFields`\n | `customFields.${number}.title`\n | `additionalFees`\n | `additionalFees.${number}.name`\n | `additionalFees.${number}._id`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n subscriptionContractId: subscriptionContractId,\n });\n\n const reqOpts =\n ambassadorWixEcomSubscriptionContractsV1SubscriptionContract.getSubscriptionContract(\n payload\n );\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(\n transformPaths(result.data, [\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'subscriptionContract.lineItems.image' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'subscriptionContract.billingInfo.address' },\n {\n path: 'subscriptionContract.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'subscriptionContract.recipientInfo.address' },\n ],\n },\n ])\n )?.subscriptionContract!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { subscriptionContractId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['subscriptionContractId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].\n *\n * Up to 300 SubscriptionContracts can be returned per request.\n *\n * To learn how to query SubscriptionContracts, see [API Query Language][2].\n *\n * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging\n * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language\n * @public\n * @documentationMaturity preview\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @applicableIdentity APP\n * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts\n */\nexport function querySubscriptionContracts(): SubscriptionContractsQueryBuilder {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n return queryBuilder<\n SubscriptionContract,\n 'CURSOR',\n QuerySubscriptionContractsRequest,\n QuerySubscriptionContractsResponse\n >({\n func: async (payload: QuerySubscriptionContractsRequest) => {\n const reqOpts =\n ambassadorWixEcomSubscriptionContractsV1SubscriptionContract.querySubscriptionContracts(\n payload\n );\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n return result;\n } catch (err) {\n sideEffects?.onError?.(err);\n throw err;\n }\n },\n requestTransformer: (query: QuerySubscriptionContractsRequest['query']) => {\n const args = [query, {}] as [\n QuerySubscriptionContractsRequest['query'],\n {}\n ];\n return renameKeysFromSDKRequestToRESTRequest({\n ...args?.[1],\n query: args?.[0],\n });\n },\n responseTransformer: ({\n data,\n }: HttpResponse<QuerySubscriptionContractsResponse>) => {\n const transformedData = renameKeysFromRESTResponseToSDKResponse(\n transformPaths(data, [\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'subscriptionContracts.lineItems.image' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'subscriptionContracts.billingInfo.address' },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'subscriptionContracts.recipientInfo.address' },\n ],\n },\n ])\n );\n\n return {\n items: transformedData?.subscriptionContracts,\n pagingMetadata: transformedData?.pagingMetadata,\n };\n },\n errorTransformer: (err: unknown) => {\n const transformedError = sdkTransformError(err, {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { query: '$[0]' },\n singleArgumentUnchanged: false,\n });\n\n throw transformedError;\n },\n pagingMethod: 'CURSOR',\n transformationPaths: {},\n });\n}\n\ninterface QueryCursorResult {\n cursors: Cursors;\n hasNext: () => boolean;\n hasPrev: () => boolean;\n length: number;\n pageSize: number;\n}\n\nexport interface SubscriptionContractsQueryResult extends QueryCursorResult {\n items: SubscriptionContract[];\n query: SubscriptionContractsQueryBuilder;\n next: () => Promise<SubscriptionContractsQueryResult>;\n prev: () => Promise<SubscriptionContractsQueryResult>;\n}\n\nexport interface SubscriptionContractsQueryBuilder {\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n eq: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ne: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ge: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n gt: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n le: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n lt: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `string`.\n * @param string - String to compare against. Case-insensitive.\n * @documentationMaturity preview\n */\n startsWith: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: string\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `values`.\n * @param values - List of values to compare against.\n * @documentationMaturity preview\n */\n hasSome: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any[]\n ) => SubscriptionContractsQueryBuilder;\n /** @documentationMaturity preview */\n in: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @documentationMaturity preview */\n exists: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: boolean\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n ascending: (\n ...propertyNames: Array<'_id' | 'buyerInfo.contactId'>\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n descending: (\n ...propertyNames: Array<'_id' | 'buyerInfo.contactId'>\n ) => SubscriptionContractsQueryBuilder;\n /** @param limit - Number of items to return, which is also the `pageSize` of the results object.\n * @documentationMaturity preview\n */\n limit: (limit: number) => SubscriptionContractsQueryBuilder;\n /** @param cursor - A pointer to specific record\n * @documentationMaturity preview\n */\n skipTo: (cursor: string) => SubscriptionContractsQueryBuilder;\n /** @documentationMaturity preview */\n find: () => Promise<SubscriptionContractsQueryResult>;\n}\n\n/**\n * @hidden\n * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts\n * @requiredField query\n */\nexport async function typedQuerySubscriptionContracts(\n query: SubscriptionContractQuery\n): Promise<\n NonNullablePaths<\n QuerySubscriptionContractsResponse,\n | `subscriptionContracts`\n | `subscriptionContracts.${number}.subscriptionSettings.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.autoRenewal`\n | `subscriptionContracts.${number}.subscriptionSettings.enableCustomerCancellation`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.interval`\n | `subscriptionContracts.${number}.buyerInfo.visitorId`\n | `subscriptionContracts.${number}.buyerInfo.memberId`\n | `subscriptionContracts.${number}.weightUnit`\n | `subscriptionContracts.${number}.taxIncludedInPrices`\n | `subscriptionContracts.${number}.shippingInfo.title`\n | `subscriptionContracts.${number}.channelInfo.type`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({ query: query });\n\n const reqOpts =\n ambassadorWixEcomSubscriptionContractsV1SubscriptionContract.querySubscriptionContracts(\n payload\n );\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(\n transformPaths(result.data, [\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'subscriptionContracts.lineItems.image' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'subscriptionContracts.billingInfo.address' },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'subscriptionContracts.recipientInfo.address' },\n ],\n },\n ])\n )!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { query: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['query']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface SubscriptionContractQuerySpec extends QuerySpec {\n paging: 'cursor';\n wql: [\n {\n fields: ['_id', 'buyerInfo.contactId'];\n operators: '*';\n sort: 'BOTH';\n }\n ];\n}\n\nexport type CommonQueryWithEntityContext = QuerySdkType<\n SubscriptionContract,\n SubscriptionContractQuerySpec\n>;\nexport type SubscriptionContractQuery = {\n /** \n 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`. \n */\n cursorPaging?: {\n /** \n Maximum number of items to return in the results. \n @max: 100 \n */\n limit?:\n | NonNullable<CommonQueryWithEntityContext['cursorPaging']>['limit']\n | null;\n /** \n Pointer to the next or previous page in the list of results.\n\n Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n Not relevant for the first request. \n @maxLength: 16000 \n */\n cursor?:\n | NonNullable<CommonQueryWithEntityContext['cursorPaging']>['cursor']\n | null;\n };\n /** \n Filter object in the following format:\n `\"filter\" : {\n \"fieldName1\": \"value1\",\n \"fieldName2\":{\"$operator\":\"value2\"}\n }`\n Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`\n Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section). \n */\n filter?: CommonQueryWithEntityContext['filter'] | null;\n /** \n Sort object in the following format:\n `[{\"fieldName\":\"sortField1\",\"order\":\"ASC\"},{\"fieldName\":\"sortField2\",\"order\":\"DESC\"}]`\n Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section). \n @maxSize: 5 \n */\n sort?: {\n /** \n Name of the field to sort by. \n @maxLength: 512 \n */\n fieldName?: NonNullable<\n CommonQueryWithEntityContext['sort']\n >[number]['fieldName'];\n /** \n Sort order. \n */\n order?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['order'];\n }[];\n};\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/subscription-contracts/v1/subscription-contracts',\n destPath: '/v1/subscription-contracts',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/ecom/subscription-contracts/v1/subscription-contracts',\n destPath: '/v1/subscription-contracts',\n },\n ],\n _: [\n {\n srcPath: '/ecom/subscription-contracts/v1/subscription-contracts',\n destPath: '/v1/subscription-contracts',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_subscription-contracts';\n\n/** Retrieves a SubscriptionContract. */\nexport function getSubscriptionContract(\n payload: object\n): RequestOptionsFactory<any> {\n function __getSubscriptionContract({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.subscription_contracts.v1.subscription_contract',\n method: 'GET' as any,\n methodFqn:\n 'wix.ecom.subscription_contracts.v1.SubscriptionContracts.GetSubscriptionContract',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl({\n protoPath: '/v1/subscription-contracts/{subscriptionContractId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'subscriptionContract.createdDate' },\n { path: 'subscriptionContract.updatedDate' },\n { path: 'subscriptionContract.subscriptionSettings.startDate' },\n {\n path: 'subscriptionContract.lineItems.image.urlExpirationDate',\n },\n {\n path: 'subscriptionContract.lineItems.digitalFile.expirationDate',\n },\n {\n path: 'subscriptionContract.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.deliverByDate',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.deliveryTimeSlot.from',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.deliveryTimeSlot.to',\n },\n ],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n { path: 'subscriptionContract.lineItems.image.focalPoint.x' },\n { path: 'subscriptionContract.lineItems.image.focalPoint.y' },\n {\n path: 'subscriptionContract.lineItems.physicalProperties.weight',\n },\n {\n path: 'subscriptionContract.billingInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.billingInfo.address.geocode.longitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.shippingDestination.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.shippingDestination.address.geocode.longitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.pickupDetails.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.pickupDetails.address.geocode.longitude',\n },\n {\n path: 'subscriptionContract.recipientInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.recipientInfo.address.geocode.longitude',\n },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getSubscriptionContract;\n}\n\n/**\n * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].\n *\n * Up to 300 SubscriptionContracts can be returned per request.\n *\n * To learn how to query SubscriptionContracts, see [API Query Language][2].\n *\n * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging\n * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language\n */\nexport function querySubscriptionContracts(\n payload: object\n): RequestOptionsFactory<any> {\n function __querySubscriptionContracts({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.subscription_contracts.v1.subscription_contract',\n method: 'GET' as any,\n methodFqn:\n 'wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl({\n protoPath: '/v1/subscription-contracts/query',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload, true),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'subscriptionContracts.createdDate' },\n { path: 'subscriptionContracts.updatedDate' },\n { path: 'subscriptionContracts.subscriptionSettings.startDate' },\n {\n path: 'subscriptionContracts.lineItems.image.urlExpirationDate',\n },\n {\n path: 'subscriptionContracts.lineItems.digitalFile.expirationDate',\n },\n {\n path: 'subscriptionContracts.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.deliverByDate',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.deliveryTimeSlot.from',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.deliveryTimeSlot.to',\n },\n ],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n { path: 'subscriptionContracts.lineItems.image.focalPoint.x' },\n { path: 'subscriptionContracts.lineItems.image.focalPoint.y' },\n {\n path: 'subscriptionContracts.lineItems.physicalProperties.weight',\n },\n {\n path: 'subscriptionContracts.billingInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.billingInfo.address.geocode.longitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address.geocode.longitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address.geocode.longitude',\n },\n {\n path: 'subscriptionContracts.recipientInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.recipientInfo.address.geocode.longitude',\n },\n ],\n },\n ]),\n fallback: [\n {\n method: 'POST' as any,\n url: resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl({\n protoPath: '/v1/subscription-contracts/query',\n data: payload,\n host,\n }),\n data: payload,\n },\n ],\n };\n\n return metadata;\n }\n\n return __querySubscriptionContracts;\n}\n","import {\n getSubscriptionContract as publicGetSubscriptionContract,\n querySubscriptionContracts as publicQuerySubscriptionContracts,\n typedQuerySubscriptionContracts as publicTypedQuerySubscriptionContracts,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { createEventModule } from '@wix/sdk-runtime/event-definition-modules';\nimport {\n BuildRESTFunction,\n MaybeContext,\n BuildEventDefinition,\n} from '@wix/sdk-types';\nimport { HttpClient } from '@wix/sdk-types';\nimport { createQueryOverloadRouter } from '@wix/sdk-runtime/query-method-router';\nimport {\n SubscriptionContractQuery,\n SubscriptionContractsQueryBuilder,\n typedQuerySubscriptionContracts as universalTypedQuerySubscriptionContracts,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\nimport { onSubscriptionContractCreated as publicOnSubscriptionContractCreated } from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\nimport { onSubscriptionContractDeleted as publicOnSubscriptionContractDeleted } from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\nimport { onSubscriptionContractUpdated as publicOnSubscriptionContractUpdated } from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\n\nfunction customQuerySubscriptionContracts(httpClient: HttpClient) {\n const router = createQueryOverloadRouter({\n builderQueryFunction: () => publicQuerySubscriptionContracts(httpClient)(),\n typedQueryFunction: (query: SubscriptionContractQuery) =>\n publicTypedQuerySubscriptionContracts(httpClient)(query),\n hasOptionsParameter: false,\n });\n\n function overloadedQuery(): SubscriptionContractsQueryBuilder;\n function overloadedQuery(\n query: SubscriptionContractQuery\n ): ReturnType<typeof universalTypedQuerySubscriptionContracts>;\n function overloadedQuery(query?: SubscriptionContractQuery): any {\n return router(...arguments);\n }\n\n return overloadedQuery;\n}\n\nexport const getSubscriptionContract: MaybeContext<\n BuildRESTFunction<typeof publicGetSubscriptionContract> &\n typeof publicGetSubscriptionContract\n> = /*#__PURE__*/ createRESTModule(publicGetSubscriptionContract);\nexport const querySubscriptionContracts: MaybeContext<\n BuildRESTFunction<typeof customQuerySubscriptionContracts> &\n typeof customQuerySubscriptionContracts\n> = /*#__PURE__*/ createRESTModule(customQuerySubscriptionContracts);\n/** */\nexport const onSubscriptionContractCreated: BuildEventDefinition<\n typeof publicOnSubscriptionContractCreated\n> &\n typeof publicOnSubscriptionContractCreated = createEventModule(\n publicOnSubscriptionContractCreated\n);\n/** */\nexport const onSubscriptionContractDeleted: BuildEventDefinition<\n typeof publicOnSubscriptionContractDeleted\n> &\n typeof publicOnSubscriptionContractDeleted = createEventModule(\n publicOnSubscriptionContractDeleted\n);\n/** */\nexport const onSubscriptionContractUpdated: BuildEventDefinition<\n typeof publicOnSubscriptionContractUpdated\n> &\n typeof publicOnSubscriptionContractUpdated = createEventModule(\n publicOnSubscriptionContractUpdated\n);\n\nexport {\n SubscriptionFrequency,\n DescriptionLineType,\n ItemTypePreset,\n PaymentOptionType,\n JurisdictionType,\n V2SubscriptionFrequency,\n AdjustmentType,\n TaxableAddressType,\n WeightUnit,\n ChargeType,\n VatType,\n PickupMethod,\n DiscountType,\n DiscountReason,\n ChannelType,\n AdditionalFeeSource,\n SortOrder,\n WebhookIdentityType,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\nexport {\n SubscriptionContract,\n V1SubscriptionDescription,\n V1SubscriptionSettings,\n V1FreeTrialPeriod,\n OrderLineItem,\n ProductName,\n CatalogReference,\n Price,\n DescriptionLine,\n DescriptionLineValueOneOf,\n DescriptionLineDescriptionLineValueOneOf,\n DescriptionLineName,\n PlainTextValue,\n Color,\n FocalPoint,\n PhysicalProperties,\n ItemType,\n ItemTypeItemTypeDataOneOf,\n ItemTaxFullDetails,\n LineItemTaxInfo,\n LineItemTaxBreakdown,\n DigitalFile,\n SubscriptionInfo,\n SubscriptionTitle,\n SubscriptionDescription,\n SubscriptionSettings,\n FreeTrialPeriod,\n BillingAdjustment,\n BillingAdjustmentPriceSummary,\n PriceDescription,\n LocationAndQuantity,\n TaxableAddress,\n TaxableAddressTaxableAddressDataOneOf,\n ExtendedFields,\n ModifierGroup,\n TranslatableString,\n ItemModifier,\n BuyerInfo,\n BuyerInfoIdOneOf,\n CurrencyConversionDetails,\n PriceSummary,\n PlatformFeeSummary,\n PlatformFee,\n AddressWithContact,\n Address,\n StreetAddress,\n AddressLocation,\n FullAddressContactDetails,\n VatId,\n ShippingInformation,\n DeliveryLogistics,\n DeliveryLogisticsAddressOneOf,\n PickupDetails,\n PickupAddress,\n DeliveryTimeSlot,\n ShippingPrice,\n ShippingRegion,\n OrderTaxInfo,\n OrderTaxBreakdown,\n AppliedDiscount,\n AppliedDiscountDiscountSourceOneOf,\n Coupon,\n MerchantDiscount,\n MerchantDiscountMerchantDiscountReasonOneOf,\n DiscountRule,\n DiscountRuleName,\n LineItemDiscount,\n ItemCombination,\n ItemCombinationLineItem,\n ChannelInfo,\n CustomField,\n V1SubscriptionTitle,\n AdditionalFee,\n Location,\n CreateSubscriptionContractRequest,\n CreateSubscriptionContractResponse,\n GetSubscriptionContractRequest,\n GetSubscriptionContractResponse,\n UpdateSubscriptionContractRequest,\n UpdateSubscriptionContractResponse,\n QuerySubscriptionContractsRequest,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Sorting,\n CursorPaging,\n QuerySubscriptionContractsResponse,\n CursorPagingMetadata,\n Cursors,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n Empty,\n BulkCreateSubscriptionContractsRequest,\n BulkCreateSubscriptionContractsResponse,\n BulkSubscriptionContractResult,\n ItemMetadata,\n ApplicationError,\n BulkActionMetadata,\n BulkUpdateSubscriptionContractsRequest,\n MaskedSubscriptionContract,\n BulkUpdateSubscriptionContractsResponse,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n AccountInfo,\n BaseEventMetadata,\n EventMetadata,\n SubscriptionContractCreatedEnvelope,\n SubscriptionContractDeletedEnvelope,\n SubscriptionContractUpdatedEnvelope,\n SubscriptionContractsQueryResult,\n SubscriptionContractsQueryBuilder,\n SubscriptionContractQuerySpec,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\nexport {\n SubscriptionFrequencyWithLiterals,\n DescriptionLineTypeWithLiterals,\n ItemTypePresetWithLiterals,\n PaymentOptionTypeWithLiterals,\n JurisdictionTypeWithLiterals,\n V2SubscriptionFrequencyWithLiterals,\n AdjustmentTypeWithLiterals,\n TaxableAddressTypeWithLiterals,\n WeightUnitWithLiterals,\n ChargeTypeWithLiterals,\n VatTypeWithLiterals,\n PickupMethodWithLiterals,\n DiscountTypeWithLiterals,\n DiscountReasonWithLiterals,\n ChannelTypeWithLiterals,\n AdditionalFeeSourceWithLiterals,\n SortOrderWithLiterals,\n WebhookIdentityTypeWithLiterals,\n CommonQueryWithEntityContext,\n SubscriptionContractQuery,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAAA;AAAA,EAAA,qCAAAC;AAAA,EAAA,qCAAAC;AAAA,EAAA,qCAAAC;AAAA,EAAA,kCAAAC;AAAA;AAAA;;;ACAA,IAAAC,iCAAwD;AACxD,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AAU1C,SAAS,iCAAiC,YAAwB;AAChE,QAAM,aAAS,sDAA0B;AAAA,IACvC,sBAAsB,MAAMC,4BAAiC,UAAU,EAAE;AAAA,IACzE,oBAAoB,CAAC,UACnBC,iCAAsC,UAAU,EAAE,KAAK;AAAA,IACzD,qBAAqB;AAAA,EACvB,CAAC;AAMD,WAAS,gBAAgB,OAAwC;AAC/D,WAAO,OAAO,GAAG,SAAS;AAAA,EAC5B;AAEA,SAAO;AACT;AAEO,IAAMC,2BAGK,2DAAiBA,wBAA6B;AACzD,IAAMF,8BAGK,2DAAiB,gCAAgC;AAE5D,IAAMG,qCAGkC;AAAA,EAC7C;AACF;AAEO,IAAMC,qCAGkC;AAAA,EAC7C;AACF;AAEO,IAAMC,qCAGkC;AAAA,EAC7C;AACF;","names":["getSubscriptionContract","onSubscriptionContractCreated","onSubscriptionContractDeleted","onSubscriptionContractUpdated","querySubscriptionContracts","import_rename_all_nested_keys","import_address","import_float","import_image","import_timestamp","import_transform_paths","import_rest_modules","payload","import_transform_paths","SubscriptionFrequency","DescriptionLineType","ItemTypePreset","PaymentOptionType","JurisdictionType","V2SubscriptionFrequency","AdjustmentType","TaxableAddressType","WeightUnit","ChargeType","VatType","PickupMethod","DiscountType","DiscountReason","ChannelType","AdditionalFeeSource","SortOrder","WebhookIdentityType","getSubscriptionContract","sdkTransformError","querySubscriptionContracts","getSubscriptionContract","querySubscriptionContracts","typedQuerySubscriptionContracts","import_rest_modules","querySubscriptionContracts","typedQuerySubscriptionContracts","getSubscriptionContract","onSubscriptionContractCreated","onSubscriptionContractDeleted","onSubscriptionContractUpdated"]}
|
|
1
|
+
{"version":3,"sources":["../../index.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.ts","../../src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.ts"],"sourcesContent":["export * from './src/ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.context.js';\n","import { renameKeysFromRESTResponseToSDKResponse } from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { transformRESTAddressToSDKAddress } from '@wix/sdk-runtime/transformations/address';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTImageToSDKImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { EventDefinition, HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n QuerySubscriptionContractsResponse,\n SubscriptionContract,\n SubscriptionContractCreatedEnvelope,\n SubscriptionContractDeletedEnvelope,\n SubscriptionContractQuery,\n SubscriptionContractUpdatedEnvelope,\n SubscriptionContractsQueryBuilder,\n getSubscriptionContract as universalGetSubscriptionContract,\n querySubscriptionContracts as universalQuerySubscriptionContracts,\n typedQuerySubscriptionContracts as universalTypedQuerySubscriptionContracts,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/ecom' };\n\nexport function getSubscriptionContract(\n httpClient: HttpClient\n): GetSubscriptionContractSignature {\n return (subscriptionContractId: string) =>\n universalGetSubscriptionContract(\n subscriptionContractId,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetSubscriptionContractSignature {\n /**\n * Retrieves a SubscriptionContract.\n * @param - ID of the SubscriptionContract to retrieve.\n * @returns The requested SubscriptionContract.\n */\n (subscriptionContractId: string): Promise<\n NonNullablePaths<\n SubscriptionContract,\n | `subscriptionSettings.frequency`\n | `subscriptionSettings.autoRenewal`\n | `subscriptionSettings.enableCustomerCancellation`\n | `subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionSettings.freeTrialPeriod.interval`\n | `lineItems`\n | `lineItems.${number}._id`\n | `lineItems.${number}.productName.original`\n | `lineItems.${number}.catalogReference.catalogItemId`\n | `lineItems.${number}.catalogReference.appId`\n | `lineItems.${number}.quantity`\n | `lineItems.${number}.totalDiscount.amount`\n | `lineItems.${number}.totalDiscount.formattedAmount`\n | `lineItems.${number}.physicalProperties.shippable`\n | `lineItems.${number}.itemType.preset`\n | `lineItems.${number}.itemType.custom`\n | `lineItems.${number}.paymentOption`\n | `lineItems.${number}.taxDetails.taxRate`\n | `lineItems.${number}.taxInfo.taxIncludedInPrice`\n | `lineItems.${number}.digitalFile.fileId`\n | `lineItems.${number}.subscriptionInfo.cycleNumber`\n | `lineItems.${number}.subscriptionInfo.subscriptionOptionTitle`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.frequency`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.autoRenewal`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.enableCustomerCancellation`\n | `lineItems.${number}.priceDescription.original`\n | `lineItems.${number}.taxableAddress.addressType`\n | `lineItems.${number}.priceUndetermined`\n | `buyerInfo.visitorId`\n | `buyerInfo.memberId`\n | `weightUnit`\n | `taxIncludedInPrices`\n | `billingInfo.address.streetAddress.number`\n | `billingInfo.address.streetAddress.name`\n | `billingInfo.contactDetails.vatId._id`\n | `billingInfo.contactDetails.vatId.type`\n | `shippingInfo.title`\n | `shippingInfo.logistics.pickupDetails.pickupMethod`\n | `appliedDiscounts`\n | `appliedDiscounts.${number}.coupon._id`\n | `appliedDiscounts.${number}.coupon.code`\n | `appliedDiscounts.${number}.coupon.name`\n | `appliedDiscounts.${number}.merchantDiscount.discountReason`\n | `appliedDiscounts.${number}.discountRule._id`\n | `appliedDiscounts.${number}.discountRule.name.original`\n | `appliedDiscounts.${number}.discountType`\n | `channelInfo.type`\n | `customFields`\n | `customFields.${number}.title`\n | `additionalFees`\n | `additionalFees.${number}.name`\n | `additionalFees.${number}._id`,\n 6\n >\n >;\n}\n\nexport function querySubscriptionContracts(\n httpClient: HttpClient\n): QuerySubscriptionContractsSignature {\n return () =>\n universalQuerySubscriptionContracts(\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface QuerySubscriptionContractsSignature {\n /**\n * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].\n *\n * Up to 300 SubscriptionContracts can be returned per request.\n *\n * To learn how to query SubscriptionContracts, see [API Query Language][2].\n *\n * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging\n * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language\n */\n (): SubscriptionContractsQueryBuilder;\n}\n\nexport function typedQuerySubscriptionContracts(\n httpClient: HttpClient\n): TypedQuerySubscriptionContractsSignature {\n return (query: SubscriptionContractQuery) =>\n universalTypedQuerySubscriptionContracts(\n query,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface TypedQuerySubscriptionContractsSignature {\n /** */\n (query: SubscriptionContractQuery): Promise<\n NonNullablePaths<\n QuerySubscriptionContractsResponse,\n | `subscriptionContracts`\n | `subscriptionContracts.${number}.subscriptionSettings.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.autoRenewal`\n | `subscriptionContracts.${number}.subscriptionSettings.enableCustomerCancellation`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.interval`\n | `subscriptionContracts.${number}.buyerInfo.visitorId`\n | `subscriptionContracts.${number}.buyerInfo.memberId`\n | `subscriptionContracts.${number}.weightUnit`\n | `subscriptionContracts.${number}.taxIncludedInPrices`\n | `subscriptionContracts.${number}.shippingInfo.title`\n | `subscriptionContracts.${number}.channelInfo.type`,\n 6\n >\n >;\n}\n\nexport const onSubscriptionContractCreated = EventDefinition(\n 'wix.ecom.subscription_contracts.v1.subscription_contract_created',\n true,\n (event: SubscriptionContractCreatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'entity.subscriptionSettings.startDate' },\n { path: 'entity.lineItems.digitalFile.expirationDate' },\n {\n path: 'entity.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'entity.shippingInfo.logistics.deliverByDate' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.from' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.to' },\n { path: 'metadata.eventTime' },\n ],\n },\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'entity.lineItems.image' }],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [{ path: 'entity.lineItems.physicalProperties.weight' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'entity.billingInfo.address' },\n {\n path: 'entity.shippingInfo.logistics.shippingDestination.address',\n },\n { path: 'entity.shippingInfo.logistics.pickupDetails.address' },\n { path: 'entity.recipientInfo.address' },\n ],\n },\n ])\n )\n)<SubscriptionContractCreatedEnvelope>();\nexport const onSubscriptionContractDeleted = EventDefinition(\n 'wix.ecom.subscription_contracts.v1.subscription_contract_deleted',\n true,\n (event: SubscriptionContractDeletedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'undefined.createdDate' },\n { path: 'undefined.updatedDate' },\n { path: 'undefined.subscriptionSettings.startDate' },\n { path: 'undefined.lineItems.digitalFile.expirationDate' },\n {\n path: 'undefined.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'undefined.shippingInfo.logistics.deliverByDate' },\n { path: 'undefined.shippingInfo.logistics.deliveryTimeSlot.from' },\n { path: 'undefined.shippingInfo.logistics.deliveryTimeSlot.to' },\n { path: 'metadata.eventTime' },\n ],\n },\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'undefined.lineItems.image' }],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [{ path: 'undefined.lineItems.physicalProperties.weight' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'undefined.billingInfo.address' },\n {\n path: 'undefined.shippingInfo.logistics.shippingDestination.address',\n },\n { path: 'undefined.shippingInfo.logistics.pickupDetails.address' },\n { path: 'undefined.recipientInfo.address' },\n ],\n },\n ])\n )\n)<SubscriptionContractDeletedEnvelope>();\nexport const onSubscriptionContractUpdated = EventDefinition(\n 'wix.ecom.subscription_contracts.v1.subscription_contract_updated',\n true,\n (event: SubscriptionContractUpdatedEnvelope) =>\n renameKeysFromRESTResponseToSDKResponse(\n transformPaths(event, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'entity.createdDate' },\n { path: 'entity.updatedDate' },\n { path: 'entity.subscriptionSettings.startDate' },\n { path: 'entity.lineItems.digitalFile.expirationDate' },\n {\n path: 'entity.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'entity.shippingInfo.logistics.deliverByDate' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.from' },\n { path: 'entity.shippingInfo.logistics.deliveryTimeSlot.to' },\n { path: 'metadata.eventTime' },\n { path: 'modifiedFields.createdDate' },\n { path: 'modifiedFields.updatedDate' },\n { path: 'modifiedFields.subscriptionSettings.startDate' },\n { path: 'modifiedFields.lineItems.digitalFile.expirationDate' },\n {\n path: 'modifiedFields.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n { path: 'modifiedFields.shippingInfo.logistics.deliverByDate' },\n {\n path: 'modifiedFields.shippingInfo.logistics.deliveryTimeSlot.from',\n },\n {\n path: 'modifiedFields.shippingInfo.logistics.deliveryTimeSlot.to',\n },\n ],\n },\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [\n { path: 'entity.lineItems.image' },\n { path: 'modifiedFields.lineItems.image' },\n ],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n { path: 'entity.lineItems.physicalProperties.weight' },\n { path: 'modifiedFields.lineItems.physicalProperties.weight' },\n ],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'entity.billingInfo.address' },\n {\n path: 'entity.shippingInfo.logistics.shippingDestination.address',\n },\n { path: 'entity.shippingInfo.logistics.pickupDetails.address' },\n { path: 'entity.recipientInfo.address' },\n { path: 'modifiedFields.billingInfo.address' },\n {\n path: 'modifiedFields.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'modifiedFields.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'modifiedFields.recipientInfo.address' },\n ],\n },\n ])\n )\n)<SubscriptionContractUpdatedEnvelope>();\n\nexport {\n AccountInfo,\n ActionEvent,\n AdditionalFee,\n AdditionalFeeSource,\n Address,\n AddressLocation,\n AddressWithContact,\n AdjustmentType,\n ApplicationError,\n AppliedDiscount,\n AppliedDiscountDiscountSourceOneOf,\n BaseEventMetadata,\n BillingAdjustment,\n BillingAdjustmentPriceSummary,\n BulkActionMetadata,\n BulkCreateSubscriptionContractsRequest,\n BulkCreateSubscriptionContractsResponse,\n BulkSubscriptionContractResult,\n BulkUpdateSubscriptionContractsRequest,\n BulkUpdateSubscriptionContractsResponse,\n BuyerInfo,\n BuyerInfoIdOneOf,\n CatalogReference,\n ChannelInfo,\n ChannelType,\n ChargeType,\n Color,\n Coupon,\n CreateSubscriptionContractRequest,\n CreateSubscriptionContractResponse,\n CurrencyConversionDetails,\n CursorPaging,\n CursorPagingMetadata,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Cursors,\n CustomField,\n DeliveryLogistics,\n DeliveryLogisticsAddressOneOf,\n DeliveryTimeSlot,\n DescriptionLine,\n DescriptionLineDescriptionLineValueOneOf,\n DescriptionLineName,\n DescriptionLineType,\n DescriptionLineValueOneOf,\n DigitalFile,\n DiscountReason,\n DiscountRule,\n DiscountRuleName,\n DiscountType,\n DomainEvent,\n DomainEventBodyOneOf,\n Empty,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n EventMetadata,\n ExtendedFields,\n FocalPoint,\n FreeTrialPeriod,\n FullAddressContactDetails,\n GetSubscriptionContractRequest,\n GetSubscriptionContractResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemCombination,\n ItemCombinationLineItem,\n ItemMetadata,\n ItemModifier,\n ItemTaxFullDetails,\n ItemType,\n ItemTypeItemTypeDataOneOf,\n ItemTypePreset,\n JurisdictionType,\n LineItemDiscount,\n LineItemTaxBreakdown,\n LineItemTaxInfo,\n Location,\n LocationAndQuantity,\n MaskedSubscriptionContract,\n MerchantDiscount,\n MerchantDiscountMerchantDiscountReasonOneOf,\n MessageEnvelope,\n ModifierGroup,\n OrderLineItem,\n OrderTaxBreakdown,\n OrderTaxInfo,\n PaymentOptionType,\n PhysicalProperties,\n PickupAddress,\n PickupDetails,\n PickupMethod,\n PlainTextValue,\n PlatformFee,\n PlatformFeeSummary,\n Price,\n PriceDescription,\n PriceSummary,\n ProductName,\n QuerySubscriptionContractsRequest,\n QuerySubscriptionContractsResponse,\n RestoreInfo,\n ShippingInformation,\n ShippingPrice,\n ShippingRegion,\n SortOrder,\n Sorting,\n StreetAddress,\n SubscriptionContract,\n SubscriptionContractCreatedEnvelope,\n SubscriptionContractDeletedEnvelope,\n SubscriptionContractQuerySpec,\n SubscriptionContractUpdatedEnvelope,\n SubscriptionContractsQueryBuilder,\n SubscriptionContractsQueryResult,\n SubscriptionDescription,\n SubscriptionFrequency,\n SubscriptionInfo,\n SubscriptionSettings,\n SubscriptionTitle,\n TaxableAddress,\n TaxableAddressTaxableAddressDataOneOf,\n TaxableAddressType,\n TranslatableString,\n UpdateSubscriptionContractRequest,\n UpdateSubscriptionContractResponse,\n V1FreeTrialPeriod,\n V1SubscriptionDescription,\n V1SubscriptionSettings,\n V1SubscriptionTitle,\n V2SubscriptionFrequency,\n VatId,\n VatType,\n WebhookIdentityType,\n WeightUnit,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport { queryBuilder } from '@wix/sdk-runtime/query-builder';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport {\n HttpClient,\n HttpResponse,\n NonNullablePaths,\n QuerySpec,\n Query as QuerySdkType,\n} from '@wix/sdk-types';\nimport * as ambassadorWixEcomSubscriptionContractsV1SubscriptionContract from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.http.js';\n// @ts-ignore\nimport { transformRESTAddressToSDKAddress } from '@wix/sdk-runtime/transformations/address';\nimport { transformRESTImageToSDKImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\n\n/**\n * A SubscriptionContract is a ...\n * You can ...\n * Read more about SubscriptionContracts\n * in this [article](<LINK_TO_KB_ARTICLE>).\n */\nexport interface SubscriptionContract {\n /**\n * SubscriptionContract ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * Revision number, which increments by 1 each time the SubscriptionContract is updated.\n * To prevent conflicting changes, the current revision must be passed when updating the SubscriptionContract.\n *\n * Ignored when creating a SubscriptionOrderContract.\n * @readonly\n */\n revision?: string | null;\n /**\n * Date and time the subscription contract was created in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * 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.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @maxLength 500\n * @deprecated Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @replacedBy subscription_description\n * @targetRemovalDate 2025-10-01\n */\n description?: string | null;\n /**\n * Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @internal\n */\n subscriptionDescription?: V1SubscriptionDescription;\n /**\n * Subscription detailed information.\n * @immutable\n */\n subscriptionSettings?: V1SubscriptionSettings;\n /**\n * Order line items.\n * @minSize 1\n * @maxSize 1\n */\n lineItems?: OrderLineItem[];\n /** Buyer information. */\n buyerInfo?: BuyerInfo;\n /**\n * Language for communication with the buyer. Defaults to the site language.\n * For a site that supports multiple languages, this is the language the buyer selected.\n */\n buyerLanguage?: string | null;\n /** Weight measurement unit - defaults to site's weight unit. */\n weightUnit?: WeightUnitWithLiterals;\n /**\n * 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.\n * @format CURRENCY\n * @immutable\n */\n currency?: string | null;\n /** Multi-currency information of the subscription. conversionRate may reflect updated exchange rate on created order per recurring cycle. */\n currencyConversionDetails?: CurrencyConversionDetails;\n /**\n * Whether tax is included in line item prices.\n *\n * Default: `false`\n * @immutable\n */\n taxIncludedInPrices?: boolean;\n /**\n * Order price summary.\n * @readonly\n */\n priceSummary?: PriceSummary;\n /**\n * Summary of all platform fees added to the order.\n * @internal\n */\n platformFeeSummary?: PlatformFeeSummary;\n /** Billing address and contact details. */\n billingInfo?: AddressWithContact;\n /** Shipping info and selected shipping option details. */\n shippingInfo?: ShippingInformation;\n /** Applied discounts. */\n appliedDiscounts?: AppliedDiscount[];\n /** Information about the sales channel that submitted this order. */\n channelInfo?: ChannelInfo;\n /** Custom fields. */\n customFields?: CustomField[];\n /**\n * Order recipient address and contact details.\n *\n * This field may differ from the address in `shippingInfo.logistics` when:\n * + The chosen shipping option is pickup point or store pickup.\n * + No shipping option is selected.\n */\n recipientInfo?: AddressWithContact;\n /**\n * Custom field data for the subscription contract object.\n *\n * [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.\n */\n extendedFields?: ExtendedFields;\n /**\n * Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @maxLength 150\n * @deprecated Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @replacedBy subscription_title\n * @targetRemovalDate 2025-10-01\n */\n title?: string | null;\n /**\n * Subscription title. For example, `\"Monthly coffee Subscription\"`.\n * @internal\n */\n subscriptionTitle?: V1SubscriptionTitle;\n /**\n * Additional fees applied to subscription contract.\n * @maxSize 100\n */\n additionalFees?: AdditionalFee[];\n}\n\nexport interface V1SubscriptionDescription {\n /**\n * Subscription option description.\n * @maxLength 500\n */\n original?: string;\n /**\n * Translated subscription option description.\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface V1SubscriptionSettings {\n /** Frequency of recurring payment. */\n frequency?: SubscriptionFrequencyWithLiterals;\n /**\n * Interval of recurring payment.\n * @min 1\n * @max 3650\n */\n interval?: number | null;\n /** Whether subscription is renewed automatically at the end of each period. */\n autoRenewal?: boolean;\n /**\n * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`.\n * @min 1\n */\n billingCycles?: number | null;\n /** Whether to allow the customer to cancel the subscription. */\n enableCustomerCancellation?: boolean;\n /** Period until first cycle starts. If None => no free trial */\n freeTrialPeriod?: V1FreeTrialPeriod;\n /**\n * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.\n * @internal\n */\n startDate?: Date | null;\n}\n\nexport enum SubscriptionFrequency {\n UNDEFINED = 'UNDEFINED',\n DAY = 'DAY',\n WEEK = 'WEEK',\n MONTH = 'MONTH',\n YEAR = 'YEAR',\n}\n\n/** @enumType */\nexport type SubscriptionFrequencyWithLiterals =\n | SubscriptionFrequency\n | 'UNDEFINED'\n | 'DAY'\n | 'WEEK'\n | 'MONTH'\n | 'YEAR';\n\nexport interface V1FreeTrialPeriod {\n /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */\n frequency?: SubscriptionFrequencyWithLiterals;\n /**\n * interval of period\n * @min 1\n * @max 3650\n */\n interval?: number;\n}\n\nexport interface OrderLineItem {\n /**\n * Line item ID.\n * @immutable\n */\n _id?: string;\n /**\n * Item name.\n * + Stores - `product.name`\n * + Bookings - `service.info.name`\n * + Events - `ticket.name`\n */\n productName?: ProductName;\n /**\n * References to the line item's origin catalog.\n * This field may be empty in the case of a custom line item.\n */\n catalogReference?: CatalogReference;\n /**\n * Line item quantity.\n * @min 1\n * @max 100000\n */\n quantity?: number;\n /**\n * Total discount for this line item's entire quantity.\n * @readonly\n */\n totalDiscount?: Price;\n /**\n * Line item description lines. Used for display purposes for the cart, checkout and order.\n * @maxSize 20\n */\n descriptionLines?: DescriptionLine[];\n /** Line item image. */\n image?: string;\n /** Physical properties of the item. When relevant, contains information such as SKU and item weight. */\n physicalProperties?: PhysicalProperties;\n /** Item type. Either a preset type or custom. */\n itemType?: ItemType;\n /**\n * Fulfiller ID. Field is empty when the line item is self-fulfilled.\n * 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).\n * @format GUID\n */\n fulfillerId?: string | null;\n /**\n * Number of items that were refunded.\n * @max 100000\n */\n refundQuantity?: number | null;\n /**\n * Number of items restocked.\n * @max 100000\n */\n restockQuantity?: number | null;\n /** Line item price after line item discounts for display purposes. */\n price?: Price;\n /**\n * Line item price before line item discounts for display purposes. Defaults to `price` when not provided.\n * @readonly\n */\n priceBeforeDiscounts?: Price;\n /**\n * Total price after discounts, and before tax.\n * @readonly\n */\n totalPriceBeforeTax?: Price;\n /**\n * Total price after all discounts and tax.\n * @readonly\n */\n totalPriceAfterTax?: Price;\n /**\n * Type of selected payment option for current item.\n *\n * Default: `FULL_PAYMENT_ONLINE`\n */\n paymentOption?: PaymentOptionTypeWithLiterals;\n /**\n * Deprecated. Use `taxInfo` instead.\n * This field will be removed on September 30, 2024.\n * Tax details for this line item.\n * @deprecated Deprecated. Use `taxInfo` instead.\n * This field will be removed on September 30, 2024.\n * Tax details for this line item.\n * @replacedBy tax_info\n * @targetRemovalDate 2024-09-30\n */\n taxDetails?: ItemTaxFullDetails;\n /** Represents all the relevant tax details for a specific line item. */\n taxInfo?: LineItemTaxInfo;\n /** Digital file identifier, relevant only for items with type DIGITAL. */\n digitalFile?: DigitalFile;\n /** Subscription info. */\n subscriptionInfo?: SubscriptionInfo;\n /** Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - \"Starts at $67\". */\n priceDescription?: PriceDescription;\n /**\n * Item's price amount to be charged during checkout. Relevant for items with a `paymentOption` value of `\"DEPOSIT_ONLINE\"`.\n * @readonly\n */\n depositAmount?: Price;\n /**\n * Line item locations.\n *\n * The location's total quantity must not exceed the line item quantity.\n * @maxSize 5\n */\n locations?: LocationAndQuantity[];\n /** Total price **after** catalog discounts and line item discounts. */\n lineItemPrice?: Price;\n /** Address used for tax calculation. */\n taxableAddress?: TaxableAddress;\n /**\n * ID of the app managing the inventory.\n * @internal\n * @format GUID\n */\n inventoryAppId?: string | null;\n /**\n * Whether the price is not yet defined, and will be updated after the order is created.\n *\n * Default: `false`\n */\n priceUndetermined?: boolean;\n /**\n * Custom extended fields for the line item object.\n *\n * [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.\n */\n extendedFields?: ExtendedFields;\n /**\n * Modifier groups that were added to the item.\n * @readonly\n * @maxSize 10\n */\n modifierGroups?: ModifierGroup[];\n /**\n * Line item ID in external systems.\n * @internal\n * @minLength 1\n * @maxLength 64\n * @immutable\n */\n externalLineItemId?: string | null;\n}\n\nexport interface ProductName {\n /**\n * __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).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * Item name translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in key:value pairs. Use this optional field to provide more specificity with item selection. The `options` field values differ depending on which catalog is providing the items.\n *\n * For products and variants from a Wix Stores catalog, learn more about [eCommerce integration](https://dev.wix.com/docs/rest/business-solutions/stores/catalog/e-commerce-integration).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface Price {\n /**\n * Amount.\n * @decimalValue options { gte:0, lte:1000000000000000 }\n */\n amount?: string;\n /**\n * Amount formatted with currency symbol.\n * @readonly\n */\n formattedAmount?: string;\n}\n\nexport interface DescriptionLine\n extends DescriptionLineValueOneOf,\n DescriptionLineDescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n /** Description line name. */\n name?: DescriptionLineName;\n /**\n * Whether the description line originates from a modifier.\n * @internal\n * @deprecated Whether the description line originates from a modifier.\n * @replacedBy none\n * @targetRemovalDate 2025-12-31\n */\n modifierDescriptionLine?: boolean;\n}\n\n/** @oneof */\nexport interface DescriptionLineValueOneOf {\n /** Description line plain text value. */\n plainText?: PlainTextValue;\n /** Description line color value. */\n colorInfo?: Color;\n}\n\n/** @oneof */\nexport interface DescriptionLineDescriptionLineValueOneOf {}\n\nexport interface DescriptionLineName {\n /**\n * 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).\n * @maxLength 100\n */\n original?: string;\n /**\n * Description line name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 200\n */\n translated?: string | null;\n}\n\nexport interface PlainTextValue {\n /**\n * 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).\n * @maxLength 600\n */\n original?: string;\n /**\n * Description line plain text value translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 600\n */\n translated?: string | null;\n}\n\nexport interface Color {\n /**\n * 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).\n * @maxLength 500\n */\n original?: string;\n /**\n * Description line color name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @maxLength 500\n */\n translated?: string | null;\n /** HEX or RGB color code for display. */\n code?: string | null;\n}\n\nexport enum DescriptionLineType {\n /** Unrecognized type. */\n UNRECOGNISED = 'UNRECOGNISED',\n /** Plain text type. */\n PLAIN_TEXT = 'PLAIN_TEXT',\n /** Color type. */\n COLOR = 'COLOR',\n}\n\n/** @enumType */\nexport type DescriptionLineTypeWithLiterals =\n | DescriptionLineType\n | 'UNRECOGNISED'\n | 'PLAIN_TEXT'\n | 'COLOR';\n\nexport interface FocalPoint {\n /** X-coordinate of the focal point. */\n x?: number;\n /** Y-coordinate of the focal point. */\n y?: number;\n /** crop by height */\n height?: number | null;\n /** crop by width */\n width?: number | null;\n}\n\nexport interface PhysicalProperties {\n /** Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. */\n weight?: number | null;\n /**\n * Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku).\n * @maxLength 40\n */\n sku?: string | null;\n /** Whether this line item is shippable. */\n shippable?: boolean;\n}\n\nexport interface ItemType extends ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePresetWithLiterals;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\n/** @oneof */\nexport interface ItemTypeItemTypeDataOneOf {\n /** Preset item type. */\n preset?: ItemTypePresetWithLiterals;\n /** Custom item type. When none of the preset types are suitable, specifies the custom type. */\n custom?: string;\n}\n\nexport enum ItemTypePreset {\n UNRECOGNISED = 'UNRECOGNISED',\n PHYSICAL = 'PHYSICAL',\n DIGITAL = 'DIGITAL',\n GIFT_CARD = 'GIFT_CARD',\n SERVICE = 'SERVICE',\n}\n\n/** @enumType */\nexport type ItemTypePresetWithLiterals =\n | ItemTypePreset\n | 'UNRECOGNISED'\n | 'PHYSICAL'\n | 'DIGITAL'\n | 'GIFT_CARD'\n | 'SERVICE';\n\n/** Type of selected payment option for catalog item */\nexport enum PaymentOptionType {\n /** The entire payment for this item happens as part of the checkout. */\n FULL_PAYMENT_ONLINE = 'FULL_PAYMENT_ONLINE',\n /** The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. */\n FULL_PAYMENT_OFFLINE = 'FULL_PAYMENT_OFFLINE',\n /** 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. */\n MEMBERSHIP = 'MEMBERSHIP',\n /** Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. */\n DEPOSIT_ONLINE = 'DEPOSIT_ONLINE',\n /** 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`. */\n MEMBERSHIP_OFFLINE = 'MEMBERSHIP_OFFLINE',\n /**\n * Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline.\n * @documentationMaturity preview\n */\n MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER = 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER',\n}\n\n/** @enumType */\nexport type PaymentOptionTypeWithLiterals =\n | PaymentOptionType\n | 'FULL_PAYMENT_ONLINE'\n | 'FULL_PAYMENT_OFFLINE'\n | 'MEMBERSHIP'\n | 'DEPOSIT_ONLINE'\n | 'MEMBERSHIP_OFFLINE'\n | 'MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER';\n\nexport interface ItemTaxFullDetails {\n /** Taxable amount of this line item. */\n taxableAmount?: Price;\n /**\n * Tax rate percentage, as a decimal numeral between 0 and 1. For example, `\"0.13\"`.\n * @decimalValue options { gte:0, maxScale:6 }\n */\n taxRate?: string;\n /** The calculated tax, based on the `taxableAmount` and `taxRate`. */\n totalTax?: Price;\n /**\n * Amount that was exempt from tax calculations.\n * @internal\n */\n exemptAmount?: Price;\n}\n\nexport interface LineItemTaxInfo {\n /** Calculated tax, based on `taxable_amount` and `tax_rate`. */\n taxAmount?: Price;\n /** Amount for which tax is calculated. */\n taxableAmount?: Price;\n /**\n * Tax rate %, as a decimal point.\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, maxScale:6 }\n */\n taxRate?: string | null;\n /**\n * Tax group ID.\n * @format GUID\n */\n taxGroupId?: string | null;\n /** Indicates whether the price already includes tax. */\n taxIncludedInPrice?: boolean;\n /**\n * Tax information for a line item.\n * @maxSize 7\n */\n taxBreakdown?: LineItemTaxBreakdown[];\n /**\n * Amount of the line item price that was exempt from tax.\n * @internal\n */\n exemptAmount?: Price;\n}\n\n/**\n * TaxBreakdown represents tax information for a line item.\n * It holds the tax amount and the tax rate for each tax authority that apply on the line item.\n */\nexport interface LineItemTaxBreakdown {\n /**\n * Jurisdiction that taxes were calculated for. For example, \"New York\", or \"Quebec\".\n * @maxLength 200\n */\n jurisdiction?: string | null;\n /**\n * Tax rate used for this jurisdiction, as a decimal. For example, 10% tax is 0.1000.\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, maxScale:6 }\n */\n rate?: string | null;\n /** Amount of tax calculated for this line item. */\n taxAmount?: Price;\n /**\n * The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, \"Sales Tax\", \"Income Tax\", \"Value Added Tax\", etc.\n * @maxLength 200\n */\n taxType?: string | null;\n /**\n * The name of the tax against which this tax amount was calculated. For example, \"NY State Sales Tax\", \"Quebec GST\", etc.\n * This name should be explicit enough to allow the merchant to understand what tax was calculated.\n * @maxLength 200\n */\n taxName?: string | null;\n /** Type of jurisdiction that taxes were calculated for. */\n jurisdictionType?: JurisdictionTypeWithLiterals;\n /** Non-taxable amount of the line item price. */\n nonTaxableAmount?: Price;\n /** Taxable amount of the line item price. */\n taxableAmount?: Price;\n /**\n * Amount of the line item price that was exempt from this authority.\n * @internal\n */\n exemptAmount?: Price;\n}\n\n/** JurisdictionType represents the type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */\nexport enum JurisdictionType {\n UNDEFINED = 'UNDEFINED',\n COUNTRY = 'COUNTRY',\n STATE = 'STATE',\n COUNTY = 'COUNTY',\n CITY = 'CITY',\n SPECIAL = 'SPECIAL',\n}\n\n/** @enumType */\nexport type JurisdictionTypeWithLiterals =\n | JurisdictionType\n | 'UNDEFINED'\n | 'COUNTRY'\n | 'STATE'\n | 'COUNTY'\n | 'CITY'\n | 'SPECIAL';\n\nexport interface DigitalFile {\n /**\n * ID of the secure file in media.\n * @minLength 1\n * @maxLength 100\n */\n fileId?: string;\n /**\n * Link will exist after the digital links have been generated on the order.\n * @format WEB_URL\n * @minLength 1\n * @maxLength 2000\n */\n link?: string | null;\n /**\n * Link expiration time and date.\n * @readonly\n */\n expirationDate?: Date | null;\n}\n\nexport interface SubscriptionInfo {\n /**\n * Subscription ID.\n * @format GUID\n */\n _id?: string | null;\n /** Subscription cycle. For example, if this order is for the 3rd cycle of a subscription, value will be `3`. */\n cycleNumber?: number;\n /**\n * Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @maxLength 150\n * @deprecated Subscription option title. For example, `\"Monthly coffee Subscription\"`.\n * @replacedBy title\n * @targetRemovalDate 2025-10-01\n */\n subscriptionOptionTitle?: string;\n /**\n * Subscription title. For example, `\"Monthly coffee Subscription\"`.\n * @internal\n */\n title?: SubscriptionTitle;\n /**\n * Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @maxLength 500\n * @deprecated Subscription option description. For example, `\"1kg of selected coffee, once a month\"`.\n * @replacedBy description\n * @targetRemovalDate 2025-10-01\n */\n subscriptionOptionDescription?: string | null;\n /**\n * Subscription description. For example, `\"1kg of selected coffee, once a month\"`.\n * @internal\n */\n description?: SubscriptionDescription;\n /**\n * Subscription detailed information.\n * @immutable\n */\n subscriptionSettings?: SubscriptionSettings;\n /**\n * Description of the charges that will be applied for subscription.\n * @maxLength 1000\n */\n chargesDescription?: string | null;\n /**\n * Details of the billing adjustment applied to the current subscription cycle due to a shift in the subscription’s billing date.\n * @internal\n */\n billingAdjustment?: BillingAdjustment;\n}\n\nexport interface SubscriptionTitle {\n /**\n * 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).\n * @minLength 1\n * @maxLength 150\n */\n original?: string;\n /**\n * Subscription option name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 150\n */\n translated?: string | null;\n}\n\nexport interface SubscriptionDescription {\n /**\n * Subscription option description.\n * @maxLength 500\n */\n original?: string;\n /**\n * Translated subscription option description.\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface SubscriptionSettings {\n /** Frequency of recurring payment. */\n frequency?: V2SubscriptionFrequencyWithLiterals;\n /**\n * Interval of recurring payment.\n * @min 1\n * @max 3650\n */\n interval?: number | null;\n /** Whether subscription is renewed automatically at the end of each period. */\n autoRenewal?: boolean;\n /**\n * Number of billing cycles before subscription ends. Ignored if `autoRenewal: true`.\n * @min 1\n */\n billingCycles?: number | null;\n /** Whether to allow the customer to cancel the subscription. */\n enableCustomerCancellation?: boolean;\n /** Period until first cycle starts. If None => no free trial */\n freeTrialPeriod?: FreeTrialPeriod;\n /**\n * The date the subscription will start. The subscription will be charged either now or according to freeTrialDays.\n * @internal\n */\n startDate?: Date | null;\n}\n\n/** Frequency unit of recurring payment */\nexport enum V2SubscriptionFrequency {\n UNDEFINED = 'UNDEFINED',\n DAY = 'DAY',\n WEEK = 'WEEK',\n MONTH = 'MONTH',\n YEAR = 'YEAR',\n}\n\n/** @enumType */\nexport type V2SubscriptionFrequencyWithLiterals =\n | V2SubscriptionFrequency\n | 'UNDEFINED'\n | 'DAY'\n | 'WEEK'\n | 'MONTH'\n | 'YEAR';\n\nexport interface FreeTrialPeriod {\n /** Frequency of period. Values: DAY, WEEK, MONTH, YEAR */\n frequency?: V2SubscriptionFrequencyWithLiterals;\n /**\n * interval of period\n * @min 1\n * @max 3650\n */\n interval?: number;\n}\n\nexport interface BillingAdjustment {\n /** The type of adjustment. */\n type?: AdjustmentTypeWithLiterals;\n /** Summary of the prorated adjustment amount. */\n priceSummary?: BillingAdjustmentPriceSummary;\n}\n\nexport enum AdjustmentType {\n UNKNOWN_ADJUSTMENT_TYPE = 'UNKNOWN_ADJUSTMENT_TYPE',\n /** Adjustment increases the total amount due to changes like covering extra billing days. Typically results in an additional fee. */\n EXTRA_CHARGE = 'EXTRA_CHARGE',\n /** Adjustment reduces the total amount due to changes like covering fewer billing days. Typically results in a credit or discount. */\n CREDIT = 'CREDIT',\n}\n\n/** @enumType */\nexport type AdjustmentTypeWithLiterals =\n | AdjustmentType\n | 'UNKNOWN_ADJUSTMENT_TYPE'\n | 'EXTRA_CHARGE'\n | 'CREDIT';\n\nexport interface BillingAdjustmentPriceSummary {\n /** Subtotal of adjustment, before tax. */\n subtotal?: Price;\n /** Tax on adjustment. */\n tax?: Price;\n /** Total price after tax. */\n total?: Price;\n}\n\nexport interface PriceDescription {\n /**\n * __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).\n * @minLength 1\n * @maxLength 100\n */\n original?: string;\n /**\n * Price description translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 100\n */\n translated?: string | null;\n}\n\nexport interface LocationAndQuantity {\n /**\n * Location id in the associated owner app.\n * @format GUID\n */\n _id?: string;\n /**\n * Location owner app, if not provided then the site business info locations will be used.\n * @format GUID\n * @deprecated Location owner app, if not provided then the site business info locations will be used.\n * @targetRemovalDate 2025-03-01\n */\n appId?: string | null;\n /**\n * Quantity for specific location.\n * @min 1\n * @max 100000\n */\n quantity?: number;\n /**\n * Location name.\n * @maxLength 500\n * @readonly\n */\n name?: string | null;\n}\n\nexport interface TaxableAddress extends TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface TaxableAddressTaxableAddressDataOneOf {\n /** taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. */\n addressType?: TaxableAddressTypeWithLiterals;\n}\n\nexport enum TaxableAddressType {\n UNKNOWN_TAXABLE_ADDRESS = 'UNKNOWN_TAXABLE_ADDRESS',\n BUSINESS = 'BUSINESS',\n BILLING = 'BILLING',\n SHIPPING = 'SHIPPING',\n}\n\n/** @enumType */\nexport type TaxableAddressTypeWithLiterals =\n | TaxableAddressType\n | 'UNKNOWN_TAXABLE_ADDRESS'\n | 'BUSINESS'\n | 'BILLING'\n | 'SHIPPING';\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\nexport interface ModifierGroup {\n /**\n * Modifier group ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /** Modifier group name. */\n name?: TranslatableString;\n /**\n * List of modifiers in this group.\n * @minSize 1\n * @maxSize 10\n */\n modifiers?: ItemModifier[];\n}\n\nexport interface TranslatableString {\n /**\n * __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).\n *\n * Min: 1 character.\n * Max: 200 characters.\n * @minLength 1\n * @maxLength 200\n */\n original?: string;\n /**\n * String translated into the buyer's language.\n *\n * Min: 1 character.\n * Max: 400 characters.\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 400\n */\n translated?: string | null;\n}\n\nexport interface ItemModifier {\n /**\n * Modifier ID.\n * @minLength 1\n * @maxLength 36\n */\n _id?: string;\n /**\n * The quantity of this modifier.\n * @min 1\n * @max 100000\n */\n quantity?: number | null;\n /** Primary display label for the modifier. */\n label?: TranslatableString;\n /** Additional details. */\n details?: TranslatableString;\n /** The price of the modifier. */\n price?: Price;\n}\n\n/** Buyer Info */\nexport interface BuyerInfo extends BuyerInfoIdOneOf {\n /**\n * Visitor ID (if site visitor is not a member).\n * @format GUID\n */\n visitorId?: string;\n /**\n * Member ID (if site visitor is a site member).\n * @format GUID\n */\n memberId?: string;\n /**\n * 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).\n * @format GUID\n */\n contactId?: string | null;\n /**\n * Buyer email address.\n * @format EMAIL\n */\n email?: string | null;\n}\n\n/** @oneof */\nexport interface BuyerInfoIdOneOf {\n /**\n * Visitor ID (if site visitor is not a member).\n * @format GUID\n */\n visitorId?: string;\n /**\n * Member ID (if site visitor is a site member).\n * @format GUID\n */\n memberId?: string;\n}\n\nexport enum WeightUnit {\n /** Weight unit can't be classified due to an error. */\n UNSPECIFIED_WEIGHT_UNIT = 'UNSPECIFIED_WEIGHT_UNIT',\n /** Kilograms. */\n KG = 'KG',\n /** Pounds. */\n LB = 'LB',\n}\n\n/** @enumType */\nexport type WeightUnitWithLiterals =\n | WeightUnit\n | 'UNSPECIFIED_WEIGHT_UNIT'\n | 'KG'\n | 'LB';\n\nexport interface CurrencyConversionDetails {\n /**\n * 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.\n *\n * This currency is used to calculate the pricing before conversion to the buyer's payment currency.\n * @readonly\n * @immutable\n * @format CURRENCY\n */\n originalCurrency?: string | null;\n /**\n * The rate used for converting the original currency to the currency used for payment.\n * @readonly\n * @immutable\n * @decimalValue options { gt:0, lte:1000000000000000 }\n */\n conversionRate?: string | null;\n}\n\nexport interface PriceSummary {\n /** Subtotal of all the line items, before discounts and before tax. */\n subtotal?: Price;\n /** Total shipping price, before discounts and before tax. */\n shipping?: Price;\n /** Total tax on this order. */\n tax?: Price;\n /** Total calculated discount value. */\n discount?: Price;\n /** Order’s total price after discounts and tax. */\n total?: Price;\n /** Total price of additional fees before tax. */\n totalAdditionalFees?: Price;\n}\n\nexport interface PlatformFeeSummary {\n /** Total sum of all platform fees. */\n total?: Price;\n /** Total amount of platform fees with `PASS_ON` charge type. */\n totalPassOn?: Price;\n /** Total amount of platform fees with `ABSORBED` charge type. */\n totalAbsorbed?: Price;\n /**\n * Specific information about each platform fee.\n * @maxSize 300\n */\n fees?: PlatformFee[];\n}\n\nexport interface PlatformFee {\n /** Platform fee name. */\n name?: TranslatableString;\n /** Platform fee amount. */\n amount?: Price;\n /**\n * ID of the line item the platform fee applies to.\n * @format GUID\n */\n lineItemId?: string;\n /** Platform fee charge type. */\n chargeType?: ChargeTypeWithLiterals;\n /**\n * Percentage rate charged as platform fee.\n * The fee rate percentage expressed as a decimal fraction between 0 and 1. For example, `0.05` for 5%.\n * @format DECIMAL_VALUE\n * @decimalValue options { gt:0, lte:1, maxScale:4 }\n */\n percentageRate?: string;\n}\n\nexport enum ChargeType {\n UNKNOWN_CHARGE_TYPE = 'UNKNOWN_CHARGE_TYPE',\n /**\n * Platform fee passed on to buyer.\n *\n * This type increases the order total, and is visible to the buyer and merchant as an additional fee.\n */\n PASS_ON = 'PASS_ON',\n /**\n * Platform fee absorbed by merchant.\n *\n * This type does not increase the order total, and is only visible to the merchant.\n */\n ABSORBED = 'ABSORBED',\n}\n\n/** @enumType */\nexport type ChargeTypeWithLiterals =\n | ChargeType\n | 'UNKNOWN_CHARGE_TYPE'\n | 'PASS_ON'\n | 'ABSORBED';\n\n/** Billing Info and shipping details */\nexport interface AddressWithContact {\n /** Address. */\n address?: Address;\n /** Contact details. */\n contactDetails?: FullAddressContactDetails;\n}\n\n/** Physical address */\nexport interface Address {\n /**\n * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.\n * @format COUNTRY\n */\n country?: string | null;\n /**\n * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.\n * @maxLength 50\n */\n subdivision?: string | null;\n /**\n * City name.\n * @maxLength 50\n */\n city?: string | null;\n /**\n * Postal or zip code.\n * @maxLength 50\n */\n postalCode?: string | null;\n /** Street address. */\n streetAddress?: StreetAddress;\n /**\n * Main address line (usually street name and number).\n * @maxLength 150\n */\n addressLine1?: string | null;\n /**\n * Free text providing more detailed address info. Usually contains apt, suite, floor.\n * @maxLength 100\n */\n addressLine2?: string | null;\n /** Geocode object containing latitude and longitude coordinates. */\n location?: AddressLocation;\n /**\n * Country's full name.\n * @readonly\n */\n countryFullname?: string | null;\n /**\n * Subdivision full-name.\n * @readonly\n */\n subdivisionFullname?: string | null;\n}\n\nexport interface StreetAddress {\n /** Street number. */\n number?: string;\n /** Street name. */\n name?: string;\n}\n\nexport interface AddressLocation {\n /** Address latitude. */\n latitude?: number | null;\n /** Address longitude. */\n longitude?: number | null;\n}\n\n/** Full contact details for an address */\nexport interface FullAddressContactDetails {\n /**\n * First name.\n * @maxLength 100\n */\n firstName?: string | null;\n /**\n * Last name.\n * @maxLength 100\n */\n lastName?: string | null;\n /**\n * Phone number.\n * @format PHONE\n */\n phone?: string | null;\n /**\n * Company name.\n * @maxLength 1000\n */\n company?: string | null;\n /** Tax information (for Brazil only). If ID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. */\n vatId?: VatId;\n}\n\nexport interface VatId {\n /** Customer's tax ID. */\n _id?: string;\n /**\n * Tax type.\n *\n * Supported values:\n * + `CPF`: for individual tax payers\n * + `CNPJ`: for corporations\n */\n type?: VatTypeWithLiterals;\n}\n\n/** tax info types */\nexport enum VatType {\n UNSPECIFIED = 'UNSPECIFIED',\n /** CPF - for individual tax payers. */\n CPF = 'CPF',\n /** CNPJ - for corporations */\n CNPJ = 'CNPJ',\n}\n\n/** @enumType */\nexport type VatTypeWithLiterals = VatType | 'UNSPECIFIED' | 'CPF' | 'CNPJ';\n\nexport interface ShippingInformation {\n /**\n * App Def Id of external provider which was a source of shipping info\n * @minLength 1\n * @maxLength 100\n */\n carrierId?: string | null;\n /**\n * Unique code (or ID) of selected shipping option. For example, `\"usps_std_overnight\"`.\n * @minLength 1\n * @maxLength 100\n */\n code?: string | null;\n /**\n * Shipping option title.\n * For example, `\"USPS Standard Overnight Delivery\"`, `\"Standard\"` or `\"First-Class Package International\"`.\n * @maxLength 250\n */\n title?: string;\n /** Shipping logistics. */\n logistics?: DeliveryLogistics;\n /** Shipping costs. */\n cost?: ShippingPrice;\n /** Shipping region. */\n region?: ShippingRegion;\n}\n\nexport interface DeliveryLogistics extends DeliveryLogisticsAddressOneOf {\n /** Shipping address and contact details. */\n shippingDestination?: AddressWithContact;\n /** Pickup details. */\n pickupDetails?: PickupDetails;\n /**\n * Expected delivery time in free text. For example, `\"3-5 business days\"`.\n * @maxLength 500\n */\n deliveryTime?: string | null;\n /**\n * Instructions for carrier. For example, `\"Please knock on the door. If unanswered, please call contact number. Thanks.\"`.\n * @maxLength 1000\n */\n instructions?: string | null;\n /**\n * Deprecated - Latest expected delivery date and time in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format.\n * @deprecated\n */\n deliverByDate?: Date | null;\n /** Expected delivery time. */\n deliveryTimeSlot?: DeliveryTimeSlot;\n}\n\n/** @oneof */\nexport interface DeliveryLogisticsAddressOneOf {\n /** Shipping address and contact details. */\n shippingDestination?: AddressWithContact;\n /** Pickup details. */\n pickupDetails?: PickupDetails;\n}\n\nexport interface PickupDetails {\n /** Pickup address. */\n address?: PickupAddress;\n /** Pickup method */\n pickupMethod?: PickupMethodWithLiterals;\n}\n\n/** Physical address */\nexport interface PickupAddress {\n /**\n * Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.\n * @format COUNTRY\n */\n country?: string | null;\n /**\n * Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.\n * @maxLength 50\n */\n subdivision?: string | null;\n /**\n * City name.\n * @maxLength 1000\n */\n city?: string | null;\n /**\n * Postal or zip code.\n * @maxLength 1000\n */\n postalCode?: string | null;\n /** Street address object, with number, name, and apartment number in separate fields. */\n streetAddress?: StreetAddress;\n /**\n * Main address line (usually street name and number).\n * @maxLength 1000\n */\n addressLine1?: string | null;\n /**\n * Free text providing more detailed address info. Usually contains apt, suite, floor.\n * @maxLength 1000\n */\n addressLine2?: string | null;\n /**\n * Country's full name.\n * @readonly\n */\n countryFullname?: string | null;\n /**\n * Subdivision full-name.\n * @readonly\n */\n subdivisionFullname?: string | null;\n}\n\nexport enum PickupMethod {\n UNKNOWN_METHOD = 'UNKNOWN_METHOD',\n STORE_PICKUP = 'STORE_PICKUP',\n PICKUP_POINT = 'PICKUP_POINT',\n}\n\n/** @enumType */\nexport type PickupMethodWithLiterals =\n | PickupMethod\n | 'UNKNOWN_METHOD'\n | 'STORE_PICKUP'\n | 'PICKUP_POINT';\n\nexport interface DeliveryTimeSlot {\n /** Delivery slot starting time. */\n from?: Date | null;\n /** Delivery slot ending time. */\n to?: Date | null;\n}\n\nexport interface ShippingPrice {\n /** Shipping price for display purposes. */\n price?: Price;\n /**\n * Total price of shipping after discounts (when relevant), and before tax.\n * @readonly\n */\n totalPriceBeforeTax?: Price;\n /**\n * Shipping price after all discounts (if any exist), and after tax.\n * @readonly\n */\n totalPriceAfterTax?: Price;\n /**\n * Tax details.\n * @deprecated Tax details.\n * @replacedBy tax_info\n * @targetRemovalDate 2026-03-30\n */\n taxDetails?: ItemTaxFullDetails;\n /** Represents all the relevant tax details for a shipping. */\n taxInfo?: LineItemTaxInfo;\n /**\n * Shipping discount before tax.\n * @readonly\n */\n discount?: Price;\n}\n\nexport interface ShippingRegion {\n /**\n * Name of shipping region. For example, `\"Metropolitan London\"`, or `\"Outer Melbourne suburbs\"`.\n * @maxLength 100\n */\n name?: string | null;\n}\n\nexport interface OrderTaxInfo {\n /** Calculated tax, added from line items. */\n totalTax?: Price;\n /**\n * 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.\n * @maxSize 50\n */\n taxBreakdown?: OrderTaxBreakdown[];\n /**\n * Whether the order is exempt from tax calculations.\n *\n * Default: `false`\n * @readonly\n */\n taxExempt?: boolean | null;\n /**\n * The total amount that was exempt from tax calculations.\n * @internal\n * @readonly\n */\n totalExempt?: Price;\n}\n\n/**\n * 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.\n * Tax breakdown is the tax amount split to the tax authorities that applied on the line item.\n */\nexport interface OrderTaxBreakdown {\n /**\n * The name of the tax against which this tax amount was calculated.\n * @maxLength 200\n */\n taxName?: string;\n /**\n * The type of tax that was calculated. Depends on the company's nexus settings as well as the jurisdiction's tax laws.\n * @maxLength 200\n */\n taxType?: string;\n /**\n * The name of the jurisdiction in which this tax detail applies.\n * @maxLength 200\n */\n jurisdiction?: string;\n /** The type of the jurisdiction in which this tax detail applies (e.g. Country,State,County,City,Special). */\n jurisdictionType?: JurisdictionTypeWithLiterals;\n /**\n * The rate at which this tax detail was calculated.\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, maxScale:6 }\n */\n rate?: string;\n /** The sum of all the tax from line items that calculated by the tax identifiers. */\n aggregatedTaxAmount?: Price;\n /**\n * The aggregated exempt amount from all line items for tax identifiers.\n * @internal\n */\n aggregatedExemptAmount?: Price;\n}\n\nexport interface AppliedDiscount extends AppliedDiscountDiscountSourceOneOf {\n /** Applied coupon info. */\n coupon?: Coupon;\n /** Merchant discount. */\n merchantDiscount?: MerchantDiscount;\n /** Automatic Discount */\n discountRule?: DiscountRule;\n /**\n * Discount type.\n * * `\"GLOBAL\"` - discount applies to entire order.\n * * `\"SPECIFIC-ITEMS\"` - discount applies to specific items.\n * * `\"SHIPPING\"` - discount applies to shipping. For example, free shipping.\n */\n discountType?: DiscountTypeWithLiterals;\n /**\n * IDs of line items discount applies to.\n * Deprecated. Use `line_item_discounts` instead.\n * @format GUID\n * @maxSize 1\n * @deprecated IDs of line items discount applies to.\n * Deprecated. Use `line_item_discounts` instead.\n * @replacedBy line_item_discounts\n * @targetRemovalDate 2024-10-30\n */\n lineItemIds?: string[];\n /**\n * Discount id.\n * @format GUID\n * @immutable\n */\n _id?: string | null;\n /**\n * Number of subscription billing cycles the discount applies to.\n * If None and discount is linked to subscription line item, it applies to all cycles.\n * @internal\n * @min 1\n * @max 999\n */\n subscriptionCycles?: number | null;\n /**\n * A list of item combinations for this applied discount.\n * Each entry represents a unique combination of line items that triggered\n * or received this discount, along with how many times that combination was applied together.\n * Relevant ONLY for BXGY and Quantity-based promotions.\n * In BXGY the combination will contain the \"X\" items with discount amount of 0.\n * @internal\n * @maxSize 1000\n */\n itemCombinations?: ItemCombination[];\n}\n\n/** @oneof */\nexport interface AppliedDiscountDiscountSourceOneOf {\n /** Applied coupon info. */\n coupon?: Coupon;\n /** Merchant discount. */\n merchantDiscount?: MerchantDiscount;\n /** Automatic Discount */\n discountRule?: DiscountRule;\n}\n\nexport enum DiscountType {\n GLOBAL = 'GLOBAL',\n SPECIFIC_ITEMS = 'SPECIFIC_ITEMS',\n SHIPPING = 'SHIPPING',\n}\n\n/** @enumType */\nexport type DiscountTypeWithLiterals =\n | DiscountType\n | 'GLOBAL'\n | 'SPECIFIC_ITEMS'\n | 'SHIPPING';\n\n/** Coupon */\nexport interface Coupon {\n /** Coupon ID. */\n _id?: string;\n /** Coupon code. */\n code?: string;\n /** Coupon name. */\n name?: string;\n /** Coupon value. */\n amount?: Price;\n}\n\nexport interface MerchantDiscount\n extends MerchantDiscountMerchantDiscountReasonOneOf {\n /**\n * Pre-defined discount reason (optional).\n * * `\"ITEMS_EXCHANGE\"` - exchange balance acquired as a result of items exchange.\n */\n discountReason?: DiscountReasonWithLiterals;\n /**\n * Discount description as free text (optional).\n * @maxLength 200\n */\n description?: string | null;\n /** Discount amount. */\n amount?: Price;\n /**\n * Discount percentage.\n * @internal\n * @format DECIMAL_VALUE\n * @decimalValue options { gte:0, lte:100, maxScale:2 }\n */\n percentage?: string | null;\n}\n\n/** @oneof */\nexport interface MerchantDiscountMerchantDiscountReasonOneOf {\n /**\n * Pre-defined discount reason (optional).\n * * `\"ITEMS_EXCHANGE\"` - exchange balance acquired as a result of items exchange.\n */\n discountReason?: DiscountReasonWithLiterals;\n /**\n * Discount description as free text (optional).\n * @maxLength 200\n */\n description?: string | null;\n}\n\nexport enum DiscountReason {\n UNSPECIFIED = 'UNSPECIFIED',\n EXCHANGED_ITEMS = 'EXCHANGED_ITEMS',\n BILLING_ADJUSTMENT = 'BILLING_ADJUSTMENT',\n}\n\n/** @enumType */\nexport type DiscountReasonWithLiterals =\n | DiscountReason\n | 'UNSPECIFIED'\n | 'EXCHANGED_ITEMS'\n | 'BILLING_ADJUSTMENT';\n\nexport interface DiscountRule {\n /**\n * Discount rule ID\n * @format GUID\n */\n _id?: string;\n /** Discount rule name */\n name?: DiscountRuleName;\n /** Discount value. */\n amount?: Price;\n}\n\nexport interface DiscountRuleName {\n /**\n * Original discount rule name (in site's default language).\n * @minLength 1\n * @maxLength 256\n */\n original?: string;\n /**\n * Translated discount rule name according to buyer language. Defaults to `original` when not provided.\n * @minLength 1\n * @maxLength 500\n */\n translated?: string | null;\n}\n\nexport interface LineItemDiscount {\n /**\n * ID of line item the discount applies to.\n * @format GUID\n */\n _id?: string;\n /** Total discount for this line item. */\n totalDiscount?: Price;\n}\n\nexport interface ItemCombination {\n /**\n * The number of times this exact combination of items (with the specified quantities) was applied together in the order.\n * @min 1\n * @max 100000\n */\n count?: number;\n /**\n * Line items that participated together in this combination.\n * @minSize 1\n * @maxSize 100\n */\n lineItems?: ItemCombinationLineItem[];\n}\n\nexport interface ItemCombinationLineItem {\n /**\n * The unique ID of the line item to which this discount applies.\n * @format GUID\n */\n lineItemId?: string;\n /** Total discount amount for all units (quantity) of this line item in this combination. */\n discountAmount?: Price;\n /**\n * Number of units from this line item that participated in a single combination.\n * @min 1\n * @max 100000\n */\n quantity?: number;\n}\n\nexport interface ChannelInfo {\n /** Sales channel that submitted the order. */\n type?: ChannelTypeWithLiterals;\n /**\n * Reference to an order ID from an external system.\n * @maxLength 100\n */\n externalOrderId?: string | null;\n /**\n * URL to the order in the external system.\n * @maxLength 300\n */\n externalOrderUrl?: string | null;\n}\n\nexport enum ChannelType {\n /** Unspecified sales channel. This value is not supported. */\n UNSPECIFIED = 'UNSPECIFIED',\n /** A web client. */\n WEB = 'WEB',\n /** [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). */\n POS = 'POS',\n /** [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). */\n EBAY = 'EBAY',\n /** [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). */\n AMAZON = 'AMAZON',\n /** Other sales platform. */\n OTHER_PLATFORM = 'OTHER_PLATFORM',\n /** [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). */\n WIX_APP_STORE = 'WIX_APP_STORE',\n /** 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) */\n WIX_INVOICES = 'WIX_INVOICES',\n /** Wix merchant backoffice. */\n BACKOFFICE_MERCHANT = 'BACKOFFICE_MERCHANT',\n /** Wish sales channel. */\n WISH = 'WISH',\n /** [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). */\n CLASS_PASS = 'CLASS_PASS',\n /** Global-E sales channel. */\n GLOBAL_E = 'GLOBAL_E',\n /** [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). */\n FACEBOOK = 'FACEBOOK',\n /** [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). */\n ETSY = 'ETSY',\n /** [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). */\n TIKTOK = 'TIKTOK',\n /** [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). */\n FAIRE_COM = 'FAIRE_COM',\n /** PayPal Agentic Checkout sales channel. */\n PAYPAL_AGENTIC_CHECKOUT = 'PAYPAL_AGENTIC_CHECKOUT',\n}\n\n/** @enumType */\nexport type ChannelTypeWithLiterals =\n | ChannelType\n | 'UNSPECIFIED'\n | 'WEB'\n | 'POS'\n | 'EBAY'\n | 'AMAZON'\n | 'OTHER_PLATFORM'\n | 'WIX_APP_STORE'\n | 'WIX_INVOICES'\n | 'BACKOFFICE_MERCHANT'\n | 'WISH'\n | 'CLASS_PASS'\n | 'GLOBAL_E'\n | 'FACEBOOK'\n | 'ETSY'\n | 'TIKTOK'\n | 'FAIRE_COM'\n | 'PAYPAL_AGENTIC_CHECKOUT';\n\nexport interface CustomField {\n /** Custom field value. */\n value?: any;\n /**\n * Custom field title.\n * @minLength 1\n * @maxLength 500\n */\n title?: string;\n /**\n * Translated custom field title.\n * @minLength 1\n * @maxLength 500\n */\n translatedTitle?: string | null;\n}\n\nexport interface V1SubscriptionTitle {\n /**\n * 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).\n * @minLength 1\n * @maxLength 150\n */\n original?: string;\n /**\n * Subscription option name translated into the buyer's language.\n *\n * Default: Same as `original`.\n * @minLength 1\n * @maxLength 150\n */\n translated?: string | null;\n}\n\nexport interface AdditionalFee {\n /**\n * Additional fee's unique code for future processing.\n * @minLength 1\n * @maxLength 100\n */\n code?: string | null;\n /**\n * Name of additional fee.\n * @minLength 1\n * @maxLength 50\n */\n name?: string;\n /** Additional fee's price. */\n price?: Price;\n /**\n * Tax details.\n * @deprecated Tax details.\n * @replacedBy tax_info\n * @targetRemovalDate 2026-03-30\n */\n taxDetails?: ItemTaxFullDetails;\n /** Represents all the relevant tax details for additional fee. */\n taxInfo?: LineItemTaxInfo;\n /**\n * SPI implementer's `appId`.\n * @format GUID\n */\n providerAppId?: string | null;\n /** Additional fee's price before tax. */\n priceBeforeTax?: Price;\n /** Additional fee's price after tax. */\n priceAfterTax?: Price;\n /**\n * Additional fee's id.\n * @format GUID\n * @immutable\n */\n _id?: string;\n /**\n * Optional - Line items associated with this additional fee.\n * If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order.\n * @format GUID\n */\n lineItemIds?: string[];\n /**\n * Number of subscription billing cycles the additional fee applies to.\n * If None and additional fee is linked to subscription line item, it applies to all cycles.\n * @internal\n * @min 1\n * @max 999\n */\n subscriptionCycles?: number | null;\n /**\n * Specifies the entity that added the additional fee.\n * @internal\n */\n source?: AdditionalFeeSourceWithLiterals;\n}\n\nexport enum AdditionalFeeSource {\n UNKNOWN_ADDITIONAL_FEE_SOURCE = 'UNKNOWN_ADDITIONAL_FEE_SOURCE',\n /** The additional fee was added by an additional fee service plugin. */\n SERVICE_PLUGIN = 'SERVICE_PLUGIN',\n /** The additional fee was added to the item by a catalog or custom line item. */\n ITEM = 'ITEM',\n /** The additional fee was added manually on request. */\n MANUAL = 'MANUAL',\n /** The additional fee was added by the shipping provider. */\n SHIPPING = 'SHIPPING',\n /** The additional fee was added by the Wix eCommerce platform. */\n PLATFORM = 'PLATFORM',\n}\n\n/** @enumType */\nexport type AdditionalFeeSourceWithLiterals =\n | AdditionalFeeSource\n | 'UNKNOWN_ADDITIONAL_FEE_SOURCE'\n | 'SERVICE_PLUGIN'\n | 'ITEM'\n | 'MANUAL'\n | 'SHIPPING'\n | 'PLATFORM';\n\nexport interface Location {\n /**\n * Location ID.\n * Learn more about the [Wix Locations API](https://dev.wix.com/docs/rest/business-management/locations/introduction).\n * @format GUID\n */\n _id?: string;\n /**\n * Location name.\n * @minLength 1\n * @maxLength 500\n * @readonly\n */\n name?: string;\n}\n\nexport interface CreateSubscriptionContractRequest {\n /** SubscriptionContract to be created. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface CreateSubscriptionContractResponse {\n /** The created SubscriptionContract. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface GetSubscriptionContractRequest {\n /**\n * ID of the SubscriptionContract to retrieve.\n * @format GUID\n */\n subscriptionContractId: string;\n}\n\nexport interface GetSubscriptionContractResponse {\n /** The requested SubscriptionContract. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface UpdateSubscriptionContractRequest {\n /** SubscriptionContract to be updated, may be partial. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface UpdateSubscriptionContractResponse {\n /** Updated SubscriptionContract. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface QuerySubscriptionContractsRequest {\n /** WQL expression. */\n query?: CursorQuery;\n}\n\nexport interface CursorQuery extends CursorQueryPagingMethodOneOf {\n /** 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`. */\n cursorPaging?: CursorPaging;\n /**\n * Filter object in the following format:\n * `\"filter\" : {\n * \"fieldName1\": \"value1\",\n * \"fieldName2\":{\"$operator\":\"value2\"}\n * }`\n * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`\n * Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).\n */\n filter?: Record<string, any> | null;\n /**\n * Sort object in the following format:\n * `[{\"fieldName\":\"sortField1\",\"order\":\"ASC\"},{\"fieldName\":\"sortField2\",\"order\":\"DESC\"}]`\n * Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section).\n * @maxSize 5\n */\n sort?: Sorting[];\n}\n\n/** @oneof */\nexport interface CursorQueryPagingMethodOneOf {\n /** 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`. */\n cursorPaging?: CursorPaging;\n}\n\nexport interface Sorting {\n /**\n * Name of the field to sort by.\n * @maxLength 512\n */\n fieldName?: string;\n /** Sort order. */\n order?: SortOrderWithLiterals;\n}\n\nexport enum SortOrder {\n ASC = 'ASC',\n DESC = 'DESC',\n}\n\n/** @enumType */\nexport type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';\n\nexport interface CursorPaging {\n /**\n * Maximum number of items to return in the results.\n * @max 100\n */\n limit?: number | null;\n /**\n * Pointer to the next or previous page in the list of results.\n *\n * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n * Not relevant for the first request.\n * @maxLength 16000\n */\n cursor?: string | null;\n}\n\nexport interface QuerySubscriptionContractsResponse {\n /** List of SubscriptionContracts. */\n subscriptionContracts?: SubscriptionContract[];\n /** Paging metadata */\n pagingMetadata?: CursorPagingMetadata;\n}\n\nexport interface CursorPagingMetadata {\n /** Number of items returned in the response. */\n count?: number | null;\n /** Cursor strings that point to the next page, previous page, or both. */\n cursors?: Cursors;\n /**\n * Whether there are more pages to retrieve following the current page.\n *\n * + `true`: Another page of results can be retrieved.\n * + `false`: This is the last page.\n */\n hasNext?: boolean | null;\n}\n\nexport interface Cursors {\n /**\n * Cursor string pointing to the next page in the list of results.\n * @maxLength 16000\n */\n next?: string | null;\n /**\n * Cursor pointing to the previous page in the list of results.\n * @maxLength 16000\n */\n prev?: string | null;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * 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.\n * 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.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface Empty {}\n\nexport interface BulkCreateSubscriptionContractsRequest {\n /**\n * List of SubscriptionContracts to create.\n * @minSize 1\n * @maxSize 100\n */\n subscriptionContracts?: SubscriptionContract[];\n /**\n * Whether to return the full subscription contract entities in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface BulkCreateSubscriptionContractsResponse {\n /**\n * Results of the contract created operation.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkSubscriptionContractResult[];\n /** Bulk action metadata. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface BulkSubscriptionContractResult {\n /** Metadata about a single update operation. */\n itemMetadata?: ItemMetadata;\n /**\n * Created subscription contract.\n *\n * Only present if `returnEntity` was `true`.\n */\n item?: SubscriptionContract;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateSubscriptionContractsRequest {\n /**\n * List of SubscriptionContracts to update.\n * @minSize 1\n * @maxSize 100\n */\n subscriptionContracts?: MaskedSubscriptionContract[];\n /**\n * Whether to return the full subscription contract entities in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface MaskedSubscriptionContract {\n /** Subscription contract to be updated. */\n subscriptionContract?: SubscriptionContract;\n}\n\nexport interface BulkUpdateSubscriptionContractsResponse {\n /**\n * Results of the contract updated operation.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkSubscriptionContractResult[];\n /** Metadata about the bulk operation. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\nexport interface BaseEventMetadata {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n}\n\nexport interface EventMetadata extends BaseEventMetadata {\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * 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.\n * 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.\n */\n entityEventSequence?: string | null;\n accountInfo?: AccountInfoMetadata;\n}\n\ninterface AccountInfoMetadata {\n /** ID of the Wix account associated with the event */\n accountId: string;\n /** ID of the Wix site associated with the event. Only included when the event is tied to a specific site. */\n siteId?: string;\n /** ID of the parent Wix account. Only included when 'accountId' belongs to a child account. */\n parentAccountId?: string;\n}\n\nexport interface SubscriptionContractCreatedEnvelope {\n entity: SubscriptionContract;\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Read eCommerce - all read permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @webhook\n * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_created\n * @slug created\n * @documentationMaturity preview\n */\nexport declare function onSubscriptionContractCreated(\n handler: (event: SubscriptionContractCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface SubscriptionContractDeletedEnvelope {\n metadata: EventMetadata;\n}\n\n/** @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Read eCommerce - all read permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @webhook\n * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_deleted\n * @slug deleted\n * @documentationMaturity preview\n */\nexport declare function onSubscriptionContractDeleted(\n handler: (event: SubscriptionContractDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface SubscriptionContractUpdatedEnvelope {\n entity: SubscriptionContract;\n metadata: EventMetadata;\n /** @hidden */\n modifiedFields: Record<string, any>;\n}\n\n/** @permissionScope Manage Stores - all permissions\n * @permissionScopeId SCOPE.DC-STORES-MEGA.MANAGE-STORES\n * @permissionScope Read eCommerce - all read permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.READ-ECOM\n * @permissionScope Manage Restaurants - all permissions\n * @permissionScopeId SCOPE.RESTAURANTS.MEGA-SCOPES\n * @permissionScope Manage eCommerce - all permissions\n * @permissionScopeId SCOPE.DC-ECOM-MEGA.MANAGE-ECOM\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @webhook\n * @eventType wix.ecom.subscription_contracts.v1.subscription_contract_updated\n * @slug updated\n * @documentationMaturity preview\n */\nexport declare function onSubscriptionContractUpdated(\n handler: (event: SubscriptionContractUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Retrieves a SubscriptionContract.\n * @param subscriptionContractId - ID of the SubscriptionContract to retrieve.\n * @public\n * @documentationMaturity preview\n * @requiredField subscriptionContractId\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @applicableIdentity APP\n * @returns The requested SubscriptionContract.\n * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.GetSubscriptionContract\n */\nexport async function getSubscriptionContract(\n subscriptionContractId: string\n): Promise<\n NonNullablePaths<\n SubscriptionContract,\n | `subscriptionSettings.frequency`\n | `subscriptionSettings.autoRenewal`\n | `subscriptionSettings.enableCustomerCancellation`\n | `subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionSettings.freeTrialPeriod.interval`\n | `lineItems`\n | `lineItems.${number}._id`\n | `lineItems.${number}.productName.original`\n | `lineItems.${number}.catalogReference.catalogItemId`\n | `lineItems.${number}.catalogReference.appId`\n | `lineItems.${number}.quantity`\n | `lineItems.${number}.totalDiscount.amount`\n | `lineItems.${number}.totalDiscount.formattedAmount`\n | `lineItems.${number}.physicalProperties.shippable`\n | `lineItems.${number}.itemType.preset`\n | `lineItems.${number}.itemType.custom`\n | `lineItems.${number}.paymentOption`\n | `lineItems.${number}.taxDetails.taxRate`\n | `lineItems.${number}.taxInfo.taxIncludedInPrice`\n | `lineItems.${number}.digitalFile.fileId`\n | `lineItems.${number}.subscriptionInfo.cycleNumber`\n | `lineItems.${number}.subscriptionInfo.subscriptionOptionTitle`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.frequency`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.autoRenewal`\n | `lineItems.${number}.subscriptionInfo.subscriptionSettings.enableCustomerCancellation`\n | `lineItems.${number}.priceDescription.original`\n | `lineItems.${number}.taxableAddress.addressType`\n | `lineItems.${number}.priceUndetermined`\n | `buyerInfo.visitorId`\n | `buyerInfo.memberId`\n | `weightUnit`\n | `taxIncludedInPrices`\n | `billingInfo.address.streetAddress.number`\n | `billingInfo.address.streetAddress.name`\n | `billingInfo.contactDetails.vatId._id`\n | `billingInfo.contactDetails.vatId.type`\n | `shippingInfo.title`\n | `shippingInfo.logistics.pickupDetails.pickupMethod`\n | `appliedDiscounts`\n | `appliedDiscounts.${number}.coupon._id`\n | `appliedDiscounts.${number}.coupon.code`\n | `appliedDiscounts.${number}.coupon.name`\n | `appliedDiscounts.${number}.merchantDiscount.discountReason`\n | `appliedDiscounts.${number}.discountRule._id`\n | `appliedDiscounts.${number}.discountRule.name.original`\n | `appliedDiscounts.${number}.discountType`\n | `channelInfo.type`\n | `customFields`\n | `customFields.${number}.title`\n | `additionalFees`\n | `additionalFees.${number}.name`\n | `additionalFees.${number}._id`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n subscriptionContractId: subscriptionContractId,\n });\n\n const reqOpts =\n ambassadorWixEcomSubscriptionContractsV1SubscriptionContract.getSubscriptionContract(\n payload\n );\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(\n transformPaths(result.data, [\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'subscriptionContract.lineItems.image' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'subscriptionContract.billingInfo.address' },\n {\n path: 'subscriptionContract.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'subscriptionContract.recipientInfo.address' },\n ],\n },\n ])\n )?.subscriptionContract!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { subscriptionContractId: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['subscriptionContractId']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\n/**\n * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].\n *\n * Up to 300 SubscriptionContracts can be returned per request.\n *\n * To learn how to query SubscriptionContracts, see [API Query Language][2].\n *\n * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging\n * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language\n * @public\n * @documentationMaturity preview\n * @permissionId ECOM.SUBSCRIPTION_CONTRACT_READ\n * @applicableIdentity APP\n * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts\n */\nexport function querySubscriptionContracts(): SubscriptionContractsQueryBuilder {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[0] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n return queryBuilder<\n SubscriptionContract,\n 'CURSOR',\n QuerySubscriptionContractsRequest,\n QuerySubscriptionContractsResponse\n >({\n func: async (payload: QuerySubscriptionContractsRequest) => {\n const reqOpts =\n ambassadorWixEcomSubscriptionContractsV1SubscriptionContract.querySubscriptionContracts(\n payload\n );\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n return result;\n } catch (err) {\n sideEffects?.onError?.(err);\n throw err;\n }\n },\n requestTransformer: (query: QuerySubscriptionContractsRequest['query']) => {\n const args = [query, {}] as [\n QuerySubscriptionContractsRequest['query'],\n {}\n ];\n return renameKeysFromSDKRequestToRESTRequest({\n ...args?.[1],\n query: args?.[0],\n });\n },\n responseTransformer: ({\n data,\n }: HttpResponse<QuerySubscriptionContractsResponse>) => {\n const transformedData = renameKeysFromRESTResponseToSDKResponse(\n transformPaths(data, [\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'subscriptionContracts.lineItems.image' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'subscriptionContracts.billingInfo.address' },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'subscriptionContracts.recipientInfo.address' },\n ],\n },\n ])\n );\n\n return {\n items: transformedData?.subscriptionContracts,\n pagingMetadata: transformedData?.pagingMetadata,\n };\n },\n errorTransformer: (err: unknown) => {\n const transformedError = sdkTransformError(err, {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { query: '$[0]' },\n singleArgumentUnchanged: false,\n });\n\n throw transformedError;\n },\n pagingMethod: 'CURSOR',\n transformationPaths: {},\n });\n}\n\ninterface QueryCursorResult {\n cursors: Cursors;\n hasNext: () => boolean;\n hasPrev: () => boolean;\n length: number;\n pageSize: number;\n}\n\nexport interface SubscriptionContractsQueryResult extends QueryCursorResult {\n items: SubscriptionContract[];\n query: SubscriptionContractsQueryBuilder;\n next: () => Promise<SubscriptionContractsQueryResult>;\n prev: () => Promise<SubscriptionContractsQueryResult>;\n}\n\nexport interface SubscriptionContractsQueryBuilder {\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n eq: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ne: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n ge: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n gt: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n le: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `value`.\n * @param value - Value to compare against.\n * @documentationMaturity preview\n */\n lt: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `string`.\n * @param string - String to compare against. Case-insensitive.\n * @documentationMaturity preview\n */\n startsWith: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: string\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyName - Property whose value is compared with `values`.\n * @param values - List of values to compare against.\n * @documentationMaturity preview\n */\n hasSome: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any[]\n ) => SubscriptionContractsQueryBuilder;\n /** @documentationMaturity preview */\n in: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: any\n ) => SubscriptionContractsQueryBuilder;\n /** @documentationMaturity preview */\n exists: (\n propertyName: '_id' | 'buyerInfo.contactId',\n value: boolean\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n ascending: (\n ...propertyNames: Array<'_id' | 'buyerInfo.contactId'>\n ) => SubscriptionContractsQueryBuilder;\n /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.\n * @documentationMaturity preview\n */\n descending: (\n ...propertyNames: Array<'_id' | 'buyerInfo.contactId'>\n ) => SubscriptionContractsQueryBuilder;\n /** @param limit - Number of items to return, which is also the `pageSize` of the results object.\n * @documentationMaturity preview\n */\n limit: (limit: number) => SubscriptionContractsQueryBuilder;\n /** @param cursor - A pointer to specific record\n * @documentationMaturity preview\n */\n skipTo: (cursor: string) => SubscriptionContractsQueryBuilder;\n /** @documentationMaturity preview */\n find: () => Promise<SubscriptionContractsQueryResult>;\n}\n\n/**\n * @hidden\n * @fqn wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts\n * @requiredField query\n */\nexport async function typedQuerySubscriptionContracts(\n query: SubscriptionContractQuery\n): Promise<\n NonNullablePaths<\n QuerySubscriptionContractsResponse,\n | `subscriptionContracts`\n | `subscriptionContracts.${number}.subscriptionSettings.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.autoRenewal`\n | `subscriptionContracts.${number}.subscriptionSettings.enableCustomerCancellation`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.frequency`\n | `subscriptionContracts.${number}.subscriptionSettings.freeTrialPeriod.interval`\n | `subscriptionContracts.${number}.buyerInfo.visitorId`\n | `subscriptionContracts.${number}.buyerInfo.memberId`\n | `subscriptionContracts.${number}.weightUnit`\n | `subscriptionContracts.${number}.taxIncludedInPrices`\n | `subscriptionContracts.${number}.shippingInfo.title`\n | `subscriptionContracts.${number}.channelInfo.type`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({ query: query });\n\n const reqOpts =\n ambassadorWixEcomSubscriptionContractsV1SubscriptionContract.querySubscriptionContracts(\n payload\n );\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(\n transformPaths(result.data, [\n {\n transformFn: transformRESTImageToSDKImage,\n paths: [{ path: 'subscriptionContracts.lineItems.image' }],\n },\n {\n transformFn: transformRESTAddressToSDKAddress,\n paths: [\n { path: 'subscriptionContracts.billingInfo.address' },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address',\n },\n { path: 'subscriptionContracts.recipientInfo.address' },\n ],\n },\n ])\n )!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { query: '$[0]' },\n singleArgumentUnchanged: false,\n },\n ['query']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface SubscriptionContractQuerySpec extends QuerySpec {\n paging: 'cursor';\n wql: [\n {\n fields: ['_id', 'buyerInfo.contactId'];\n operators: '*';\n sort: 'BOTH';\n }\n ];\n}\n\nexport type CommonQueryWithEntityContext = QuerySdkType<\n SubscriptionContract,\n SubscriptionContractQuerySpec\n>;\nexport type SubscriptionContractQuery = {\n /** \n 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`. \n */\n cursorPaging?: {\n /** \n Maximum number of items to return in the results. \n @max: 100 \n */\n limit?:\n | NonNullable<CommonQueryWithEntityContext['cursorPaging']>['limit']\n | null;\n /** \n Pointer to the next or previous page in the list of results.\n\n Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n Not relevant for the first request. \n @maxLength: 16000 \n */\n cursor?:\n | NonNullable<CommonQueryWithEntityContext['cursorPaging']>['cursor']\n | null;\n };\n /** \n Filter object in the following format:\n `\"filter\" : {\n \"fieldName1\": \"value1\",\n \"fieldName2\":{\"$operator\":\"value2\"}\n }`\n Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`\n Learn more about the [filter format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section). \n */\n filter?: CommonQueryWithEntityContext['filter'] | null;\n /** \n Sort object in the following format:\n `[{\"fieldName\":\"sortField1\",\"order\":\"ASC\"},{\"fieldName\":\"sortField2\",\"order\":\"DESC\"}]`\n Learn more about the [sort format](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section). \n @maxSize: 5 \n */\n sort?: {\n /** \n Name of the field to sort by. \n @maxLength: 512 \n */\n fieldName?: NonNullable<\n CommonQueryWithEntityContext['sort']\n >[number]['fieldName'];\n /** \n Sort order. \n */\n order?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['order'];\n }[];\n};\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/subscription-contracts/v1/subscription-contracts',\n destPath: '/v1/subscription-contracts',\n },\n ],\n '*.dev.wix-code.com': [\n {\n srcPath: '/ecom/subscription-contracts/v1/subscription-contracts',\n destPath: '/v1/subscription-contracts',\n },\n ],\n _: [\n {\n srcPath: '/ecom/subscription-contracts/v1/subscription-contracts',\n destPath: '/v1/subscription-contracts',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_subscription-contracts';\n\n/** Retrieves a SubscriptionContract. */\nexport function getSubscriptionContract(\n payload: object\n): RequestOptionsFactory<any> {\n function __getSubscriptionContract({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.subscription_contracts.v1.subscription_contract',\n method: 'GET' as any,\n methodFqn:\n 'wix.ecom.subscription_contracts.v1.SubscriptionContracts.GetSubscriptionContract',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl({\n protoPath: '/v1/subscription-contracts/{subscriptionContractId}',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'subscriptionContract.createdDate' },\n { path: 'subscriptionContract.updatedDate' },\n { path: 'subscriptionContract.subscriptionSettings.startDate' },\n {\n path: 'subscriptionContract.lineItems.image.urlExpirationDate',\n },\n {\n path: 'subscriptionContract.lineItems.digitalFile.expirationDate',\n },\n {\n path: 'subscriptionContract.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.deliverByDate',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.deliveryTimeSlot.from',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.deliveryTimeSlot.to',\n },\n ],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n { path: 'subscriptionContract.lineItems.image.focalPoint.x' },\n { path: 'subscriptionContract.lineItems.image.focalPoint.y' },\n {\n path: 'subscriptionContract.lineItems.physicalProperties.weight',\n },\n {\n path: 'subscriptionContract.billingInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.billingInfo.address.geocode.longitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.shippingDestination.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.shippingDestination.address.geocode.longitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.pickupDetails.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.shippingInfo.logistics.pickupDetails.address.geocode.longitude',\n },\n {\n path: 'subscriptionContract.recipientInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContract.recipientInfo.address.geocode.longitude',\n },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getSubscriptionContract;\n}\n\n/**\n * Retrieves a list of SubscriptionContracts, given the provided [paging, filtering, and sorting][1].\n *\n * Up to 300 SubscriptionContracts can be returned per request.\n *\n * To learn how to query SubscriptionContracts, see [API Query Language][2].\n *\n * [1]: https://dev.wix.com/api/rest/getting-started/sorting-and-paging\n * [2]: https://dev.wix.com/api/rest/getting-started/api-query-language\n */\nexport function querySubscriptionContracts(\n payload: object\n): RequestOptionsFactory<any> {\n function __querySubscriptionContracts({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.subscription_contracts.v1.subscription_contract',\n method: 'GET' as any,\n methodFqn:\n 'wix.ecom.subscription_contracts.v1.SubscriptionContracts.QuerySubscriptionContracts',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl({\n protoPath: '/v1/subscription-contracts/query',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload, true),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'subscriptionContracts.createdDate' },\n { path: 'subscriptionContracts.updatedDate' },\n { path: 'subscriptionContracts.subscriptionSettings.startDate' },\n {\n path: 'subscriptionContracts.lineItems.image.urlExpirationDate',\n },\n {\n path: 'subscriptionContracts.lineItems.digitalFile.expirationDate',\n },\n {\n path: 'subscriptionContracts.lineItems.subscriptionInfo.subscriptionSettings.startDate',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.deliverByDate',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.deliveryTimeSlot.from',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.deliveryTimeSlot.to',\n },\n ],\n },\n {\n transformFn: transformRESTFloatToSDKFloat,\n paths: [\n { path: 'subscriptionContracts.lineItems.image.focalPoint.x' },\n { path: 'subscriptionContracts.lineItems.image.focalPoint.y' },\n {\n path: 'subscriptionContracts.lineItems.physicalProperties.weight',\n },\n {\n path: 'subscriptionContracts.billingInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.billingInfo.address.geocode.longitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.shippingDestination.address.geocode.longitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.shippingInfo.logistics.pickupDetails.address.geocode.longitude',\n },\n {\n path: 'subscriptionContracts.recipientInfo.address.geocode.latitude',\n },\n {\n path: 'subscriptionContracts.recipientInfo.address.geocode.longitude',\n },\n ],\n },\n ]),\n fallback: [\n {\n method: 'POST' as any,\n url: resolveWixEcomSubscriptionContractsV1SubscriptionContractsUrl({\n protoPath: '/v1/subscription-contracts/query',\n data: payload,\n host,\n }),\n data: payload,\n },\n ],\n };\n\n return metadata;\n }\n\n return __querySubscriptionContracts;\n}\n","import {\n getSubscriptionContract as publicGetSubscriptionContract,\n querySubscriptionContracts as publicQuerySubscriptionContracts,\n typedQuerySubscriptionContracts as publicTypedQuerySubscriptionContracts,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { createEventModule } from '@wix/sdk-runtime/event-definition-modules';\nimport {\n BuildRESTFunction,\n MaybeContext,\n BuildEventDefinition,\n} from '@wix/sdk-types';\nimport { HttpClient } from '@wix/sdk-types';\nimport { createQueryOverloadRouter } from '@wix/sdk-runtime/query-method-router';\nimport {\n SubscriptionContractQuery,\n SubscriptionContractsQueryBuilder,\n typedQuerySubscriptionContracts as universalTypedQuerySubscriptionContracts,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\nimport { onSubscriptionContractCreated as publicOnSubscriptionContractCreated } from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\nimport { onSubscriptionContractDeleted as publicOnSubscriptionContractDeleted } from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\nimport { onSubscriptionContractUpdated as publicOnSubscriptionContractUpdated } from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.public.js';\n\nfunction customQuerySubscriptionContracts(httpClient: HttpClient) {\n const router = createQueryOverloadRouter({\n builderQueryFunction: () => publicQuerySubscriptionContracts(httpClient)(),\n typedQueryFunction: (query: SubscriptionContractQuery) =>\n publicTypedQuerySubscriptionContracts(httpClient)(query),\n hasOptionsParameter: false,\n });\n\n function overloadedQuery(): SubscriptionContractsQueryBuilder;\n function overloadedQuery(\n query: SubscriptionContractQuery\n ): ReturnType<typeof universalTypedQuerySubscriptionContracts>;\n function overloadedQuery(query?: SubscriptionContractQuery): any {\n return router(...arguments);\n }\n\n return overloadedQuery;\n}\n\nexport const getSubscriptionContract: MaybeContext<\n BuildRESTFunction<typeof publicGetSubscriptionContract> &\n typeof publicGetSubscriptionContract\n> = /*#__PURE__*/ createRESTModule(publicGetSubscriptionContract);\nexport const querySubscriptionContracts: MaybeContext<\n BuildRESTFunction<typeof customQuerySubscriptionContracts> &\n typeof customQuerySubscriptionContracts\n> = /*#__PURE__*/ createRESTModule(customQuerySubscriptionContracts);\n/** */\nexport const onSubscriptionContractCreated: BuildEventDefinition<\n typeof publicOnSubscriptionContractCreated\n> &\n typeof publicOnSubscriptionContractCreated = createEventModule(\n publicOnSubscriptionContractCreated\n);\n/** */\nexport const onSubscriptionContractDeleted: BuildEventDefinition<\n typeof publicOnSubscriptionContractDeleted\n> &\n typeof publicOnSubscriptionContractDeleted = createEventModule(\n publicOnSubscriptionContractDeleted\n);\n/** */\nexport const onSubscriptionContractUpdated: BuildEventDefinition<\n typeof publicOnSubscriptionContractUpdated\n> &\n typeof publicOnSubscriptionContractUpdated = createEventModule(\n publicOnSubscriptionContractUpdated\n);\n\nexport {\n SubscriptionFrequency,\n DescriptionLineType,\n ItemTypePreset,\n PaymentOptionType,\n JurisdictionType,\n V2SubscriptionFrequency,\n AdjustmentType,\n TaxableAddressType,\n WeightUnit,\n ChargeType,\n VatType,\n PickupMethod,\n DiscountType,\n DiscountReason,\n ChannelType,\n AdditionalFeeSource,\n SortOrder,\n WebhookIdentityType,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\nexport {\n SubscriptionContract,\n V1SubscriptionDescription,\n V1SubscriptionSettings,\n V1FreeTrialPeriod,\n OrderLineItem,\n ProductName,\n CatalogReference,\n Price,\n DescriptionLine,\n DescriptionLineValueOneOf,\n DescriptionLineDescriptionLineValueOneOf,\n DescriptionLineName,\n PlainTextValue,\n Color,\n FocalPoint,\n PhysicalProperties,\n ItemType,\n ItemTypeItemTypeDataOneOf,\n ItemTaxFullDetails,\n LineItemTaxInfo,\n LineItemTaxBreakdown,\n DigitalFile,\n SubscriptionInfo,\n SubscriptionTitle,\n SubscriptionDescription,\n SubscriptionSettings,\n FreeTrialPeriod,\n BillingAdjustment,\n BillingAdjustmentPriceSummary,\n PriceDescription,\n LocationAndQuantity,\n TaxableAddress,\n TaxableAddressTaxableAddressDataOneOf,\n ExtendedFields,\n ModifierGroup,\n TranslatableString,\n ItemModifier,\n BuyerInfo,\n BuyerInfoIdOneOf,\n CurrencyConversionDetails,\n PriceSummary,\n PlatformFeeSummary,\n PlatformFee,\n AddressWithContact,\n Address,\n StreetAddress,\n AddressLocation,\n FullAddressContactDetails,\n VatId,\n ShippingInformation,\n DeliveryLogistics,\n DeliveryLogisticsAddressOneOf,\n PickupDetails,\n PickupAddress,\n DeliveryTimeSlot,\n ShippingPrice,\n ShippingRegion,\n OrderTaxInfo,\n OrderTaxBreakdown,\n AppliedDiscount,\n AppliedDiscountDiscountSourceOneOf,\n Coupon,\n MerchantDiscount,\n MerchantDiscountMerchantDiscountReasonOneOf,\n DiscountRule,\n DiscountRuleName,\n LineItemDiscount,\n ItemCombination,\n ItemCombinationLineItem,\n ChannelInfo,\n CustomField,\n V1SubscriptionTitle,\n AdditionalFee,\n Location,\n CreateSubscriptionContractRequest,\n CreateSubscriptionContractResponse,\n GetSubscriptionContractRequest,\n GetSubscriptionContractResponse,\n UpdateSubscriptionContractRequest,\n UpdateSubscriptionContractResponse,\n QuerySubscriptionContractsRequest,\n CursorQuery,\n CursorQueryPagingMethodOneOf,\n Sorting,\n CursorPaging,\n QuerySubscriptionContractsResponse,\n CursorPagingMetadata,\n Cursors,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n Empty,\n BulkCreateSubscriptionContractsRequest,\n BulkCreateSubscriptionContractsResponse,\n BulkSubscriptionContractResult,\n ItemMetadata,\n ApplicationError,\n BulkActionMetadata,\n BulkUpdateSubscriptionContractsRequest,\n MaskedSubscriptionContract,\n BulkUpdateSubscriptionContractsResponse,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n AccountInfo,\n BaseEventMetadata,\n EventMetadata,\n SubscriptionContractCreatedEnvelope,\n SubscriptionContractDeletedEnvelope,\n SubscriptionContractUpdatedEnvelope,\n SubscriptionContractsQueryResult,\n SubscriptionContractsQueryBuilder,\n SubscriptionContractQuerySpec,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\nexport {\n SubscriptionFrequencyWithLiterals,\n DescriptionLineTypeWithLiterals,\n ItemTypePresetWithLiterals,\n PaymentOptionTypeWithLiterals,\n JurisdictionTypeWithLiterals,\n V2SubscriptionFrequencyWithLiterals,\n AdjustmentTypeWithLiterals,\n TaxableAddressTypeWithLiterals,\n WeightUnitWithLiterals,\n ChargeTypeWithLiterals,\n VatTypeWithLiterals,\n PickupMethodWithLiterals,\n DiscountTypeWithLiterals,\n DiscountReasonWithLiterals,\n ChannelTypeWithLiterals,\n AdditionalFeeSourceWithLiterals,\n SortOrderWithLiterals,\n WebhookIdentityTypeWithLiterals,\n CommonQueryWithEntityContext,\n SubscriptionContractQuery,\n} from './ecom-subscription-contracts-v1-subscription-contract-subscription-contracts.universal.js';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iCAAAA;AAAA,EAAA,qCAAAC;AAAA,EAAA,qCAAAC;AAAA,EAAA,qCAAAC;AAAA,EAAA,kCAAAC;AAAA;AAAA;;;ACAA,IAAAC,iCAAwD;AACxD,IAAAC,kBAAiD;AACjD,IAAAC,gBAA6C;AAC7C,IAAAC,gBAA6C;AAC7C,IAAAC,oBAAqD;AACrD,IAAAC,0BAA+B;AAC/B,uBAA8D;;;ACN9D,6BAAoD;AACpD,2BAA6B;AAC7B,oCAGO;;;ACLP,0BAAkC;AAClC,mBAA6C;AAC7C,uBAAqD;AACrD,6BAA+B;AAC/B,IAAAC,uBAA2B;AAI3B,SAAS,8DACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,sBAAsB;AAAA,MACpB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA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A,UACL,EAAE,MAAM,yBAAyB;AAAA,UACjC,EAAE,MAAM,iCAAiC;AAAA,QAC3C;AAAA,MACF;AAAA,MACA;AAAA,QACE,aAAa;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,6CAA6C;AAAA,UACrD,EAAE,MAAM,qDAAqD;AAAA,QAC/D;AAAA,MACF;AAAA,MACA;AAAA,QACE,aAAa;AAAA,QACb,OAAO;AAAA,UACL,EAAE,MAAM,6BAA6B;AAAA,UACrC;AAAA,YACE,MAAM;AAAA,UACR;AAAA,UACA,EAAE,MAAM,sDAAsD;AAAA,UAC9D,EAAE,MAAM,+BAA+B;AAAA,UACvC,EAAE,MAAM,qCAAqC;AAAA,UAC7C;AAAA,YACE,MAAM;AAAA,UACR;AAAA,UACA;AAAA,YACE,MAAM;AAAA,UACR;AAAA,UACA,EAAE,MAAM,uCAAuC;AAAA,QACjD;AAAA,MACF;AAAA,IACF,CAAC;AAAA,EACH;AACJ,EAAuC;;;AGtTvC,IAAAC,uBAAiC;AACjC,sCAAkC;AAOlC,iCAA0C;AAU1C,SAAS,iCAAiC,YAAwB;AAChE,QAAM,aAAS,sDAA0B;AAAA,IACvC,sBAAsB,MAAMC,4BAAiC,UAAU,EAAE;AAAA,IACzE,oBAAoB,CAAC,UACnBC,iCAAsC,UAAU,EAAE,KAAK;AAAA,IACzD,qBAAqB;AAAA,EACvB,CAAC;AAMD,WAAS,gBAAgB,OAAwC;AAC/D,WAAO,OAAO,GAAG,SAAS;AAAA,EAC5B;AAEA,SAAO;AACT;AAEO,IAAMC,2BAGK,2DAAiBA,wBAA6B;AACzD,IAAMF,8BAGK,2DAAiB,gCAAgC;AAE5D,IAAMG,qCAGkC;AAAA,EAC7C;AACF;AAEO,IAAMC,qCAGkC;AAAA,EAC7C;AACF;AAEO,IAAMC,qCAGkC;AAAA,EAC7C;AACF;","names":["getSubscriptionContract","onSubscriptionContractCreated","onSubscriptionContractDeleted","onSubscriptionContractUpdated","querySubscriptionContracts","import_rename_all_nested_keys","import_address","import_float","import_image","import_timestamp","import_transform_paths","import_rest_modules","payload","import_transform_paths","SubscriptionFrequency","DescriptionLineType","ItemTypePreset","PaymentOptionType","JurisdictionType","V2SubscriptionFrequency","AdjustmentType","TaxableAddressType","WeightUnit","ChargeType","VatType","PickupMethod","DiscountType","DiscountReason","ChannelType","AdditionalFeeSource","SortOrder","WebhookIdentityType","getSubscriptionContract","sdkTransformError","querySubscriptionContracts","getSubscriptionContract","querySubscriptionContracts","typedQuerySubscriptionContracts","import_rest_modules","querySubscriptionContracts","typedQuerySubscriptionContracts","getSubscriptionContract","onSubscriptionContractCreated","onSubscriptionContractDeleted","onSubscriptionContractUpdated"]}
|