@wix/auto_sdk_ecom_delivery-profile 1.0.75 → 1.0.76
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.d.ts +11 -3
- package/build/cjs/index.js +55 -0
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +51 -1
- package/build/cjs/index.typings.js +48 -0
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +44 -2
- package/build/cjs/meta.js +43 -0
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +11 -3
- package/build/es/index.mjs +54 -0
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +51 -1
- package/build/es/index.typings.mjs +47 -0
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +44 -2
- package/build/es/meta.mjs +42 -0
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +11 -3
- package/build/internal/cjs/index.js +55 -0
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +51 -1
- package/build/internal/cjs/index.typings.js +48 -0
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +44 -2
- package/build/internal/cjs/meta.js +43 -0
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +11 -3
- package/build/internal/es/index.mjs +54 -0
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +51 -1
- package/build/internal/es/index.typings.mjs +47 -0
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +44 -2
- package/build/internal/es/meta.mjs +42 -0
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +2 -2
|
@@ -620,6 +620,47 @@ interface RequiredZipcodeResponse {
|
|
|
620
620
|
/** If the site requires a zipcode for delivery */
|
|
621
621
|
requiredZipcode?: boolean;
|
|
622
622
|
}
|
|
623
|
+
interface GetDeliveryDestinationPropertiesRequest {
|
|
624
|
+
}
|
|
625
|
+
interface GetDeliveryDestinationPropertiesResponse {
|
|
626
|
+
/** Delivery destination properties for Rest Of World */
|
|
627
|
+
restOfWorld?: DeliveryDestinationProperties;
|
|
628
|
+
/**
|
|
629
|
+
* List of countries and subdivisions and their delivery destination properties
|
|
630
|
+
* @maxSize 195
|
|
631
|
+
*/
|
|
632
|
+
countries?: CountryDeliveryProperties[];
|
|
633
|
+
}
|
|
634
|
+
interface DeliveryDestinationProperties {
|
|
635
|
+
/** True if postal code is required for delivery in this destination */
|
|
636
|
+
postalCodeRequired?: boolean;
|
|
637
|
+
/** True if only pickup is available in this destination */
|
|
638
|
+
pickupOnly?: boolean;
|
|
639
|
+
}
|
|
640
|
+
interface CountryDeliveryProperties {
|
|
641
|
+
/**
|
|
642
|
+
* Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format.
|
|
643
|
+
* @format COUNTRY
|
|
644
|
+
*/
|
|
645
|
+
country?: string;
|
|
646
|
+
/** Delivery destination properties for country */
|
|
647
|
+
deliveryDestinationProperties?: DeliveryDestinationProperties;
|
|
648
|
+
/**
|
|
649
|
+
* List of subdivisions and their delivery destination properties
|
|
650
|
+
* @maxSize 100
|
|
651
|
+
*/
|
|
652
|
+
subdivisions?: SubdivisionDeliveryProperties[];
|
|
653
|
+
}
|
|
654
|
+
interface SubdivisionDeliveryProperties {
|
|
655
|
+
/**
|
|
656
|
+
* Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format.
|
|
657
|
+
* @minLength 1
|
|
658
|
+
* @maxLength 5
|
|
659
|
+
*/
|
|
660
|
+
subdivision?: string;
|
|
661
|
+
/** Delivery destination properties for subdivision */
|
|
662
|
+
deliveryDestinationProperties?: DeliveryDestinationProperties;
|
|
663
|
+
}
|
|
623
664
|
interface ListDeliveryCarriersRequest {
|
|
624
665
|
/**
|
|
625
666
|
* Delivery profile id.
|
|
@@ -2008,6 +2049,15 @@ interface UpdateDeliveryCarrierOptions {
|
|
|
2008
2049
|
* @fqn wix.ecom.deliveryprofile.v1.DeliveryProfiles.ListInstalledDeliveryCarriers
|
|
2009
2050
|
*/
|
|
2010
2051
|
declare function listInstalledDeliveryCarriers(): Promise<NonNullablePaths<ListInstalledDeliveryCarriersResponse, `installedDeliveryCarriers` | `installedDeliveryCarriers.${number}._id` | `installedDeliveryCarriers.${number}.displayName` | `installedDeliveryCarriers.${number}.toggleGetCarrierSettingsEnabled`, 4>>;
|
|
2052
|
+
/**
|
|
2053
|
+
* Retrieves delivery destination properties by ROW, and aggregated country and subdivision
|
|
2054
|
+
* @public
|
|
2055
|
+
* @documentationMaturity preview
|
|
2056
|
+
* @permissionId ECOM.DELIVERY_PROFILE_READ
|
|
2057
|
+
* @applicableIdentity APP
|
|
2058
|
+
* @fqn wix.ecom.deliveryprofile.v1.DeliveryProfiles.GetDeliveryDestinationProperties
|
|
2059
|
+
*/
|
|
2060
|
+
declare function getDeliveryDestinationProperties(): Promise<NonNullablePaths<GetDeliveryDestinationPropertiesResponse, `restOfWorld.postalCodeRequired` | `restOfWorld.pickupOnly` | `countries` | `countries.${number}.country` | `countries.${number}.deliveryDestinationProperties.postalCodeRequired` | `countries.${number}.deliveryDestinationProperties.pickupOnly`, 5>>;
|
|
2011
2061
|
/**
|
|
2012
2062
|
* Get delivery carrier settings for a delivery profile and delivery region.
|
|
2013
2063
|
* These are returned in a table format for the dashboard.
|
|
@@ -2076,4 +2126,4 @@ interface UpdateExtendedFieldsOptions {
|
|
|
2076
2126
|
namespaceData: Record<string, any> | null;
|
|
2077
2127
|
}
|
|
2078
2128
|
|
|
2079
|
-
export { type ActionEvent, type AddDeliveryCarrierApplicationErrors, type AddDeliveryCarrierOptions, type AddDeliveryCarrierRequest, type AddDeliveryCarrierResponse, type AddDeliveryCarrierValidationErrors, type AddDeliveryRegionApplicationErrors, type AddDeliveryRegionOptions, type AddDeliveryRegionRequest, type AddDeliveryRegionResponse, type AddDeliveryRegionValidationErrors, type AdditionalCharge, type ApplicationError, type Asset, type BackupRate, type BulkActionMetadata, ChargeType, type ChargeTypeWithLiterals, type Column, type CreateDeliveryProfileApplicationErrors, type CreateDeliveryProfileRequest, type CreateDeliveryProfileResponse, type CreateDeliveryProfileValidationErrors, type CreatedBy, type CreatedByIdOneOf, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type DashboardTable, type DeleteContext, type DeleteDefaultDeliveryProfileRequest, type DeleteDefaultDeliveryProfileResponse, type DeleteDeliveryProfileRequest, type DeleteDeliveryProfileResponse, DeleteStatus, type DeleteStatusWithLiterals, type DeliveryCarrier, type DeliveryCarrierDetails, type DeliveryCarrierRegionalSettings, type DeliveryProfile, type DeliveryProfilesQueryBuilder, type DeliveryProfilesQueryResult, type DeliveryRegion, type DeliveryRegionAdded, type DeliveryRegionRemoved, type DeliveryRegionUpdated, type Destination, DestinationScope, type DestinationScopeWithLiterals, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type ExtendedFields, type GetDeliveryProfileByDeliveryRegionIdApplicationErrors, type GetDeliveryProfileByDeliveryRegionIdRequest, type GetDeliveryProfileByDeliveryRegionIdResponse, type GetDeliveryProfileRequest, type GetDeliveryProfileResponse, type IdentificationData, type IdentificationDataIdOneOf, type InstalledDeliveryCarrier, type ItemMetadata, type ListDeliveryCarriersApplicationErrors, type ListDeliveryCarriersOptions, type ListDeliveryCarriersRequest, type ListDeliveryCarriersResponse, type ListDeliveryCarriersResult, type ListDeliveryDestinationsRequest, type ListDeliveryDestinationsResponse, type ListInstalledDeliveryCarriersRequest, type ListInstalledDeliveryCarriersResponse, type MessageEnvelope, type MetaSiteSpecialEvent, type MetaSiteSpecialEventPayloadOneOf, Namespace, type NamespaceChanged, type NamespaceWithLiterals, type OdeditorAssigned, type OdeditorUnassigned, type PicassoAssigned, type PicassoUnassigned, type QueryDeliveryProfilesRequest, type QueryDeliveryProfilesResponse, type RemoveDeliveryCarrierApplicationErrors, type RemoveDeliveryCarrierOptions, type RemoveDeliveryCarrierRequest, type RemoveDeliveryCarrierResponse, type RemoveDeliveryRegionApplicationErrors, type RemoveDeliveryRegionIdentifiers, type RemoveDeliveryRegionOptions, type RemoveDeliveryRegionRequest, type RemoveDeliveryRegionResponse, type RequiredZipcodeRequest, type RequiredZipcodeResponse, type RestoreInfo, type Row, type ServiceProvisioned, type ServiceRemoved, type SiteCreated, SiteCreatedContext, type SiteCreatedContextWithLiterals, type SiteDeleted, type SiteHardDeleted, type SiteMarkedAsTemplate, type SiteMarkedAsWixSite, type SitePublished, type SitePurgedExternally, type SiteRenamed, type SiteTransferred, type SiteUndeleted, type SiteUnpublished, type SiteUrlChanged, SortOrder, type SortOrderWithLiterals, type Sorting, State, type StateWithLiterals, type StudioAssigned, type StudioTwoAssigned, type StudioTwoUnassigned, type StudioUnassigned, type UpdateCarrierSettingsApplicationErrors, type UpdateCarrierSettingsOptions, type UpdateCarrierSettingsRequest, type UpdateCarrierSettingsResponse, type UpdateDeliveryCarrierApplicationErrors, type UpdateDeliveryCarrierOptions, type UpdateDeliveryCarrierRequest, type UpdateDeliveryCarrierResponse, type UpdateDeliveryProfile, type UpdateDeliveryProfileApplicationErrors, type UpdateDeliveryProfileRequest, type UpdateDeliveryProfileResponse, type UpdateDeliveryRegion, type UpdateDeliveryRegionApplicationErrors, type UpdateDeliveryRegionIdentifiers, type UpdateDeliveryRegionOptions, type UpdateDeliveryRegionRequest, type UpdateDeliveryRegionResponse, type UpdateDeliveryRegionValidationErrors, type UpdateExtendedFieldsOptions, type UpdateExtendedFieldsRequest, type UpdateExtendedFieldsResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, type WixelAssigned, type WixelUnassigned, addDeliveryCarrier, addDeliveryRegion, createDeliveryProfile, deleteDeliveryProfile, getDeliveryProfile, getDeliveryProfileByDeliveryRegionId, listDeliveryCarriers, listInstalledDeliveryCarriers, queryDeliveryProfiles, removeDeliveryCarrier, removeDeliveryRegion, updateCarrierSettings, updateDeliveryCarrier, updateDeliveryProfile, updateDeliveryRegion, updateExtendedFields };
|
|
2129
|
+
export { type ActionEvent, type AddDeliveryCarrierApplicationErrors, type AddDeliveryCarrierOptions, type AddDeliveryCarrierRequest, type AddDeliveryCarrierResponse, type AddDeliveryCarrierValidationErrors, type AddDeliveryRegionApplicationErrors, type AddDeliveryRegionOptions, type AddDeliveryRegionRequest, type AddDeliveryRegionResponse, type AddDeliveryRegionValidationErrors, type AdditionalCharge, type ApplicationError, type Asset, type BackupRate, type BulkActionMetadata, ChargeType, type ChargeTypeWithLiterals, type Column, type CountryDeliveryProperties, type CreateDeliveryProfileApplicationErrors, type CreateDeliveryProfileRequest, type CreateDeliveryProfileResponse, type CreateDeliveryProfileValidationErrors, type CreatedBy, type CreatedByIdOneOf, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type DashboardTable, type DeleteContext, type DeleteDefaultDeliveryProfileRequest, type DeleteDefaultDeliveryProfileResponse, type DeleteDeliveryProfileRequest, type DeleteDeliveryProfileResponse, DeleteStatus, type DeleteStatusWithLiterals, type DeliveryCarrier, type DeliveryCarrierDetails, type DeliveryCarrierRegionalSettings, type DeliveryDestinationProperties, type DeliveryProfile, type DeliveryProfilesQueryBuilder, type DeliveryProfilesQueryResult, type DeliveryRegion, type DeliveryRegionAdded, type DeliveryRegionRemoved, type DeliveryRegionUpdated, type Destination, DestinationScope, type DestinationScopeWithLiterals, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type ExtendedFields, type GetDeliveryDestinationPropertiesRequest, type GetDeliveryDestinationPropertiesResponse, type GetDeliveryProfileByDeliveryRegionIdApplicationErrors, type GetDeliveryProfileByDeliveryRegionIdRequest, type GetDeliveryProfileByDeliveryRegionIdResponse, type GetDeliveryProfileRequest, type GetDeliveryProfileResponse, type IdentificationData, type IdentificationDataIdOneOf, type InstalledDeliveryCarrier, type ItemMetadata, type ListDeliveryCarriersApplicationErrors, type ListDeliveryCarriersOptions, type ListDeliveryCarriersRequest, type ListDeliveryCarriersResponse, type ListDeliveryCarriersResult, type ListDeliveryDestinationsRequest, type ListDeliveryDestinationsResponse, type ListInstalledDeliveryCarriersRequest, type ListInstalledDeliveryCarriersResponse, type MessageEnvelope, type MetaSiteSpecialEvent, type MetaSiteSpecialEventPayloadOneOf, Namespace, type NamespaceChanged, type NamespaceWithLiterals, type OdeditorAssigned, type OdeditorUnassigned, type PicassoAssigned, type PicassoUnassigned, type QueryDeliveryProfilesRequest, type QueryDeliveryProfilesResponse, type RemoveDeliveryCarrierApplicationErrors, type RemoveDeliveryCarrierOptions, type RemoveDeliveryCarrierRequest, type RemoveDeliveryCarrierResponse, type RemoveDeliveryRegionApplicationErrors, type RemoveDeliveryRegionIdentifiers, type RemoveDeliveryRegionOptions, type RemoveDeliveryRegionRequest, type RemoveDeliveryRegionResponse, type RequiredZipcodeRequest, type RequiredZipcodeResponse, type RestoreInfo, type Row, type ServiceProvisioned, type ServiceRemoved, type SiteCreated, SiteCreatedContext, type SiteCreatedContextWithLiterals, type SiteDeleted, type SiteHardDeleted, type SiteMarkedAsTemplate, type SiteMarkedAsWixSite, type SitePublished, type SitePurgedExternally, type SiteRenamed, type SiteTransferred, type SiteUndeleted, type SiteUnpublished, type SiteUrlChanged, SortOrder, type SortOrderWithLiterals, type Sorting, State, type StateWithLiterals, type StudioAssigned, type StudioTwoAssigned, type StudioTwoUnassigned, type StudioUnassigned, type SubdivisionDeliveryProperties, type UpdateCarrierSettingsApplicationErrors, type UpdateCarrierSettingsOptions, type UpdateCarrierSettingsRequest, type UpdateCarrierSettingsResponse, type UpdateDeliveryCarrierApplicationErrors, type UpdateDeliveryCarrierOptions, type UpdateDeliveryCarrierRequest, type UpdateDeliveryCarrierResponse, type UpdateDeliveryProfile, type UpdateDeliveryProfileApplicationErrors, type UpdateDeliveryProfileRequest, type UpdateDeliveryProfileResponse, type UpdateDeliveryRegion, type UpdateDeliveryRegionApplicationErrors, type UpdateDeliveryRegionIdentifiers, type UpdateDeliveryRegionOptions, type UpdateDeliveryRegionRequest, type UpdateDeliveryRegionResponse, type UpdateDeliveryRegionValidationErrors, type UpdateExtendedFieldsOptions, type UpdateExtendedFieldsRequest, type UpdateExtendedFieldsResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, type WixelAssigned, type WixelUnassigned, addDeliveryCarrier, addDeliveryRegion, createDeliveryProfile, deleteDeliveryProfile, getDeliveryDestinationProperties, getDeliveryProfile, getDeliveryProfileByDeliveryRegionId, listDeliveryCarriers, listInstalledDeliveryCarriers, queryDeliveryProfiles, removeDeliveryCarrier, removeDeliveryRegion, updateCarrierSettings, updateDeliveryCarrier, updateDeliveryProfile, updateDeliveryRegion, updateExtendedFields };
|
|
@@ -501,6 +501,27 @@ function listInstalledDeliveryCarriers(payload) {
|
|
|
501
501
|
}
|
|
502
502
|
return __listInstalledDeliveryCarriers;
|
|
503
503
|
}
|
|
504
|
+
function getDeliveryDestinationProperties(payload) {
|
|
505
|
+
function __getDeliveryDestinationProperties({ host }) {
|
|
506
|
+
const metadata = {
|
|
507
|
+
entityFqdn: "wix.ecom.v1.delivery_profile",
|
|
508
|
+
method: "GET",
|
|
509
|
+
methodFqn: "wix.ecom.deliveryprofile.v1.DeliveryProfiles.GetDeliveryDestinationProperties",
|
|
510
|
+
packageName: PACKAGE_NAME,
|
|
511
|
+
migrationOptions: {
|
|
512
|
+
optInTransformResponse: true
|
|
513
|
+
},
|
|
514
|
+
url: resolveWixEcomDeliveryprofileV1DeliveryProfilesUrl({
|
|
515
|
+
protoPath: "/v1/delivery-profiles/delivery-destination-properties",
|
|
516
|
+
data: payload,
|
|
517
|
+
host
|
|
518
|
+
}),
|
|
519
|
+
params: toURLSearchParams(payload)
|
|
520
|
+
};
|
|
521
|
+
return metadata;
|
|
522
|
+
}
|
|
523
|
+
return __getDeliveryDestinationProperties;
|
|
524
|
+
}
|
|
504
525
|
function listDeliveryCarriers(payload) {
|
|
505
526
|
function __listDeliveryCarriers({ host }) {
|
|
506
527
|
const metadata = {
|
|
@@ -1033,6 +1054,31 @@ async function listInstalledDeliveryCarriers2() {
|
|
|
1033
1054
|
throw transformedError;
|
|
1034
1055
|
}
|
|
1035
1056
|
}
|
|
1057
|
+
async function getDeliveryDestinationProperties2() {
|
|
1058
|
+
const { httpClient, sideEffects } = arguments[0];
|
|
1059
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({});
|
|
1060
|
+
const reqOpts = getDeliveryDestinationProperties(
|
|
1061
|
+
payload
|
|
1062
|
+
);
|
|
1063
|
+
sideEffects?.onSiteCall?.();
|
|
1064
|
+
try {
|
|
1065
|
+
const result = await httpClient.request(reqOpts);
|
|
1066
|
+
sideEffects?.onSuccess?.(result);
|
|
1067
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
1068
|
+
} catch (err) {
|
|
1069
|
+
const transformedError = sdkTransformError(
|
|
1070
|
+
err,
|
|
1071
|
+
{
|
|
1072
|
+
spreadPathsToArguments: {},
|
|
1073
|
+
explicitPathsToArguments: {},
|
|
1074
|
+
singleArgumentUnchanged: false
|
|
1075
|
+
},
|
|
1076
|
+
[]
|
|
1077
|
+
);
|
|
1078
|
+
sideEffects?.onError?.(err);
|
|
1079
|
+
throw transformedError;
|
|
1080
|
+
}
|
|
1081
|
+
}
|
|
1036
1082
|
async function listDeliveryCarriers2(deliveryProfileId, options) {
|
|
1037
1083
|
const { httpClient, sideEffects } = arguments[2];
|
|
1038
1084
|
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
@@ -1137,6 +1183,7 @@ export {
|
|
|
1137
1183
|
addDeliveryRegion2 as addDeliveryRegion,
|
|
1138
1184
|
createDeliveryProfile2 as createDeliveryProfile,
|
|
1139
1185
|
deleteDeliveryProfile2 as deleteDeliveryProfile,
|
|
1186
|
+
getDeliveryDestinationProperties2 as getDeliveryDestinationProperties,
|
|
1140
1187
|
getDeliveryProfile2 as getDeliveryProfile,
|
|
1141
1188
|
getDeliveryProfileByDeliveryRegionId2 as getDeliveryProfileByDeliveryRegionId,
|
|
1142
1189
|
listDeliveryCarriers2 as listDeliveryCarriers,
|