@wix/auto_sdk_ecom_draft-orders 1.0.79 → 1.0.81

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.
@@ -1,6 +1,6 @@
1
1
  import { HttpClient, NonNullablePaths, EventDefinition, MaybeContext, BuildRESTFunction, BuildEventDefinition } from '@wix/sdk-types';
2
- import { CreateDraftOrderResponse, CreateDraftOrderApplicationErrors, CreateEmptyDraftOrderResponse, CreateEmptyDraftOrderApplicationErrors, AddLineItemsToDraftOrderOptions, AddLineItemsToDraftOrderResponse, AddLineItemsToDraftOrderApplicationErrors, LineItemChangeDetails, UpdateLineItemsResponse, UpdateLineItemsApplicationErrors, IdAndApplied, SetDiscountsResponse, SetDiscountsApplicationErrors, CreateCustomDiscountsOptions, CreateCustomDiscountsResponse, CreateCustomDiscountsApplicationErrors, DeleteCustomDiscountsResponse, DeleteCustomDiscountsApplicationErrors, SetAdditionalFeesResponse, SetAdditionalFeesApplicationErrors, CreateCustomAdditionalFeesOptions, CreateCustomAdditionalFeesResponse, CreateCustomAdditionalFeesApplicationErrors, DeleteCustomAdditionalFeesResponse, DeleteCustomAdditionalFeesApplicationErrors, SetShippingInfoOptions, SetShippingInfoResponse, SetShippingInfoApplicationErrors, SetBuyerInfoOptions, SetBuyerInfoResponse, SetBuyerInfoApplicationErrors, SetRecipientInfoOptions, SetRecipientInfoResponse, SetRecipientInfoApplicationErrors, SetBillingInfoOptions, SetBillingInfoResponse, SetBillingInfoApplicationErrors, GetDraftOrderResponse, GetDraftOrderApplicationErrors, GetOrderDraftabilityStatusResponse, CommitDraftOrderOptions, CommitDraftOrderResponse, CommitDraftOrderApplicationErrors, CreateOrderFromDraftOptions, CreateOrderFromDraftResponse, CreateOrderFromDraftApplicationErrors, DeleteDraftOrderApplicationErrors, DraftOrdersQueryBuilder, UpdateExtendedFieldsOptions, UpdateExtendedFieldsResponse, UpdateExtendedFieldsApplicationErrors, SetTaxExemptionOptions, SetTaxExemptionResponse, SetTaxExemptionApplicationErrors, SetBusinessLocationOptions, SetBusinessLocationResponse, SetBusinessLocationApplicationErrors, DraftOrderCreatedEnvelope, DraftOrderDeletedEnvelope, DraftOrderUpdatedEnvelope } from './index.typings.js';
3
- export { ActionEvent, Activity, ActivityContentOneOf, ActivityType, ActivityTypeWithLiterals, AddLineItemsToDraftOrderRequest, AdditionalFee, AdditionalFeeDetails, AdditionalFeeOption, Address, AddressLocation, AddressWithContact, AdjustmentType, AdjustmentTypeWithLiterals, ApplicationError, AppliedDiscount, AppliedDiscountDiscountSourceOneOf, AppliedDiscountDiscountType, AppliedDiscountDiscountTypeWithLiterals, AttributionSource, AttributionSourceWithLiterals, AuthorizedPaymentCaptured, AuthorizedPaymentCreated, AuthorizedPaymentVoided, Balance, BalanceSummary, BaseEventMetadata, BillingAdjustment, BillingAdjustmentPriceSummary, BillingChangedDetails, BillingDetails, BillingDetailsChangeTypeOneOf, BusinessLocationChangedDetails, BusinessLocationDetails, BusinessLocationDetailsChangeTypeOneOf, BuyerChangedDetails, BuyerDetails, BuyerDetailsChangeTypeOneOf, BuyerInfo, BuyerInfoIdOneOf, CalculatedDraftOrder, CalculationErrors, CalculationErrorsShippingCalculationErrorOneOf, CarrierError, CarrierErrors, CatalogReference, CatalogReferenceLineItem, ChannelInfo, ChannelType, ChannelTypeWithLiterals, ChargebackCreated, ChargebackReversed, Color, CommitDraftOrderRequest, Coupon, CreateCustomAdditionalFeesRequest, CreateCustomDiscountsRequest, CreateDraftOrderRequest, CreateEmptyDraftOrderRequest, CreateOrderFromDraftRequest, CreatedBy, CreatedByStringOneOf, CreditCardDetails, CurrencyConversionDetails, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, CustomActivity, CustomAllowedActions, CustomField, CustomLineItem, DeleteCustomAdditionalFeesRequest, DeleteCustomDiscountsRequest, DeleteDraftOrderRequest, DeleteDraftOrderResponse, DeliveryLogistics, DeliveryTimeSlot, DepositDetails, DepositDetailsDepositOneOf, DescriptionLine, DescriptionLineDescriptionLineValueOneOf, DescriptionLineName, DescriptionLineType, DescriptionLineTypeWithLiterals, DescriptionLineValueOneOf, DescriptionLinesOverride, Details, DetailsKindOneOf, DigitalFile, DiscountDetails, DiscountOption, DiscountOptionDiscountAmountOneOf, DiscountReason, DiscountReasonWithLiterals, DiscountRule, DiscountRuleName, DiscountType, DiscountTypeWithLiterals, DomainEvent, DomainEventBodyOneOf, DraftOrder, DraftOrderChangesApplied, DraftOrderCommitSettings, DraftOrdersQueryResult, EditingStatus, EditingStatusWithLiterals, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, EventMetadata, ExtendedFields, ExternalReceipt, FieldViolation, FileType, FileTypeWithLiterals, FocalPoint, FreeTrialPeriod, FulfillmentStatus, FulfillmentStatusWithLiterals, FulfillmentStatusesAggregate, FullAddressContactDetails, GetDraftOrderRequest, GetOrderDraftabilityStatusRequest, GiftCardPaymentRefund, IdentificationData, IdentificationDataIdOneOf, InventoryUpdate, ItemChangedDetails, ItemDetails, ItemDetailsChangeTypeOneOf, ItemModifier, ItemTaxFullDetails, ItemType, ItemTypeItemTypeDataOneOf, ItemTypePreset, ItemTypePresetWithLiterals, JurisdictionType, JurisdictionTypeWithLiterals, LineItemAmount, LineItemChanges, LineItemDescriptionLineChange, LineItemDiscount, LineItemExchangeData, LineItemModifiersChange, LineItemPriceChange, LineItemProductNameChange, LineItemQuantityChange, LineItemQuantityChangeType, LineItemQuantityChangeTypeWithLiterals, LineItemTaxBreakdown, LineItemTaxInfo, Location, LocationAndQuantity, ManagedAdditionalFee, ManagedDiscount, ManagedLineItem, MembershipPaymentRefund, MerchantComment, MerchantDiscount, MerchantDiscountMerchantDiscountReasonOneOf, MessageEnvelope, ModifierGroup, ModifiersGroupsOverride, NewExchangeOrderCreated, NonDraftableReason, NonDraftableReasonWithLiterals, Order, OrderActionType, OrderActionTypeWithLiterals, OrderActivityTypeEnumActivityType, OrderActivityTypeEnumActivityTypeWithLiterals, OrderChange, OrderChangeValueOneOf, OrderCreateNotifications, OrderCreateSettings, OrderCreatedFromExchange, OrderLineItem, OrderRefunded, OrderSettings, OrderSettingsAllowedActionsOneOf, OrderStatus, OrderStatusWithLiterals, OrderTaxBreakdown, OrderTaxInfo, PaymentCanceled, PaymentCanceledPaymentDetailsOneOf, PaymentDeclined, PaymentDeclinedPaymentDetailsOneOf, PaymentOptionType, PaymentOptionTypeWithLiterals, PaymentPending, PaymentPendingPaymentDetailsOneOf, PaymentRefundFailed, PaymentRefunded, PaymentStatus, PaymentStatusWithLiterals, PhysicalProperties, PickupAddress, PickupDetails, PickupDetailsPickupMethod, PickupDetailsPickupMethodWithLiterals, PickupMethod, PickupMethodWithLiterals, PlainTextValue, Price, PriceDescription, PriceSummary, ProductName, QueryDraftOrdersRequest, QueryDraftOrdersResponse, ReceiptCreated, ReceiptCreatedReceiptInfoOneOf, ReceiptSent, ReceiptSentReceiptInfoOneOf, RecipientInfoChangedDetails, RecipientInfoDetails, RecipientInfoDetailsChangeTypeOneOf, RefundInitiated, RefundedAsStoreCredit, RefundedPayment, RefundedPaymentKindOneOf, RegularPayment, RegularPaymentPaymentMethodDetailsOneOf, RegularPaymentRefund, RestoreInfo, RuleType, RuleTypeWithLiterals, SavedPaymentMethod, SecuredMedia, SetAdditionalFeesRequest, SetBillingInfoRequest, SetBusinessLocationRequest, SetBuyerInfoRequest, SetDepositApplicationErrors, SetDepositOptions, SetDepositRequest, SetDepositResponse, SetDiscountsRequest, SetRecipientInfoRequest, SetShippingInfoRequest, SetTaxExemptionRequest, ShippingChangedDetails, ShippingDetails, ShippingDetailsChangeTypeOneOf, ShippingInformation, ShippingInformationChange, ShippingOption, ShippingPrice, ShippingRegion, SortOrder, SortOrderWithLiterals, Sorting, SourceType, SourceTypeWithLiterals, StreetAddress, SubscriptionDescription, SubscriptionFrequency, SubscriptionFrequencyWithLiterals, SubscriptionInfo, SubscriptionSettings, SubscriptionTitle, SystemError, TagList, Tags, TaxDetails, TaxSummary, TaxableAddress, TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, TaxableAddressTypeWithLiterals, TotalPriceChange, TranslatableString, TranslatedValue, UpdateExtendedFieldsRequest, UpdateLineItemsRequest, UpdateShippingInfoRequest, UpdateShippingInfoResponse, V1BalanceSummary, V1CreatedBy, V1CreatedByStringOneOf, V1DeliveryLogistics, V1DeliveryLogisticsAddressOneOf, V1DeliveryTimeSlot, V1PickupDetails, V1ShippingInformation, V1ShippingPrice, ValidationError, VatId, VatType, VatTypeWithLiterals, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WeightUnit, WeightUnitWithLiterals, WixReceipt } from './index.typings.js';
2
+ import { CreateDraftOrderResponse, CreateDraftOrderApplicationErrors, CreateEmptyDraftOrderResponse, CreateEmptyDraftOrderApplicationErrors, AddLineItemsToDraftOrderOptions, AddLineItemsToDraftOrderResponse, AddLineItemsToDraftOrderApplicationErrors, LineItemChangeDetails, UpdateLineItemsResponse, UpdateLineItemsApplicationErrors, IdAndApplied, SetDiscountsResponse, SetDiscountsApplicationErrors, CreateCustomDiscountsOptions, CreateCustomDiscountsResponse, CreateCustomDiscountsApplicationErrors, DeleteCustomDiscountsResponse, DeleteCustomDiscountsApplicationErrors, SetAdditionalFeesResponse, SetAdditionalFeesApplicationErrors, CreateCustomAdditionalFeesOptions, CreateCustomAdditionalFeesResponse, CreateCustomAdditionalFeesApplicationErrors, DeleteCustomAdditionalFeesResponse, DeleteCustomAdditionalFeesApplicationErrors, SetShippingInfoOptions, SetShippingInfoResponse, SetShippingInfoApplicationErrors, SetBuyerInfoOptions, SetBuyerInfoResponse, SetBuyerInfoApplicationErrors, SetRecipientInfoOptions, SetRecipientInfoResponse, SetRecipientInfoApplicationErrors, SetBillingInfoOptions, SetBillingInfoResponse, SetBillingInfoApplicationErrors, GetDraftOrderResponse, GetDraftOrderApplicationErrors, GetOrderDraftabilityStatusResponse, CommitDraftOrderOptions, CommitDraftOrderResponse, CommitDraftOrderApplicationErrors, CreateOrderFromDraftOptions, CreateOrderFromDraftResponse, CreateOrderFromDraftApplicationErrors, DeleteDraftOrderApplicationErrors, UpdateExtendedFieldsOptions, UpdateExtendedFieldsResponse, UpdateExtendedFieldsApplicationErrors, SetTaxExemptionOptions, SetTaxExemptionResponse, SetTaxExemptionApplicationErrors, SetBusinessLocationOptions, SetBusinessLocationResponse, SetBusinessLocationApplicationErrors, DraftOrderCreatedEnvelope, DraftOrderDeletedEnvelope, DraftOrderUpdatedEnvelope, DraftOrdersQueryBuilder, CursorQuery, typedQueryDraftOrders } from './index.typings.js';
3
+ export { ActionEvent, Activity, ActivityContentOneOf, ActivityType, ActivityTypeWithLiterals, AddLineItemsToDraftOrderRequest, AdditionalFee, AdditionalFeeDetails, AdditionalFeeOption, Address, AddressLocation, AddressWithContact, AdjustmentType, AdjustmentTypeWithLiterals, ApplicationError, AppliedDiscount, AppliedDiscountDiscountSourceOneOf, AppliedDiscountDiscountType, AppliedDiscountDiscountTypeWithLiterals, AttributionSource, AttributionSourceWithLiterals, AuthorizedPaymentCaptured, AuthorizedPaymentCreated, AuthorizedPaymentVoided, Balance, BalanceSummary, BaseEventMetadata, BillingAdjustment, BillingAdjustmentPriceSummary, BillingChangedDetails, BillingDetails, BillingDetailsChangeTypeOneOf, BusinessLocationChangedDetails, BusinessLocationDetails, BusinessLocationDetailsChangeTypeOneOf, BuyerChangedDetails, BuyerDetails, BuyerDetailsChangeTypeOneOf, BuyerInfo, BuyerInfoIdOneOf, CalculatedDraftOrder, CalculationErrors, CalculationErrorsShippingCalculationErrorOneOf, CarrierError, CarrierErrors, CatalogReference, CatalogReferenceLineItem, ChannelInfo, ChannelType, ChannelTypeWithLiterals, ChargebackCreated, ChargebackReversed, Color, CommitDraftOrderRequest, Coupon, CreateCustomAdditionalFeesRequest, CreateCustomDiscountsRequest, CreateDraftOrderRequest, CreateEmptyDraftOrderRequest, CreateOrderFromDraftRequest, CreatedBy, CreatedByStringOneOf, CreditCardDetails, CurrencyConversionDetails, CursorPaging, CursorPagingMetadata, CursorQueryPagingMethodOneOf, Cursors, CustomActivity, CustomAllowedActions, CustomField, CustomLineItem, DeleteCustomAdditionalFeesRequest, DeleteCustomDiscountsRequest, DeleteDraftOrderRequest, DeleteDraftOrderResponse, DeliveryLogistics, DeliveryTimeSlot, DepositDetails, DepositDetailsDepositOneOf, DescriptionLine, DescriptionLineDescriptionLineValueOneOf, DescriptionLineName, DescriptionLineType, DescriptionLineTypeWithLiterals, DescriptionLineValueOneOf, DescriptionLinesOverride, Details, DetailsKindOneOf, DigitalFile, DiscountDetails, DiscountOption, DiscountOptionDiscountAmountOneOf, DiscountReason, DiscountReasonWithLiterals, DiscountRule, DiscountRuleName, DiscountType, DiscountTypeWithLiterals, DomainEvent, DomainEventBodyOneOf, DraftOrder, DraftOrderChangesApplied, DraftOrderCommitSettings, DraftOrdersQueryResult, EditingStatus, EditingStatusWithLiterals, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, EventMetadata, ExtendedFields, ExternalReceipt, FieldViolation, FileType, FileTypeWithLiterals, FocalPoint, FreeTrialPeriod, FulfillmentStatus, FulfillmentStatusWithLiterals, FulfillmentStatusesAggregate, FullAddressContactDetails, GetDraftOrderRequest, GetOrderDraftabilityStatusRequest, GiftCardPaymentRefund, IdentificationData, IdentificationDataIdOneOf, InventoryUpdate, ItemChangedDetails, ItemDetails, ItemDetailsChangeTypeOneOf, ItemModifier, ItemTaxFullDetails, ItemType, ItemTypeItemTypeDataOneOf, ItemTypePreset, ItemTypePresetWithLiterals, JurisdictionType, JurisdictionTypeWithLiterals, LineItemAmount, LineItemChanges, LineItemDescriptionLineChange, LineItemDiscount, LineItemExchangeData, LineItemModifiersChange, LineItemPriceChange, LineItemProductNameChange, LineItemQuantityChange, LineItemQuantityChangeType, LineItemQuantityChangeTypeWithLiterals, LineItemTaxBreakdown, LineItemTaxInfo, Location, LocationAndQuantity, ManagedAdditionalFee, ManagedDiscount, ManagedLineItem, MembershipPaymentRefund, MerchantComment, MerchantDiscount, MerchantDiscountMerchantDiscountReasonOneOf, MessageEnvelope, ModifierGroup, ModifiersGroupsOverride, NewExchangeOrderCreated, NonDraftableReason, NonDraftableReasonWithLiterals, Order, OrderActionType, OrderActionTypeWithLiterals, OrderActivityTypeEnumActivityType, OrderActivityTypeEnumActivityTypeWithLiterals, OrderChange, OrderChangeValueOneOf, OrderCreateNotifications, OrderCreateSettings, OrderCreatedFromExchange, OrderLineItem, OrderRefunded, OrderSettings, OrderSettingsAllowedActionsOneOf, OrderStatus, OrderStatusWithLiterals, OrderTaxBreakdown, OrderTaxInfo, PaymentCanceled, PaymentCanceledPaymentDetailsOneOf, PaymentDeclined, PaymentDeclinedPaymentDetailsOneOf, PaymentOptionType, PaymentOptionTypeWithLiterals, PaymentPending, PaymentPendingPaymentDetailsOneOf, PaymentRefundFailed, PaymentRefunded, PaymentStatus, PaymentStatusWithLiterals, PhysicalProperties, PickupAddress, PickupDetails, PickupDetailsPickupMethod, PickupDetailsPickupMethodWithLiterals, PickupMethod, PickupMethodWithLiterals, PlainTextValue, Price, PriceDescription, PriceSummary, ProductName, QueryDraftOrdersRequest, QueryDraftOrdersResponse, ReceiptCreated, ReceiptCreatedReceiptInfoOneOf, ReceiptSent, ReceiptSentReceiptInfoOneOf, RecipientInfoChangedDetails, RecipientInfoDetails, RecipientInfoDetailsChangeTypeOneOf, RefundInitiated, RefundedAsStoreCredit, RefundedPayment, RefundedPaymentKindOneOf, RegularPayment, RegularPaymentPaymentMethodDetailsOneOf, RegularPaymentRefund, RestoreInfo, RuleType, RuleTypeWithLiterals, SavedPaymentMethod, SecuredMedia, SetAdditionalFeesRequest, SetBillingInfoRequest, SetBusinessLocationRequest, SetBuyerInfoRequest, SetDepositApplicationErrors, SetDepositOptions, SetDepositRequest, SetDepositResponse, SetDiscountsRequest, SetRecipientInfoRequest, SetShippingInfoRequest, SetTaxExemptionRequest, ShippingChangedDetails, ShippingDetails, ShippingDetailsChangeTypeOneOf, ShippingInformation, ShippingInformationChange, ShippingOption, ShippingPrice, ShippingRegion, SortOrder, SortOrderWithLiterals, Sorting, SourceType, SourceTypeWithLiterals, StreetAddress, SubscriptionDescription, SubscriptionFrequency, SubscriptionFrequencyWithLiterals, SubscriptionInfo, SubscriptionSettings, SubscriptionTitle, SystemError, TagList, Tags, TaxDetails, TaxSummary, TaxableAddress, TaxableAddressTaxableAddressDataOneOf, TaxableAddressType, TaxableAddressTypeWithLiterals, TotalPriceChange, TranslatableString, TranslatedValue, UpdateExtendedFieldsRequest, UpdateLineItemsRequest, UpdateShippingInfoRequest, UpdateShippingInfoResponse, V1BalanceSummary, V1CreatedBy, V1CreatedByStringOneOf, V1DeliveryLogistics, V1DeliveryLogisticsAddressOneOf, V1DeliveryTimeSlot, V1PickupDetails, V1ShippingInformation, V1ShippingPrice, ValidationError, VatId, VatType, VatTypeWithLiterals, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WeightUnit, WeightUnitWithLiterals, WixReceipt } from './index.typings.js';
4
4
 
