@wix/auto_sdk_ecom_local-delivery-options 1.0.28 → 1.0.30

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.
@@ -831,6 +831,12 @@ interface LocalDeliveryOptionsQueryBuilder {
831
831
  /** @documentationMaturity preview */
832
832
  find: () => Promise<LocalDeliveryOptionsQueryResult>;
833
833
  }
834
+ /**
835
+ * @hidden
836
+ * @fqn com.wix.ecom.shipments.localdelivery.LocalDelivery.QueryLocalDeliveryOptions
837
+ * @requiredField query
838
+ */
839
+ declare function typedQueryLocalDeliveryOptions(query: QueryV2): Promise<NonNullablePaths<QueryLocalDeliveryOptionsResponse, `localDeliveryOptions` | `localDeliveryOptions.${number}.radiusConfig.radius` | `localDeliveryOptions.${number}.radiusConfig.lengthUnit`, 5>>;
834
840
  /** @param _id - LocalDeliveryOptionId - unique identifier of local delivery option
835
841
  * @public
836
842
  * @documentationMaturity preview
@@ -1153,4 +1159,4 @@ interface RemoveDeliveryRegionOptions {
1153
1159
  revision?: string | null;
1154
1160
  }
1155
1161
 
1156
- export { type ActionEvent, type AddDeliveryRegionOptions, type AddDeliveryRegionRequest, type AddDeliveryRegionResponse, type AddressLocation, type BulkCreateLocalDeliveryOptionApplicationErrors, type BulkCreateLocalDeliveryOptionRequest, type BulkCreateLocalDeliveryOptionResponse, type BulkDeleteLocalDeliveryOptionRequest, type BulkDeleteLocalDeliveryOptionResponse, type BulkUpdateLocalDeliveryOptionRequest, type BulkUpdateLocalDeliveryOptionResponse, type Condition, ConditionType, type ConditionTypeWithLiterals, type ConditionalRates, type CreateLocalDeliveryOptionApplicationErrors, type CreateLocalDeliveryOptionRequest, type CreateLocalDeliveryOptionResponse, type CursorPaging, type CursorPagingMetadata, type Cursors, type CustomAreaConfig, DayOfWeek, type DayOfWeekWithLiterals, type DaySlot, type Days, type DeleteLocalDeliveryOptionOptions, type DeleteLocalDeliveryOptionRequest, type DeleteLocalDeliveryOptionResponse, type Destination, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type GetLocalDeliveryOptionOptions, type GetLocalDeliveryOptionRequest, type GetLocalDeliveryOptionResponse, type IdentificationData, type IdentificationDataIdOneOf, LengthUnit, type LengthUnitWithLiterals, type ListLocalDeliveryOptionsRequest, type ListLocalDeliveryOptionsResponse, type LocalDeliveryAddress, type LocalDeliveryOption, type LocalDeliveryOptionConfigOneOf, type LocalDeliveryOptionError, type LocalDeliveryOptionsQueryBuilder, type LocalDeliveryOptionsQueryResult, LogicalOperator, type LogicalOperatorWithLiterals, type MessageEnvelope, type Paging, type QueryLocalDeliveryOptionsRequest, type QueryLocalDeliveryOptionsResponse, type QueryV2, type QueryV2PagingMethodOneOf, type RadiusConfig, type RemoveDeliveryRegionOptions, type RemoveDeliveryRegionRequest, type RemoveDeliveryRegionResponse, type RestoreInfo, type ScheduledDelivery, SortOrder, type SortOrderWithLiterals, type Sorting, type TimeOfDay, type TimePoint, type TimeSlot, type TimeWindow, type UpdateLocalDeliveryOption, type UpdateLocalDeliveryOptionRequest, type UpdateLocalDeliveryOptionResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, type ZipCodeConfig, addDeliveryRegion, bulkCreateLocalDeliveryOption, bulkDeleteLocalDeliveryOption, bulkUpdateLocalDeliveryOption, createLocalDeliveryOption, deleteLocalDeliveryOption, getLocalDeliveryOption, listLocalDeliveryOptions, queryLocalDeliveryOptions, removeDeliveryRegion, updateLocalDeliveryOption };
1162
+ export { type ActionEvent, type AddDeliveryRegionOptions, type AddDeliveryRegionRequest, type AddDeliveryRegionResponse, type AddressLocation, type BulkCreateLocalDeliveryOptionApplicationErrors, type BulkCreateLocalDeliveryOptionRequest, type BulkCreateLocalDeliveryOptionResponse, type BulkDeleteLocalDeliveryOptionRequest, type BulkDeleteLocalDeliveryOptionResponse, type BulkUpdateLocalDeliveryOptionRequest, type BulkUpdateLocalDeliveryOptionResponse, type Condition, ConditionType, type ConditionTypeWithLiterals, type ConditionalRates, type CreateLocalDeliveryOptionApplicationErrors, type CreateLocalDeliveryOptionRequest, type CreateLocalDeliveryOptionResponse, type CursorPaging, type CursorPagingMetadata, type Cursors, type CustomAreaConfig, DayOfWeek, type DayOfWeekWithLiterals, type DaySlot, type Days, type DeleteLocalDeliveryOptionOptions, type DeleteLocalDeliveryOptionRequest, type DeleteLocalDeliveryOptionResponse, type Destination, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type GetLocalDeliveryOptionOptions, type GetLocalDeliveryOptionRequest, type GetLocalDeliveryOptionResponse, type IdentificationData, type IdentificationDataIdOneOf, LengthUnit, type LengthUnitWithLiterals, type ListLocalDeliveryOptionsRequest, type ListLocalDeliveryOptionsResponse, type LocalDeliveryAddress, type LocalDeliveryOption, type LocalDeliveryOptionConfigOneOf, type LocalDeliveryOptionError, type LocalDeliveryOptionsQueryBuilder, type LocalDeliveryOptionsQueryResult, LogicalOperator, type LogicalOperatorWithLiterals, type MessageEnvelope, type Paging, type QueryLocalDeliveryOptionsRequest, type QueryLocalDeliveryOptionsResponse, type QueryV2, type QueryV2PagingMethodOneOf, type RadiusConfig, type RemoveDeliveryRegionOptions, type RemoveDeliveryRegionRequest, type RemoveDeliveryRegionResponse, type RestoreInfo, type ScheduledDelivery, SortOrder, type SortOrderWithLiterals, type Sorting, type TimeOfDay, type TimePoint, type TimeSlot, type TimeWindow, type UpdateLocalDeliveryOption, type UpdateLocalDeliveryOptionRequest, type UpdateLocalDeliveryOptionResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, type ZipCodeConfig, addDeliveryRegion, bulkCreateLocalDeliveryOption, bulkDeleteLocalDeliveryOption, bulkUpdateLocalDeliveryOption, createLocalDeliveryOption, deleteLocalDeliveryOption, getLocalDeliveryOption, listLocalDeliveryOptions, queryLocalDeliveryOptions, removeDeliveryRegion, typedQueryLocalDeliveryOptions, updateLocalDeliveryOption };
@@ -36,6 +36,7 @@ __export(index_typings_exports, {
36
36
  listLocalDeliveryOptions: () => listLocalDeliveryOptions2,
37
37
  queryLocalDeliveryOptions: () => queryLocalDeliveryOptions2,
38
38
  removeDeliveryRegion: () => removeDeliveryRegion2,
39
+ typedQueryLocalDeliveryOptions: () => typedQueryLocalDeliveryOptions,
39
40
  updateLocalDeliveryOption: () => updateLocalDeliveryOption2
40
41
  });
41
42
  module.exports = __toCommonJS(index_typings_exports);
@@ -884,6 +885,36 @@ function queryLocalDeliveryOptions2() {
884
885
  transformationPaths: {}
885
886
  });
886
887
  }
888
+ async function typedQueryLocalDeliveryOptions(query) {
889
+ const { httpClient, sideEffects } = arguments[1];
890
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ query });
891
+ const reqOpts = queryLocalDeliveryOptions(payload);
892
+ sideEffects?.onSiteCall?.();
893
+ try {
894
+ const result = await httpClient.request(reqOpts);
895
+ sideEffects?.onSuccess?.(result);
896
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
897
+ (0, import_transform_paths2.transformPaths)(result.data, [
898
+ {
899
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
900
+ paths: [{ path: "localDeliveryOptions.radiusConfig.address" }]
901
+ }
902
+ ])
903
+ );
904
+ } catch (err) {
905
+ const transformedError = (0, import_transform_error.transformError)(
906
+ err,
907
+ {
908
+ spreadPathsToArguments: {},
909
+ explicitPathsToArguments: { query: "$[0]" },
910
+ singleArgumentUnchanged: false
911
+ },
912
+ ["query"]
913
+ );
914
+ sideEffects?.onError?.(err);
915
+ throw transformedError;
916
+ }
917
+ }
887
918
  async function updateLocalDeliveryOption2(_id, localDeliveryOption) {
888
919
  const { httpClient, sideEffects } = arguments[2];
889
920
  const payload = (0, import_transform_paths2.transformPaths)(
@@ -1154,6 +1185,7 @@ async function removeDeliveryRegion2(deliveryRegionId, options) {
1154
1185
  listLocalDeliveryOptions,
1155
1186
  queryLocalDeliveryOptions,
1156
1187
  removeDeliveryRegion,
1188
+ typedQueryLocalDeliveryOptions,
1157
1189
  updateLocalDeliveryOption
1158
1190
  });
1159
1191
  //# sourceMappingURL=index.typings.js.map