@asteby/storefront 0.26.0 → 0.27.0
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/dist/{account-settings-BnhDUPWx.d.ts → account-settings-Cio2mAvd.d.ts} +40 -1
- package/dist/{account-settings-C0r3jJ72.d.cts → account-settings-DghDmuaI.d.cts} +40 -1
- package/dist/cli.js +21 -1
- package/dist/fiscal-document.d.cts +2 -2
- package/dist/fiscal-document.d.ts +2 -2
- package/dist/index.cjs +20 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -3
- package/dist/index.d.ts +12 -3
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -1
- package/dist/mock.d.cts +1 -1
- package/dist/mock.d.ts +1 -1
- package/dist/mockup.d.cts +1 -1
- package/dist/mockup.d.ts +1 -1
- package/dist/node.cjs +1 -1
- package/dist/node.js +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { bf as ProductSort, c1 as TokenIntrospection, bK as Shop, bp as Region, bt as RegionPostalCode, d as AddressSuggestions, bd as ProductConnection, ba as Product, D as Connection, B as Collection, aw as LocationListParams, at as Location, aC as NearestLocation, bO as StockLevel, bu as RestockSubscriptionInput, bv as RestockSubscriptionResult, p as CartLineInput, C as Cart, s as CartLineUpdateInput, i as CartBuyerInput, b as AddressInput, _ as DeliveryOptions, b0 as PaymentMethods, Y as DeliveryInput, ao as InvoiceRequest, bn as RecommendationPlacement, v as CartRecommendations, x as CheckoutInput, z as CheckoutResult, bk as PromotionsList, aY as PaymentConfig, b5 as PaymentSubmitInput, aU as PaymentAttemptResult, K as CustomerIdentifier, S as CustomerSessionInput, Q as CustomerSession, F as CustomerCapabilities, N as CustomerRegisterInput, O as CustomerRegisterResult, V as CustomerVerifyRegistrationInput, L as CustomerPasswordLoginInput, T as CustomerSetPasswordInput, P as CustomerResetPasswordInput, E as Customer, U as CustomerUpdateInput, R as CustomerSessionInfo, bl as ReauthInput, bm as ReauthResult, J as CustomerEmailCodeInput, H as CustomerEmailChangeInput, I as CustomerEmailChangeRequested, G as CustomerEmailChangeConfirmInput, W as DataExportFile, A as AccountDeleteInput, aF as Order, ai as InvoiceConnection, bC as ShipmentConnection, bx as ReturnRequestInput, bw as ReturnRequest, ap as InvoiceResult, b7 as PendingPayment, al as InvoiceFileKind, ak as InvoiceFile, a5 as FiscalProfile, a6 as FiscalProfileInput, bT as Subject, bY as SubjectInput, b_ as SubjectPatch, a as Address, bZ as SubjectKind, c0 as Theme, aR as Page, ay as Menu, e as Article, aA as Money, g as AvailabilityStatus, r as CartLineProblem, f as Availability, ag as InsufficientStockLine, o as CartLine, bg as ProductVariant, X as DeclineCode, b6 as PaymentVoucher, b1 as PaymentNextStep, t as CartPromotions, bi as PromotionReward, aj as InvoiceDoc, bB as Shipment, aD as NextAction, aJ as OrderProgress, bH as ShipmentStatus, bD as ShipmentEvent, bV as SubjectCatalogNode, bW as SubjectField, Z as DeliveryMethod,
|
|
2
|
-
export { c as AddressSuggestion, h as CartBuyer, j as CartCost, k as CartDelivery, l as CartDiscountCode, m as CartDiscountLine, n as CartInvoice, q as CartLineMerchandise, u as CartRecommendation, w as CheckoutInfo, y as CheckoutPayment, M as CustomerPreferences, $ as Facet, a0 as FacetValue, a1 as FiscalDocumentEvidence, a2 as FiscalDocumentSource, a3 as FiscalIdentity, a4 as FiscalIdentityInput, a7 as FiscalVerification, a8 as GeoHint, a9 as IdentityCapture, aa as IdentityDocumentSpec, ab as IdentityFieldRule, ac as IdentityRulesV1, ad as IdentityStrategy, ae as Image, af as InsufficientStockDetails, ah as InvoiceAction, am as InvoiceListNode, an as InvoiceReceiver, aq as InvoiceStage, ar as InvoiceSummary, as as InvoicingCapabilities, au as LocationContacts, av as LocationKind, ax as LocationPickup, az as MenuItem, aB as MoneyRange, aE as NextActionKind, aG as OrderLine, aH as OrderPickup, aI as OrderProblem, aK as OrderProgressStep, aL as OrderRef, aM as OrderSection, aN as OrderShippingService, aO as OrderStage, aP as OrderStepKey, aQ as OrderStepState, aT as PaymentAction, aV as PaymentAttemptStatus, aW as PaymentClient, aX as PaymentClientCsp, aZ as PaymentFlow, a_ as PaymentInfo, a$ as PaymentMethod, b2 as PaymentOption, b3 as PaymentOptionKey, b4 as PaymentPoint, b8 as PendingPaymentVoucher, b9 as PickupOption, bb as ProductAttributeValue, bc as ProductCategory, be as ProductOption, bh as PromotionAnnouncement, bj as PromotionTier, bo as Refund, bq as RegionFiscalEntry, br as RegionFiscalId, bs as RegionPaymentMethod, by as SEO, bz as Section, bA as SelectedOption, bE as ShipmentKind, bF as ShipmentListNode, bG as ShipmentMap, bI as ShipmentsSummary, bJ as ShippingRate, bL as ShopBranch, bM as ShopContact, bN as ShopPolicies, bP as StorefrontError, bQ as StorefrontErrorBody, bR as StorefrontErrorCode, bS as StorefrontErrorInit, bU as SubjectCatalog, bX as SubjectFieldType, b$ as SubjectRef,
|
|
1
|
+
import { bf as ProductSort, c1 as TokenIntrospection, bK as Shop, bp as Region, bt as RegionPostalCode, d as AddressSuggestions, bd as ProductConnection, ba as Product, D as Connection, B as Collection, aw as LocationListParams, at as Location, aC as NearestLocation, bO as StockLevel, bu as RestockSubscriptionInput, bv as RestockSubscriptionResult, p as CartLineInput, C as Cart, s as CartLineUpdateInput, i as CartBuyerInput, b as AddressInput, _ as DeliveryOptions, b0 as PaymentMethods, Y as DeliveryInput, ao as InvoiceRequest, bn as RecommendationPlacement, v as CartRecommendations, x as CheckoutInput, z as CheckoutResult, bk as PromotionsList, aY as PaymentConfig, b5 as PaymentSubmitInput, aU as PaymentAttemptResult, c3 as TrackingLookupInput, c4 as TrackingLookupResult, K as CustomerIdentifier, S as CustomerSessionInput, Q as CustomerSession, F as CustomerCapabilities, N as CustomerRegisterInput, O as CustomerRegisterResult, V as CustomerVerifyRegistrationInput, L as CustomerPasswordLoginInput, T as CustomerSetPasswordInput, P as CustomerResetPasswordInput, E as Customer, U as CustomerUpdateInput, R as CustomerSessionInfo, bl as ReauthInput, bm as ReauthResult, J as CustomerEmailCodeInput, H as CustomerEmailChangeInput, I as CustomerEmailChangeRequested, G as CustomerEmailChangeConfirmInput, W as DataExportFile, A as AccountDeleteInput, aF as Order, ai as InvoiceConnection, bC as ShipmentConnection, bx as ReturnRequestInput, bw as ReturnRequest, ap as InvoiceResult, b7 as PendingPayment, al as InvoiceFileKind, ak as InvoiceFile, a5 as FiscalProfile, a6 as FiscalProfileInput, bT as Subject, bY as SubjectInput, b_ as SubjectPatch, a as Address, bZ as SubjectKind, c0 as Theme, aR as Page, ay as Menu, e as Article, aA as Money, g as AvailabilityStatus, r as CartLineProblem, f as Availability, ag as InsufficientStockLine, o as CartLine, bg as ProductVariant, X as DeclineCode, b6 as PaymentVoucher, b1 as PaymentNextStep, t as CartPromotions, bi as PromotionReward, aj as InvoiceDoc, bB as Shipment, aD as NextAction, aJ as OrderProgress, bH as ShipmentStatus, bD as ShipmentEvent, bV as SubjectCatalogNode, bW as SubjectField, Z as DeliveryMethod, c6 as UnavailableRateProvider, aS as PageInfo } from './account-settings-DghDmuaI.cjs';
|
|
2
|
+
export { c as AddressSuggestion, h as CartBuyer, j as CartCost, k as CartDelivery, l as CartDiscountCode, m as CartDiscountLine, n as CartInvoice, q as CartLineMerchandise, u as CartRecommendation, w as CheckoutInfo, y as CheckoutPayment, M as CustomerPreferences, $ as Facet, a0 as FacetValue, a1 as FiscalDocumentEvidence, a2 as FiscalDocumentSource, a3 as FiscalIdentity, a4 as FiscalIdentityInput, a7 as FiscalVerification, a8 as GeoHint, a9 as IdentityCapture, aa as IdentityDocumentSpec, ab as IdentityFieldRule, ac as IdentityRulesV1, ad as IdentityStrategy, ae as Image, af as InsufficientStockDetails, ah as InvoiceAction, am as InvoiceListNode, an as InvoiceReceiver, aq as InvoiceStage, ar as InvoiceSummary, as as InvoicingCapabilities, au as LocationContacts, av as LocationKind, ax as LocationPickup, az as MenuItem, aB as MoneyRange, aE as NextActionKind, aG as OrderLine, aH as OrderPickup, aI as OrderProblem, aK as OrderProgressStep, aL as OrderRef, aM as OrderSection, aN as OrderShippingService, aO as OrderStage, aP as OrderStepKey, aQ as OrderStepState, aT as PaymentAction, aV as PaymentAttemptStatus, aW as PaymentClient, aX as PaymentClientCsp, aZ as PaymentFlow, a_ as PaymentInfo, a$ as PaymentMethod, b2 as PaymentOption, b3 as PaymentOptionKey, b4 as PaymentPoint, b8 as PendingPaymentVoucher, b9 as PickupOption, bb as ProductAttributeValue, bc as ProductCategory, be as ProductOption, bh as PromotionAnnouncement, bj as PromotionTier, bo as Refund, bq as RegionFiscalEntry, br as RegionFiscalId, bs as RegionPaymentMethod, by as SEO, bz as Section, bA as SelectedOption, bE as ShipmentKind, bF as ShipmentListNode, bG as ShipmentMap, bI as ShipmentsSummary, bJ as ShippingRate, bL as ShopBranch, bM as ShopContact, bN as ShopPolicies, bP as StorefrontError, bQ as StorefrontErrorBody, bR as StorefrontErrorCode, bS as StorefrontErrorInit, bU as SubjectCatalog, bX as SubjectFieldType, b$ as SubjectRef, c2 as TrackingEventView, c5 as TrackingView, c7 as dataExportBytes, c8 as isAccountDeleteBlocked, c9 as isReauthRequired, ca as isStorefrontError, cb as safeExportFilename } from './account-settings-DghDmuaI.cjs';
|
|
3
3
|
import { GeoPoint } from './geo.cjs';
|
|
4
4
|
export { OpenStatus, OpeningHours } from './geo.cjs';
|
|
5
5
|
|
|
@@ -363,6 +363,15 @@ declare function createStorefrontClient(config: StorefrontClientOptions): {
|
|
|
363
363
|
*/
|
|
364
364
|
get: (id: string, options?: RequestOptions) => Promise<CheckoutResult | null>;
|
|
365
365
|
};
|
|
366
|
+
/**
|
|
367
|
+
* Public "where is my order" lookup (`POST /storefront/customer/track`): by order number + email, or by the guide
|
|
368
|
+
* printed on the parcel. No buyer session. Every failure is one of three plain answers, so a miss never tells a
|
|
369
|
+
* real order from an unknown one: `not_found`, `rate_limited` (with `retryAfter` seconds when known) or
|
|
370
|
+
* `unavailable` (the server or the network failed). Needs the store to enable the route.
|
|
371
|
+
*/
|
|
372
|
+
tracking: {
|
|
373
|
+
lookup: (input: TrackingLookupInput, options?: WriteOptions) => Promise<TrackingLookupResult>;
|
|
374
|
+
};
|
|
366
375
|
customer: {
|
|
367
376
|
/** Sends a one-time code by email or SMS/WhatsApp. */
|
|
368
377
|
requestOtp: (identifier: CustomerIdentifier, options?: WriteOptions) => Promise<void>;
|
|
@@ -1170,4 +1179,4 @@ declare function pageRange(state: Pick<ListPageState, 'query' | 'pageInfo' | 'co
|
|
|
1170
1179
|
total: number | null;
|
|
1171
1180
|
} | null;
|
|
1172
1181
|
|
|
1173
|
-
export { AccountDeleteInput, type AccountListParams, Address, AddressInput, type AddressSuggestParams, AddressSuggestions, Article, type ArticleListParams, Availability, type AvailabilityLocale, type AvailabilityMessageKey, type AvailabilityMessages, AvailabilityStatus, type AvailabilityTone, type AvailabilityView, type AvailabilityViewOptions, CLIENT_IP_HEADER, COUNTRY_HEADERS, Cart, CartBuyerInput, CartLine, CartLineInput, CartLineProblem, type CartLineProblemView, CartLineUpdateInput, CartPromotions, CartRecommendations, CheckoutInput, CheckoutResult, Collection, type CollectionListParams, Connection, Customer, CustomerCapabilities, CustomerEmailChangeConfirmInput, CustomerEmailChangeInput, CustomerEmailChangeRequested, CustomerEmailCodeInput, CustomerIdentifier, CustomerPasswordLoginInput, CustomerRegisterInput, CustomerRegisterResult, CustomerResetPasswordInput, CustomerSession, CustomerSessionInfo, CustomerSessionInput, CustomerSetPasswordInput, CustomerUpdateInput, CustomerVerifyRegistrationInput, DEFAULT_FIT_TAG_PREFIX, DataExportFile, DeclineCode, type DeliveryChoice, type DeliveryChoiceKind, DeliveryInput, DeliveryMethod, type DeliveryNotices, DeliveryOptions, type DiagnoseOptions, type DiscountBarState, type DiscountBarView, type FetchLike, FiscalProfile, FiscalProfileInput, type FormatMoneyOptions, GeoPoint, InsufficientStockLine, InvoiceConnection, InvoiceDoc, InvoiceFile, InvoiceFileKind, type InvoiceGroup, type InvoiceListParams, InvoiceRequest, InvoiceResult, LIST_URL_EN, LIST_URL_ES, type ListPageState, type ListQuery, type ListUrlNames, Location, LocationListParams, MAX_SUBJECT_YEAR, MIN_SUBJECT_YEAR, MISSING_WEIGHT, type MarketInfo, type MarketSuggestion, Menu, Money, NOTE_MAX_LENGTH, NearestLocation, NextAction, Order, type OrderListParams, OrderProgress, PAYMENT_CHOICE_REFUSED_FIELD, PICKUP_STEPS, PRIVATE_MASK, Page, PageInfo, type PaginationParams, PaymentAttemptResult, PaymentConfig, type PaymentErrorClass, type PaymentErrorClassKind, type PaymentErrorKind, type PaymentErrorLike, type PaymentErrorView, type PaymentLocale, type PaymentMessageKey, type PaymentMessages, PaymentMethods, PaymentNextStep, type PaymentOutcome, type PaymentOutcomeKind, PaymentSubmitInput, PaymentVoucher, PendingPayment, type PreviewOptions, Product, ProductConnection, type ProductListParams, ProductSort, ProductVariant, type PromoProgressView, type PromotionLocale, type PromotionMessageKey, type PromotionMessages, PromotionReward, PromotionsList, type QueryParams, type QueryValue, ReauthInput, ReauthResult, RecommendationPlacement, Region, RegionPostalCode, type RequestOptions, type ResolveAvailabilityOptions, type ResolvedSubject, RestockSubscriptionInput, RestockSubscriptionResult, ReturnRequest, ReturnRequestInput, SHIPPING_STEPS, SUBJECT_CATALOG_PAGE_BYTES, Shipment, ShipmentConnection, ShipmentEvent, type ShipmentListParams, ShipmentStatus, type ShippingBarState, type ShippingBarView, Shop, StockLevel, type StorefrontClient, type StorefrontClientOptions, type StorefrontRequestContext, type StorefrontResponseContext, Subject, SubjectCatalogNode, SubjectField, SubjectInput, SubjectKind, type SubjectOption, SubjectPatch, type SubjectProblemCode, type SubjectProblems, type SubjectValues, Theme, TokenIntrospection, UnavailableRateProvider, type WriteOptions, accountListQuery, appendParams, availabilityLocale, availabilityMessages, availabilityView, cartLineProblemView, clampPercent, classifyPaymentError, coversYear, createStorefrontClient, declineMessage, declineMessageKey, deliveryInput, deliveryNotices, diagnose, firstPageQuery, fitTag, fitTagsAny, formatAvailabilityMessage, formatMoney, formatVoucherExpiry, generateIdempotencyKey, groupInvoiceDocs, hreflangLinks, invoiceFileBytes, isFiltered, isMasked, isTestInvoice, isTestShipment, isTokenPublishable, lineShipDate, lineShipLabel, listApiParams, listHref, listQueryString, maskToken, negotiateLocale, nextAction, nextPageQuery, normalizeClientIp, normalizeNote, opsSaysNotRetryable, orderProgress, orderShipments, pagePosition, pageRange, parseDelivery, parseMoney, parseProductFilters, paymentErrorView, paymentIdempotencyKey, paymentMessages, paymentOutcome, preferredLanguages, previousPageQuery, productAvailability, productListQuery, promoProgressView, promotionMessages, readListQuery, reconcileSubjectValues, repairPath, resolveAvailability, resolveSubject, rewardLabel, safeHttpsUrl, safeInvoiceFilename, safeTrackingUrl, schemaAvailability, shipmentsStatus, sortTrackingEvents, splitSubjectTree, storefrontDomainHeader, subjectFields, subjectLevels, subjectOptions, suggestMarket, toMoney, visitorCountry };
|
|
1182
|
+
export { AccountDeleteInput, type AccountListParams, Address, AddressInput, type AddressSuggestParams, AddressSuggestions, Article, type ArticleListParams, Availability, type AvailabilityLocale, type AvailabilityMessageKey, type AvailabilityMessages, AvailabilityStatus, type AvailabilityTone, type AvailabilityView, type AvailabilityViewOptions, CLIENT_IP_HEADER, COUNTRY_HEADERS, Cart, CartBuyerInput, CartLine, CartLineInput, CartLineProblem, type CartLineProblemView, CartLineUpdateInput, CartPromotions, CartRecommendations, CheckoutInput, CheckoutResult, Collection, type CollectionListParams, Connection, Customer, CustomerCapabilities, CustomerEmailChangeConfirmInput, CustomerEmailChangeInput, CustomerEmailChangeRequested, CustomerEmailCodeInput, CustomerIdentifier, CustomerPasswordLoginInput, CustomerRegisterInput, CustomerRegisterResult, CustomerResetPasswordInput, CustomerSession, CustomerSessionInfo, CustomerSessionInput, CustomerSetPasswordInput, CustomerUpdateInput, CustomerVerifyRegistrationInput, DEFAULT_FIT_TAG_PREFIX, DataExportFile, DeclineCode, type DeliveryChoice, type DeliveryChoiceKind, DeliveryInput, DeliveryMethod, type DeliveryNotices, DeliveryOptions, type DiagnoseOptions, type DiscountBarState, type DiscountBarView, type FetchLike, FiscalProfile, FiscalProfileInput, type FormatMoneyOptions, GeoPoint, InsufficientStockLine, InvoiceConnection, InvoiceDoc, InvoiceFile, InvoiceFileKind, type InvoiceGroup, type InvoiceListParams, InvoiceRequest, InvoiceResult, LIST_URL_EN, LIST_URL_ES, type ListPageState, type ListQuery, type ListUrlNames, Location, LocationListParams, MAX_SUBJECT_YEAR, MIN_SUBJECT_YEAR, MISSING_WEIGHT, type MarketInfo, type MarketSuggestion, Menu, Money, NOTE_MAX_LENGTH, NearestLocation, NextAction, Order, type OrderListParams, OrderProgress, PAYMENT_CHOICE_REFUSED_FIELD, PICKUP_STEPS, PRIVATE_MASK, Page, PageInfo, type PaginationParams, PaymentAttemptResult, PaymentConfig, type PaymentErrorClass, type PaymentErrorClassKind, type PaymentErrorKind, type PaymentErrorLike, type PaymentErrorView, type PaymentLocale, type PaymentMessageKey, type PaymentMessages, PaymentMethods, PaymentNextStep, type PaymentOutcome, type PaymentOutcomeKind, PaymentSubmitInput, PaymentVoucher, PendingPayment, type PreviewOptions, Product, ProductConnection, type ProductListParams, ProductSort, ProductVariant, type PromoProgressView, type PromotionLocale, type PromotionMessageKey, type PromotionMessages, PromotionReward, PromotionsList, type QueryParams, type QueryValue, ReauthInput, ReauthResult, RecommendationPlacement, Region, RegionPostalCode, type RequestOptions, type ResolveAvailabilityOptions, type ResolvedSubject, RestockSubscriptionInput, RestockSubscriptionResult, ReturnRequest, ReturnRequestInput, SHIPPING_STEPS, SUBJECT_CATALOG_PAGE_BYTES, Shipment, ShipmentConnection, ShipmentEvent, type ShipmentListParams, ShipmentStatus, type ShippingBarState, type ShippingBarView, Shop, StockLevel, type StorefrontClient, type StorefrontClientOptions, type StorefrontRequestContext, type StorefrontResponseContext, Subject, SubjectCatalogNode, SubjectField, SubjectInput, SubjectKind, type SubjectOption, SubjectPatch, type SubjectProblemCode, type SubjectProblems, type SubjectValues, Theme, TokenIntrospection, TrackingLookupInput, TrackingLookupResult, UnavailableRateProvider, type WriteOptions, accountListQuery, appendParams, availabilityLocale, availabilityMessages, availabilityView, cartLineProblemView, clampPercent, classifyPaymentError, coversYear, createStorefrontClient, declineMessage, declineMessageKey, deliveryInput, deliveryNotices, diagnose, firstPageQuery, fitTag, fitTagsAny, formatAvailabilityMessage, formatMoney, formatVoucherExpiry, generateIdempotencyKey, groupInvoiceDocs, hreflangLinks, invoiceFileBytes, isFiltered, isMasked, isTestInvoice, isTestShipment, isTokenPublishable, lineShipDate, lineShipLabel, listApiParams, listHref, listQueryString, maskToken, negotiateLocale, nextAction, nextPageQuery, normalizeClientIp, normalizeNote, opsSaysNotRetryable, orderProgress, orderShipments, pagePosition, pageRange, parseDelivery, parseMoney, parseProductFilters, paymentErrorView, paymentIdempotencyKey, paymentMessages, paymentOutcome, preferredLanguages, previousPageQuery, productAvailability, productListQuery, promoProgressView, promotionMessages, readListQuery, reconcileSubjectValues, repairPath, resolveAvailability, resolveSubject, rewardLabel, safeHttpsUrl, safeInvoiceFilename, safeTrackingUrl, schemaAvailability, shipmentsStatus, sortTrackingEvents, splitSubjectTree, storefrontDomainHeader, subjectFields, subjectLevels, subjectOptions, suggestMarket, toMoney, visitorCountry };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { bf as ProductSort, c1 as TokenIntrospection, bK as Shop, bp as Region, bt as RegionPostalCode, d as AddressSuggestions, bd as ProductConnection, ba as Product, D as Connection, B as Collection, aw as LocationListParams, at as Location, aC as NearestLocation, bO as StockLevel, bu as RestockSubscriptionInput, bv as RestockSubscriptionResult, p as CartLineInput, C as Cart, s as CartLineUpdateInput, i as CartBuyerInput, b as AddressInput, _ as DeliveryOptions, b0 as PaymentMethods, Y as DeliveryInput, ao as InvoiceRequest, bn as RecommendationPlacement, v as CartRecommendations, x as CheckoutInput, z as CheckoutResult, bk as PromotionsList, aY as PaymentConfig, b5 as PaymentSubmitInput, aU as PaymentAttemptResult, K as CustomerIdentifier, S as CustomerSessionInput, Q as CustomerSession, F as CustomerCapabilities, N as CustomerRegisterInput, O as CustomerRegisterResult, V as CustomerVerifyRegistrationInput, L as CustomerPasswordLoginInput, T as CustomerSetPasswordInput, P as CustomerResetPasswordInput, E as Customer, U as CustomerUpdateInput, R as CustomerSessionInfo, bl as ReauthInput, bm as ReauthResult, J as CustomerEmailCodeInput, H as CustomerEmailChangeInput, I as CustomerEmailChangeRequested, G as CustomerEmailChangeConfirmInput, W as DataExportFile, A as AccountDeleteInput, aF as Order, ai as InvoiceConnection, bC as ShipmentConnection, bx as ReturnRequestInput, bw as ReturnRequest, ap as InvoiceResult, b7 as PendingPayment, al as InvoiceFileKind, ak as InvoiceFile, a5 as FiscalProfile, a6 as FiscalProfileInput, bT as Subject, bY as SubjectInput, b_ as SubjectPatch, a as Address, bZ as SubjectKind, c0 as Theme, aR as Page, ay as Menu, e as Article, aA as Money, g as AvailabilityStatus, r as CartLineProblem, f as Availability, ag as InsufficientStockLine, o as CartLine, bg as ProductVariant, X as DeclineCode, b6 as PaymentVoucher, b1 as PaymentNextStep, t as CartPromotions, bi as PromotionReward, aj as InvoiceDoc, bB as Shipment, aD as NextAction, aJ as OrderProgress, bH as ShipmentStatus, bD as ShipmentEvent, bV as SubjectCatalogNode, bW as SubjectField, Z as DeliveryMethod,
|
|
2
|
-
export { c as AddressSuggestion, h as CartBuyer, j as CartCost, k as CartDelivery, l as CartDiscountCode, m as CartDiscountLine, n as CartInvoice, q as CartLineMerchandise, u as CartRecommendation, w as CheckoutInfo, y as CheckoutPayment, M as CustomerPreferences, $ as Facet, a0 as FacetValue, a1 as FiscalDocumentEvidence, a2 as FiscalDocumentSource, a3 as FiscalIdentity, a4 as FiscalIdentityInput, a7 as FiscalVerification, a8 as GeoHint, a9 as IdentityCapture, aa as IdentityDocumentSpec, ab as IdentityFieldRule, ac as IdentityRulesV1, ad as IdentityStrategy, ae as Image, af as InsufficientStockDetails, ah as InvoiceAction, am as InvoiceListNode, an as InvoiceReceiver, aq as InvoiceStage, ar as InvoiceSummary, as as InvoicingCapabilities, au as LocationContacts, av as LocationKind, ax as LocationPickup, az as MenuItem, aB as MoneyRange, aE as NextActionKind, aG as OrderLine, aH as OrderPickup, aI as OrderProblem, aK as OrderProgressStep, aL as OrderRef, aM as OrderSection, aN as OrderShippingService, aO as OrderStage, aP as OrderStepKey, aQ as OrderStepState, aT as PaymentAction, aV as PaymentAttemptStatus, aW as PaymentClient, aX as PaymentClientCsp, aZ as PaymentFlow, a_ as PaymentInfo, a$ as PaymentMethod, b2 as PaymentOption, b3 as PaymentOptionKey, b4 as PaymentPoint, b8 as PendingPaymentVoucher, b9 as PickupOption, bb as ProductAttributeValue, bc as ProductCategory, be as ProductOption, bh as PromotionAnnouncement, bj as PromotionTier, bo as Refund, bq as RegionFiscalEntry, br as RegionFiscalId, bs as RegionPaymentMethod, by as SEO, bz as Section, bA as SelectedOption, bE as ShipmentKind, bF as ShipmentListNode, bG as ShipmentMap, bI as ShipmentsSummary, bJ as ShippingRate, bL as ShopBranch, bM as ShopContact, bN as ShopPolicies, bP as StorefrontError, bQ as StorefrontErrorBody, bR as StorefrontErrorCode, bS as StorefrontErrorInit, bU as SubjectCatalog, bX as SubjectFieldType, b$ as SubjectRef,
|
|
1
|
+
import { bf as ProductSort, c1 as TokenIntrospection, bK as Shop, bp as Region, bt as RegionPostalCode, d as AddressSuggestions, bd as ProductConnection, ba as Product, D as Connection, B as Collection, aw as LocationListParams, at as Location, aC as NearestLocation, bO as StockLevel, bu as RestockSubscriptionInput, bv as RestockSubscriptionResult, p as CartLineInput, C as Cart, s as CartLineUpdateInput, i as CartBuyerInput, b as AddressInput, _ as DeliveryOptions, b0 as PaymentMethods, Y as DeliveryInput, ao as InvoiceRequest, bn as RecommendationPlacement, v as CartRecommendations, x as CheckoutInput, z as CheckoutResult, bk as PromotionsList, aY as PaymentConfig, b5 as PaymentSubmitInput, aU as PaymentAttemptResult, c3 as TrackingLookupInput, c4 as TrackingLookupResult, K as CustomerIdentifier, S as CustomerSessionInput, Q as CustomerSession, F as CustomerCapabilities, N as CustomerRegisterInput, O as CustomerRegisterResult, V as CustomerVerifyRegistrationInput, L as CustomerPasswordLoginInput, T as CustomerSetPasswordInput, P as CustomerResetPasswordInput, E as Customer, U as CustomerUpdateInput, R as CustomerSessionInfo, bl as ReauthInput, bm as ReauthResult, J as CustomerEmailCodeInput, H as CustomerEmailChangeInput, I as CustomerEmailChangeRequested, G as CustomerEmailChangeConfirmInput, W as DataExportFile, A as AccountDeleteInput, aF as Order, ai as InvoiceConnection, bC as ShipmentConnection, bx as ReturnRequestInput, bw as ReturnRequest, ap as InvoiceResult, b7 as PendingPayment, al as InvoiceFileKind, ak as InvoiceFile, a5 as FiscalProfile, a6 as FiscalProfileInput, bT as Subject, bY as SubjectInput, b_ as SubjectPatch, a as Address, bZ as SubjectKind, c0 as Theme, aR as Page, ay as Menu, e as Article, aA as Money, g as AvailabilityStatus, r as CartLineProblem, f as Availability, ag as InsufficientStockLine, o as CartLine, bg as ProductVariant, X as DeclineCode, b6 as PaymentVoucher, b1 as PaymentNextStep, t as CartPromotions, bi as PromotionReward, aj as InvoiceDoc, bB as Shipment, aD as NextAction, aJ as OrderProgress, bH as ShipmentStatus, bD as ShipmentEvent, bV as SubjectCatalogNode, bW as SubjectField, Z as DeliveryMethod, c6 as UnavailableRateProvider, aS as PageInfo } from './account-settings-Cio2mAvd.js';
|
|
2
|
+
export { c as AddressSuggestion, h as CartBuyer, j as CartCost, k as CartDelivery, l as CartDiscountCode, m as CartDiscountLine, n as CartInvoice, q as CartLineMerchandise, u as CartRecommendation, w as CheckoutInfo, y as CheckoutPayment, M as CustomerPreferences, $ as Facet, a0 as FacetValue, a1 as FiscalDocumentEvidence, a2 as FiscalDocumentSource, a3 as FiscalIdentity, a4 as FiscalIdentityInput, a7 as FiscalVerification, a8 as GeoHint, a9 as IdentityCapture, aa as IdentityDocumentSpec, ab as IdentityFieldRule, ac as IdentityRulesV1, ad as IdentityStrategy, ae as Image, af as InsufficientStockDetails, ah as InvoiceAction, am as InvoiceListNode, an as InvoiceReceiver, aq as InvoiceStage, ar as InvoiceSummary, as as InvoicingCapabilities, au as LocationContacts, av as LocationKind, ax as LocationPickup, az as MenuItem, aB as MoneyRange, aE as NextActionKind, aG as OrderLine, aH as OrderPickup, aI as OrderProblem, aK as OrderProgressStep, aL as OrderRef, aM as OrderSection, aN as OrderShippingService, aO as OrderStage, aP as OrderStepKey, aQ as OrderStepState, aT as PaymentAction, aV as PaymentAttemptStatus, aW as PaymentClient, aX as PaymentClientCsp, aZ as PaymentFlow, a_ as PaymentInfo, a$ as PaymentMethod, b2 as PaymentOption, b3 as PaymentOptionKey, b4 as PaymentPoint, b8 as PendingPaymentVoucher, b9 as PickupOption, bb as ProductAttributeValue, bc as ProductCategory, be as ProductOption, bh as PromotionAnnouncement, bj as PromotionTier, bo as Refund, bq as RegionFiscalEntry, br as RegionFiscalId, bs as RegionPaymentMethod, by as SEO, bz as Section, bA as SelectedOption, bE as ShipmentKind, bF as ShipmentListNode, bG as ShipmentMap, bI as ShipmentsSummary, bJ as ShippingRate, bL as ShopBranch, bM as ShopContact, bN as ShopPolicies, bP as StorefrontError, bQ as StorefrontErrorBody, bR as StorefrontErrorCode, bS as StorefrontErrorInit, bU as SubjectCatalog, bX as SubjectFieldType, b$ as SubjectRef, c2 as TrackingEventView, c5 as TrackingView, c7 as dataExportBytes, c8 as isAccountDeleteBlocked, c9 as isReauthRequired, ca as isStorefrontError, cb as safeExportFilename } from './account-settings-Cio2mAvd.js';
|
|
3
3
|
import { GeoPoint } from './geo.js';
|
|
4
4
|
export { OpenStatus, OpeningHours } from './geo.js';
|
|
5
5
|
|
|
@@ -363,6 +363,15 @@ declare function createStorefrontClient(config: StorefrontClientOptions): {
|
|
|
363
363
|
*/
|
|
364
364
|
get: (id: string, options?: RequestOptions) => Promise<CheckoutResult | null>;
|
|
365
365
|
};
|
|
366
|
+
/**
|
|
367
|
+
* Public "where is my order" lookup (`POST /storefront/customer/track`): by order number + email, or by the guide
|
|
368
|
+
* printed on the parcel. No buyer session. Every failure is one of three plain answers, so a miss never tells a
|
|
369
|
+
* real order from an unknown one: `not_found`, `rate_limited` (with `retryAfter` seconds when known) or
|
|
370
|
+
* `unavailable` (the server or the network failed). Needs the store to enable the route.
|
|
371
|
+
*/
|
|
372
|
+
tracking: {
|
|
373
|
+
lookup: (input: TrackingLookupInput, options?: WriteOptions) => Promise<TrackingLookupResult>;
|
|
374
|
+
};
|
|
366
375
|
customer: {
|
|
367
376
|
/** Sends a one-time code by email or SMS/WhatsApp. */
|
|
368
377
|
requestOtp: (identifier: CustomerIdentifier, options?: WriteOptions) => Promise<void>;
|
|
@@ -1170,4 +1179,4 @@ declare function pageRange(state: Pick<ListPageState, 'query' | 'pageInfo' | 'co
|
|
|
1170
1179
|
total: number | null;
|
|
1171
1180
|
} | null;
|
|
1172
1181
|
|
|
1173
|
-
export { AccountDeleteInput, type AccountListParams, Address, AddressInput, type AddressSuggestParams, AddressSuggestions, Article, type ArticleListParams, Availability, type AvailabilityLocale, type AvailabilityMessageKey, type AvailabilityMessages, AvailabilityStatus, type AvailabilityTone, type AvailabilityView, type AvailabilityViewOptions, CLIENT_IP_HEADER, COUNTRY_HEADERS, Cart, CartBuyerInput, CartLine, CartLineInput, CartLineProblem, type CartLineProblemView, CartLineUpdateInput, CartPromotions, CartRecommendations, CheckoutInput, CheckoutResult, Collection, type CollectionListParams, Connection, Customer, CustomerCapabilities, CustomerEmailChangeConfirmInput, CustomerEmailChangeInput, CustomerEmailChangeRequested, CustomerEmailCodeInput, CustomerIdentifier, CustomerPasswordLoginInput, CustomerRegisterInput, CustomerRegisterResult, CustomerResetPasswordInput, CustomerSession, CustomerSessionInfo, CustomerSessionInput, CustomerSetPasswordInput, CustomerUpdateInput, CustomerVerifyRegistrationInput, DEFAULT_FIT_TAG_PREFIX, DataExportFile, DeclineCode, type DeliveryChoice, type DeliveryChoiceKind, DeliveryInput, DeliveryMethod, type DeliveryNotices, DeliveryOptions, type DiagnoseOptions, type DiscountBarState, type DiscountBarView, type FetchLike, FiscalProfile, FiscalProfileInput, type FormatMoneyOptions, GeoPoint, InsufficientStockLine, InvoiceConnection, InvoiceDoc, InvoiceFile, InvoiceFileKind, type InvoiceGroup, type InvoiceListParams, InvoiceRequest, InvoiceResult, LIST_URL_EN, LIST_URL_ES, type ListPageState, type ListQuery, type ListUrlNames, Location, LocationListParams, MAX_SUBJECT_YEAR, MIN_SUBJECT_YEAR, MISSING_WEIGHT, type MarketInfo, type MarketSuggestion, Menu, Money, NOTE_MAX_LENGTH, NearestLocation, NextAction, Order, type OrderListParams, OrderProgress, PAYMENT_CHOICE_REFUSED_FIELD, PICKUP_STEPS, PRIVATE_MASK, Page, PageInfo, type PaginationParams, PaymentAttemptResult, PaymentConfig, type PaymentErrorClass, type PaymentErrorClassKind, type PaymentErrorKind, type PaymentErrorLike, type PaymentErrorView, type PaymentLocale, type PaymentMessageKey, type PaymentMessages, PaymentMethods, PaymentNextStep, type PaymentOutcome, type PaymentOutcomeKind, PaymentSubmitInput, PaymentVoucher, PendingPayment, type PreviewOptions, Product, ProductConnection, type ProductListParams, ProductSort, ProductVariant, type PromoProgressView, type PromotionLocale, type PromotionMessageKey, type PromotionMessages, PromotionReward, PromotionsList, type QueryParams, type QueryValue, ReauthInput, ReauthResult, RecommendationPlacement, Region, RegionPostalCode, type RequestOptions, type ResolveAvailabilityOptions, type ResolvedSubject, RestockSubscriptionInput, RestockSubscriptionResult, ReturnRequest, ReturnRequestInput, SHIPPING_STEPS, SUBJECT_CATALOG_PAGE_BYTES, Shipment, ShipmentConnection, ShipmentEvent, type ShipmentListParams, ShipmentStatus, type ShippingBarState, type ShippingBarView, Shop, StockLevel, type StorefrontClient, type StorefrontClientOptions, type StorefrontRequestContext, type StorefrontResponseContext, Subject, SubjectCatalogNode, SubjectField, SubjectInput, SubjectKind, type SubjectOption, SubjectPatch, type SubjectProblemCode, type SubjectProblems, type SubjectValues, Theme, TokenIntrospection, UnavailableRateProvider, type WriteOptions, accountListQuery, appendParams, availabilityLocale, availabilityMessages, availabilityView, cartLineProblemView, clampPercent, classifyPaymentError, coversYear, createStorefrontClient, declineMessage, declineMessageKey, deliveryInput, deliveryNotices, diagnose, firstPageQuery, fitTag, fitTagsAny, formatAvailabilityMessage, formatMoney, formatVoucherExpiry, generateIdempotencyKey, groupInvoiceDocs, hreflangLinks, invoiceFileBytes, isFiltered, isMasked, isTestInvoice, isTestShipment, isTokenPublishable, lineShipDate, lineShipLabel, listApiParams, listHref, listQueryString, maskToken, negotiateLocale, nextAction, nextPageQuery, normalizeClientIp, normalizeNote, opsSaysNotRetryable, orderProgress, orderShipments, pagePosition, pageRange, parseDelivery, parseMoney, parseProductFilters, paymentErrorView, paymentIdempotencyKey, paymentMessages, paymentOutcome, preferredLanguages, previousPageQuery, productAvailability, productListQuery, promoProgressView, promotionMessages, readListQuery, reconcileSubjectValues, repairPath, resolveAvailability, resolveSubject, rewardLabel, safeHttpsUrl, safeInvoiceFilename, safeTrackingUrl, schemaAvailability, shipmentsStatus, sortTrackingEvents, splitSubjectTree, storefrontDomainHeader, subjectFields, subjectLevels, subjectOptions, suggestMarket, toMoney, visitorCountry };
|
|
1182
|
+
export { AccountDeleteInput, type AccountListParams, Address, AddressInput, type AddressSuggestParams, AddressSuggestions, Article, type ArticleListParams, Availability, type AvailabilityLocale, type AvailabilityMessageKey, type AvailabilityMessages, AvailabilityStatus, type AvailabilityTone, type AvailabilityView, type AvailabilityViewOptions, CLIENT_IP_HEADER, COUNTRY_HEADERS, Cart, CartBuyerInput, CartLine, CartLineInput, CartLineProblem, type CartLineProblemView, CartLineUpdateInput, CartPromotions, CartRecommendations, CheckoutInput, CheckoutResult, Collection, type CollectionListParams, Connection, Customer, CustomerCapabilities, CustomerEmailChangeConfirmInput, CustomerEmailChangeInput, CustomerEmailChangeRequested, CustomerEmailCodeInput, CustomerIdentifier, CustomerPasswordLoginInput, CustomerRegisterInput, CustomerRegisterResult, CustomerResetPasswordInput, CustomerSession, CustomerSessionInfo, CustomerSessionInput, CustomerSetPasswordInput, CustomerUpdateInput, CustomerVerifyRegistrationInput, DEFAULT_FIT_TAG_PREFIX, DataExportFile, DeclineCode, type DeliveryChoice, type DeliveryChoiceKind, DeliveryInput, DeliveryMethod, type DeliveryNotices, DeliveryOptions, type DiagnoseOptions, type DiscountBarState, type DiscountBarView, type FetchLike, FiscalProfile, FiscalProfileInput, type FormatMoneyOptions, GeoPoint, InsufficientStockLine, InvoiceConnection, InvoiceDoc, InvoiceFile, InvoiceFileKind, type InvoiceGroup, type InvoiceListParams, InvoiceRequest, InvoiceResult, LIST_URL_EN, LIST_URL_ES, type ListPageState, type ListQuery, type ListUrlNames, Location, LocationListParams, MAX_SUBJECT_YEAR, MIN_SUBJECT_YEAR, MISSING_WEIGHT, type MarketInfo, type MarketSuggestion, Menu, Money, NOTE_MAX_LENGTH, NearestLocation, NextAction, Order, type OrderListParams, OrderProgress, PAYMENT_CHOICE_REFUSED_FIELD, PICKUP_STEPS, PRIVATE_MASK, Page, PageInfo, type PaginationParams, PaymentAttemptResult, PaymentConfig, type PaymentErrorClass, type PaymentErrorClassKind, type PaymentErrorKind, type PaymentErrorLike, type PaymentErrorView, type PaymentLocale, type PaymentMessageKey, type PaymentMessages, PaymentMethods, PaymentNextStep, type PaymentOutcome, type PaymentOutcomeKind, PaymentSubmitInput, PaymentVoucher, PendingPayment, type PreviewOptions, Product, ProductConnection, type ProductListParams, ProductSort, ProductVariant, type PromoProgressView, type PromotionLocale, type PromotionMessageKey, type PromotionMessages, PromotionReward, PromotionsList, type QueryParams, type QueryValue, ReauthInput, ReauthResult, RecommendationPlacement, Region, RegionPostalCode, type RequestOptions, type ResolveAvailabilityOptions, type ResolvedSubject, RestockSubscriptionInput, RestockSubscriptionResult, ReturnRequest, ReturnRequestInput, SHIPPING_STEPS, SUBJECT_CATALOG_PAGE_BYTES, Shipment, ShipmentConnection, ShipmentEvent, type ShipmentListParams, ShipmentStatus, type ShippingBarState, type ShippingBarView, Shop, StockLevel, type StorefrontClient, type StorefrontClientOptions, type StorefrontRequestContext, type StorefrontResponseContext, Subject, SubjectCatalogNode, SubjectField, SubjectInput, SubjectKind, type SubjectOption, SubjectPatch, type SubjectProblemCode, type SubjectProblems, type SubjectValues, Theme, TokenIntrospection, TrackingLookupInput, TrackingLookupResult, UnavailableRateProvider, type WriteOptions, accountListQuery, appendParams, availabilityLocale, availabilityMessages, availabilityView, cartLineProblemView, clampPercent, classifyPaymentError, coversYear, createStorefrontClient, declineMessage, declineMessageKey, deliveryInput, deliveryNotices, diagnose, firstPageQuery, fitTag, fitTagsAny, formatAvailabilityMessage, formatMoney, formatVoucherExpiry, generateIdempotencyKey, groupInvoiceDocs, hreflangLinks, invoiceFileBytes, isFiltered, isMasked, isTestInvoice, isTestShipment, isTokenPublishable, lineShipDate, lineShipLabel, listApiParams, listHref, listQueryString, maskToken, negotiateLocale, nextAction, nextPageQuery, normalizeClientIp, normalizeNote, opsSaysNotRetryable, orderProgress, orderShipments, pagePosition, pageRange, parseDelivery, parseMoney, parseProductFilters, paymentErrorView, paymentIdempotencyKey, paymentMessages, paymentOutcome, preferredLanguages, previousPageQuery, productAvailability, productListQuery, promoProgressView, promotionMessages, readListQuery, reconcileSubjectValues, repairPath, resolveAvailability, resolveSubject, rewardLabel, safeHttpsUrl, safeInvoiceFilename, safeTrackingUrl, schemaAvailability, shipmentsStatus, sortTrackingEvents, splitSubjectTree, storefrontDomainHeader, subjectFields, subjectLevels, subjectOptions, suggestMarket, toMoney, visitorCountry };
|
package/dist/index.js
CHANGED
|
@@ -414,6 +414,26 @@ function createStorefrontClient(config) {
|
|
|
414
414
|
*/
|
|
415
415
|
get: (id, options) => getOrNull(`/storefront/checkouts/${enc(id)}`, void 0, options)
|
|
416
416
|
},
|
|
417
|
+
/**
|
|
418
|
+
* Public "where is my order" lookup (`POST /storefront/customer/track`): by order number + email, or by the guide
|
|
419
|
+
* printed on the parcel. No buyer session. Every failure is one of three plain answers, so a miss never tells a
|
|
420
|
+
* real order from an unknown one: `not_found`, `rate_limited` (with `retryAfter` seconds when known) or
|
|
421
|
+
* `unavailable` (the server or the network failed). Needs the store to enable the route.
|
|
422
|
+
*/
|
|
423
|
+
tracking: {
|
|
424
|
+
lookup: async (input, options) => {
|
|
425
|
+
try {
|
|
426
|
+
const tracking = await write("POST", "/storefront/customer/track", input, options);
|
|
427
|
+
return tracking && Array.isArray(tracking.events) ? { status: "found", tracking } : { status: "not_found" };
|
|
428
|
+
} catch (err) {
|
|
429
|
+
if (err instanceof StorefrontError) {
|
|
430
|
+
if (err.status === 429) return err.retryAfter ? { status: "rate_limited", retryAfter: err.retryAfter } : { status: "rate_limited" };
|
|
431
|
+
if (err.status === 400 || err.status === 404 || err.status === 422) return { status: "not_found" };
|
|
432
|
+
}
|
|
433
|
+
return { status: "unavailable" };
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
},
|
|
417
437
|
customer: {
|
|
418
438
|
/** Sends a one-time code by email or SMS/WhatsApp. */
|
|
419
439
|
requestOtp: (identifier, options) => write("POST", "/storefront/customer/otp", identifier, options),
|