5
5
  declare function createDraftOrder$1(httpClient: HttpClient): CreateDraftOrderSignature;
6
6
  interface CreateDraftOrderSignature {
@@ -245,16 +245,6 @@ interface DeleteDraftOrderSignature {
245
245
  __applicationErrorsType?: DeleteDraftOrderApplicationErrors;
246
246
  }>;
247
247
  }
248
- declare function queryDraftOrders$1(httpClient: HttpClient): QueryDraftOrdersSignature;
249
- interface QueryDraftOrdersSignature {
250
- /**
251
- * Retrieves a list of up to 100 draft orders, given the provided paging, filtering, and sorting.
252
- *
253
- * For field support, see [supported filters and sorting](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/draft-orders/supported-filters-and-sorting).
254
- * To learn how to query draft orders, see [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).
255
- */
256
- (): DraftOrdersQueryBuilder;
257
- }
258
248
  declare function updateExtendedFields$1(httpClient: HttpClient): UpdateExtendedFieldsSignature;
259
249
  interface UpdateExtendedFieldsSignature {
260
250
  /**
@@ -294,6 +284,10 @@ declare const onDraftOrderCreated$1: EventDefinition<DraftOrderCreatedEnvelope,
294
284
  declare const onDraftOrderDeleted$1: EventDefinition<DraftOrderDeletedEnvelope, "wix.ecom.v1.draft_order_deleted">;
295
285
  declare const onDraftOrderUpdated$1: EventDefinition<DraftOrderUpdatedEnvelope, "wix.ecom.v1.draft_order_updated">;
296
286
 
287
+ declare function customQueryDraftOrders(httpClient: HttpClient): {
288
+ (): DraftOrdersQueryBuilder;
289
+ (query: CursorQuery): ReturnType<typeof typedQueryDraftOrders>;
290
+ };
297
291
  declare const createDraftOrder: MaybeContext<BuildRESTFunction<typeof createDraftOrder$1> & typeof createDraftOrder$1>;
298
292
  declare const createEmptyDraftOrder: MaybeContext<BuildRESTFunction<typeof createEmptyDraftOrder$1> & typeof createEmptyDraftOrder$1>;
299
293
  declare const addLineItemsToDraftOrder: MaybeContext<BuildRESTFunction<typeof addLineItemsToDraftOrder$1> & typeof addLineItemsToDraftOrder$1>;
@@ -313,10 +307,10 @@ declare const getOrderDraftabilityStatus: MaybeContext<BuildRESTFunction<typeof
313
307
  declare const commitDraftOrder: MaybeContext<BuildRESTFunction<typeof commitDraftOrder$1> & typeof commitDraftOrder$1>;
314
308
  declare const createOrderFromDraft: MaybeContext<BuildRESTFunction<typeof createOrderFromDraft$1> & typeof createOrderFromDraft$1>;
315
309
  declare const deleteDraftOrder: MaybeContext<BuildRESTFunction<typeof deleteDraftOrder$1> & typeof deleteDraftOrder$1>;
316
- declare const queryDraftOrders: MaybeContext<BuildRESTFunction<typeof queryDraftOrders$1> & typeof queryDraftOrders$1>;
317
310
  declare const updateExtendedFields: MaybeContext<BuildRESTFunction<typeof updateExtendedFields$1> & typeof updateExtendedFields$1>;
318
311
  declare const setTaxExemption: MaybeContext<BuildRESTFunction<typeof setTaxExemption$1> & typeof setTaxExemption$1>;
319
312
  declare const setBusinessLocation: MaybeContext<BuildRESTFunction<typeof setBusinessLocation$1> & typeof setBusinessLocation$1>;
313
+ declare const queryDraftOrders: MaybeContext<BuildRESTFunction<typeof customQueryDraftOrders> & typeof customQueryDraftOrders>;
320
314
  /**
321
315
  * Triggered when a draft order is created.
322
316
  */
@@ -330,4 +324,4 @@ declare const onDraftOrderDeleted: BuildEventDefinition<typeof onDraftOrderDelet
330
324
  */
331
325
  declare const onDraftOrderUpdated: BuildEventDefinition<typeof onDraftOrderUpdated$1> & typeof onDraftOrderUpdated$1;
332
326
 
333
- export { AddLineItemsToDraftOrderApplicationErrors, AddLineItemsToDraftOrderOptions, AddLineItemsToDraftOrderResponse, CommitDraftOrderApplicationErrors, CommitDraftOrderOptions, CommitDraftOrderResponse, CreateCustomAdditionalFeesApplicationErrors, CreateCustomAdditionalFeesOptions, CreateCustomAdditionalFeesResponse, CreateCustomDiscountsApplicationErrors, CreateCustomDiscountsOptions, CreateCustomDiscountsResponse, CreateDraftOrderApplicationErrors, CreateDraftOrderResponse, CreateEmptyDraftOrderApplicationErrors, CreateEmptyDraftOrderResponse, CreateOrderFromDraftApplicationErrors, CreateOrderFromDraftOptions, CreateOrderFromDraftResponse, DeleteCustomAdditionalFeesApplicationErrors, DeleteCustomAdditionalFeesResponse, DeleteCustomDiscountsApplicationErrors, DeleteCustomDiscountsResponse, DeleteDraftOrderApplicationErrors, DraftOrderCreatedEnvelope, DraftOrderDeletedEnvelope, DraftOrderUpdatedEnvelope, DraftOrdersQueryBuilder, GetDraftOrderApplicationErrors, GetDraftOrderResponse, GetOrderDraftabilityStatusResponse, IdAndApplied, LineItemChangeDetails, SetAdditionalFeesApplicationErrors, SetAdditionalFeesResponse, SetBillingInfoApplicationErrors, SetBillingInfoOptions, SetBillingInfoResponse, SetBusinessLocationApplicationErrors, SetBusinessLocationOptions, SetBusinessLocationResponse, SetBuyerInfoApplicationErrors, SetBuyerInfoOptions, SetBuyerInfoResponse, SetDiscountsApplicationErrors, SetDiscountsResponse, SetRecipientInfoApplicationErrors, SetRecipientInfoOptions, SetRecipientInfoResponse, SetShippingInfoApplicationErrors, SetShippingInfoOptions, SetShippingInfoResponse, SetTaxExemptionApplicationErrors, SetTaxExemptionOptions, SetTaxExemptionResponse, UpdateExtendedFieldsApplicationErrors, UpdateExtendedFieldsOptions, UpdateExtendedFieldsResponse, UpdateLineItemsApplicationErrors, UpdateLineItemsResponse, addLineItemsToDraftOrder, commitDraftOrder, createCustomAdditionalFees, createCustomDiscounts, createDraftOrder, createEmptyDraftOrder, createOrderFromDraft, deleteCustomAdditionalFees, deleteCustomDiscounts, deleteDraftOrder, getDraftOrder, getOrderDraftabilityStatus, onDraftOrderCreated, onDraftOrderDeleted, onDraftOrderUpdated, queryDraftOrders, setAdditionalFees, setBillingInfo, setBusinessLocation, setBuyerInfo, setDiscounts, setRecipientInfo, setShippingInfo, setTaxExemption, updateExtendedFields, updateLineItems };
327
+ export { AddLineItemsToDraftOrderApplicationErrors, AddLineItemsToDraftOrderOptions, AddLineItemsToDraftOrderResponse, CommitDraftOrderApplicationErrors, CommitDraftOrderOptions, CommitDraftOrderResponse, CreateCustomAdditionalFeesApplicationErrors, CreateCustomAdditionalFeesOptions, CreateCustomAdditionalFeesResponse, CreateCustomDiscountsApplicationErrors, CreateCustomDiscountsOptions, CreateCustomDiscountsResponse, CreateDraftOrderApplicationErrors, CreateDraftOrderResponse, CreateEmptyDraftOrderApplicationErrors, CreateEmptyDraftOrderResponse, CreateOrderFromDraftApplicationErrors, CreateOrderFromDraftOptions, CreateOrderFromDraftResponse, CursorQuery, DeleteCustomAdditionalFeesApplicationErrors, DeleteCustomAdditionalFeesResponse, DeleteCustomDiscountsApplicationErrors, DeleteCustomDiscountsResponse, DeleteDraftOrderApplicationErrors, DraftOrderCreatedEnvelope, DraftOrderDeletedEnvelope, DraftOrderUpdatedEnvelope, DraftOrdersQueryBuilder, GetDraftOrderApplicationErrors, GetDraftOrderResponse, GetOrderDraftabilityStatusResponse, IdAndApplied, LineItemChangeDetails, SetAdditionalFeesApplicationErrors, SetAdditionalFeesResponse, SetBillingInfoApplicationErrors, SetBillingInfoOptions, SetBillingInfoResponse, SetBusinessLocationApplicationErrors, SetBusinessLocationOptions, SetBusinessLocationResponse, SetBuyerInfoApplicationErrors, SetBuyerInfoOptions, SetBuyerInfoResponse, SetDiscountsApplicationErrors, SetDiscountsResponse, SetRecipientInfoApplicationErrors, SetRecipientInfoOptions, SetRecipientInfoResponse, SetShippingInfoApplicationErrors, SetShippingInfoOptions, SetShippingInfoResponse, SetTaxExemptionApplicationErrors, SetTaxExemptionOptions, SetTaxExemptionResponse, UpdateExtendedFieldsApplicationErrors, UpdateExtendedFieldsOptions, UpdateExtendedFieldsResponse, UpdateLineItemsApplicationErrors, UpdateLineItemsResponse, addLineItemsToDraftOrder, commitDraftOrder, createCustomAdditionalFees, createCustomDiscounts, createDraftOrder, createEmptyDraftOrder, createOrderFromDraft, deleteCustomAdditionalFees, deleteCustomDiscounts, deleteDraftOrder, getDraftOrder, getOrderDraftabilityStatus, onDraftOrderCreated, onDraftOrderDeleted, onDraftOrderUpdated, queryDraftOrders, setAdditionalFees, setBillingInfo, setBusinessLocation, setBuyerInfo, setDiscounts, setRecipientInfo, setShippingInfo, setTaxExemption, updateExtendedFields, updateLineItems };
@@ -5073,6 +5073,62 @@ function queryDraftOrders2() {
5073
5073
  transformationPaths: {}
5074
5074
  });
5075
5075
  }
5076
+ async function typedQueryDraftOrders(query) {
5077
+ const { httpClient, sideEffects } = arguments[1];
5078
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ query });
5079
+ const reqOpts = queryDraftOrders(payload);
5080
+ sideEffects?.onSiteCall?.();
5081
+ try {
5082
+ const result = await httpClient.request(reqOpts);
5083
+ sideEffects?.onSuccess?.(result);
5084
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
5085
+ (0, import_transform_paths2.transformPaths)(result.data, [
5086
+ {
5087
+ transformFn: import_image2.transformRESTImageToSDKImage,
5088
+ paths: [{ path: "draftOrders.lineItems.lineItem.image" }]
5089
+ },
5090
+ {
5091
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
5092
+ paths: [
5093
+ {
5094
+ path: "draftOrders.shippingInfo.changedDetails.shippingInfoBeforeChange.logistics.shippingDestination.address"
5095
+ },
5096
+ {
5097
+ path: "draftOrders.shippingInfo.changedDetails.shippingInfoBeforeChange.logistics.pickupDetails.address"
5098
+ },
5099
+ {
5100
+ path: "draftOrders.shippingInfo.shippingInfo.logistics.shippingDestination.address"
5101
+ },
5102
+ {
5103
+ path: "draftOrders.shippingInfo.shippingInfo.logistics.pickupDetails.address"
5104
+ },
5105
+ { path: "draftOrders.billingInfo.address" },
5106
+ {
5107
+ path: "draftOrders.recipientInfo.changedDetails.recipientInfoBeforeChange.address"
5108
+ },
5109
+ { path: "draftOrders.recipientInfo.recipientInfo.address" },
5110
+ {
5111
+ path: "draftOrders.billingDetails.changedDetails.billingInfoBeforeChange.address"
5112
+ },
5113
+ { path: "draftOrders.billingDetails.billingInfo.address" }
5114
+ ]
5115
+ }
5116
+ ])
5117
+ );
5118
+ } catch (err) {
5119
+ const transformedError = (0, import_transform_error.transformError)(
5120
+ err,
5121
+ {
5122
+ spreadPathsToArguments: {},
5123
+ explicitPathsToArguments: { query: "$[0]" },
5124
+ singleArgumentUnchanged: false
5125
+ },
5126
+ ["query"]
5127
+ );
5128
+ sideEffects?.onError?.(err);
5129
+ throw transformedError;
5130
+ }
5131
+ }
5076
5132
  async function updateExtendedFields2(_id, namespace, options) {
5077
5133
  const { httpClient, sideEffects } = arguments[3];
5078
5134
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
@@ -5445,6 +5501,13 @@ function queryDraftOrders3(httpClient) {
5445
5501
  { httpClient }
5446
5502
  );
5447
5503
  }
5504
+ function typedQueryDraftOrders2(httpClient) {
5505
+ return (query) => typedQueryDraftOrders(
5506
+ query,
5507
+ // @ts-ignore
5508
+ { httpClient }
5509
+ );
5510
+ }
5448
5511
  function updateExtendedFields3(httpClient) {
5449
5512
  return (_id, namespace, options) => updateExtendedFields2(
5450
5513
  _id,
@@ -5696,6 +5759,18 @@ var onDraftOrderUpdated = (0, import_sdk_types.EventDefinition)(
5696
5759
  // src/ecom-v1-draft-order-draft-orders.context.ts
5697
5760
  var import_rest_modules3 = require("@wix/sdk-runtime/rest-modules");
5698
5761
  var import_event_definition_modules = require("@wix/sdk-runtime/event-definition-modules");
5762
+ var import_query_method_router = require("@wix/sdk-runtime/query-method-router");
5763
+ function customQueryDraftOrders(httpClient) {
5764
+ const router = (0, import_query_method_router.createQueryOverloadRouter)({
5765
+ builderQueryFunction: () => queryDraftOrders3(httpClient)(),
5766
+ typedQueryFunction: (query) => typedQueryDraftOrders2(httpClient)(query),
5767
+ hasOptionsParameter: false
5768
+ });
5769
+ function overloadedQuery(query) {
5770
+ return router(...arguments);
5771
+ }
5772
+ return overloadedQuery;
5773
+ }
5699
5774
  var createDraftOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createDraftOrder3);
5700
5775
  var createEmptyDraftOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createEmptyDraftOrder3);
5701
5776
  var addLineItemsToDraftOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(addLineItemsToDraftOrder3);
@@ -5716,10 +5791,10 @@ var getOrderDraftabilityStatus4 = /* @__PURE__ */ (0, import_rest_modules3.creat
5716
5791
  var commitDraftOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(commitDraftOrder3);
5717
5792
  var createOrderFromDraft4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createOrderFromDraft3);
5718
5793
  var deleteDraftOrder4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteDraftOrder3);
5719
- var queryDraftOrders4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(queryDraftOrders3);
5720
5794
  var updateExtendedFields4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateExtendedFields3);
5721
5795
  var setTaxExemption4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(setTaxExemption3);
5722
5796
  var setBusinessLocation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(setBusinessLocation3);
5797
+ var queryDraftOrders4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customQueryDraftOrders);
5723
5798
  var onDraftOrderCreated2 = (0, import_event_definition_modules.createEventModule)(
5724
5799
  onDraftOrderCreated
5725
5800
  );