@behio/storefront-sdk 2.11.0 → 2.13.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.
@@ -482,6 +482,8 @@ interface ProductVariant {
482
482
  stockQuantity?: number | null;
483
483
  /** "Only X left" for this variant — same contract as ProductListItem.lowStockRemaining. */
484
484
  lowStockRemaining?: number | null;
485
+ /** Most pieces the cart accepts for this variant; null = uncapped or hidden stock. SDK 2.13.0. */
486
+ maxPurchasableQuantity?: number | null;
485
487
  /**
486
488
  * Cover image URL for the variant. Falls back to the parent product's
487
489
  * cover when the variant has no photo of its own — see `imageIsInherited`.
@@ -837,6 +839,10 @@ interface ProductAssetGroup {
837
839
  items: ProductAssetItem[];
838
840
  }
839
841
  interface ProductDetail extends ProductListItem {
842
+ /** Most pieces the cart accepts (stock, plus safetyStock under BACKORDER);
843
+ * null when uncapped or the shop hides stock counts. Cap the PDP quantity
844
+ * stepper with it, it is exactly the cart rule. SDK 2.13.0. */
845
+ maxPurchasableQuantity?: number | null;
840
846
  longDescription?: string;
841
847
  /**
842
848
  * @deprecated Legacy per-listing images. Prefer `media`. Each carries its
@@ -1205,6 +1211,13 @@ interface CheckoutPreview {
1205
1211
  giftCardDeducted: number;
1206
1212
  roundingAdjustment: number;
1207
1213
  grandTotal: number;
1214
+ /** VAT contained in `grandTotal` split by rate: order discounts (always
1215
+ * VAT-inclusive) reduce base and VAT per rate, shipping and the payment fee
1216
+ * carry the goods rates. Same numbers as the invoice. SDK 2.12.0. */
1217
+ taxBreakdown?: TaxBreakdownLine[];
1218
+ /** VAT contained in `grandTotal`, the sum of `taxBreakdown[].taxAmount`.
1219
+ * `taxTotal` is the goods VAT before order discounts. SDK 2.12.0. */
1220
+ vatTotal?: number;
1208
1221
  previewToken: string;
1209
1222
  expiresAt: number;
1210
1223
  }
@@ -1275,6 +1288,9 @@ interface CartItemProduct {
1275
1288
  sku: string;
1276
1289
  imageUrl?: string;
1277
1290
  inStock: boolean;
1291
+ /** Pieces left for an "only X left" note on the cart line; null when the
1292
+ * shop does not track stock, hides the nudge or has plenty. SDK 2.13.0. */
1293
+ lowStockRemaining?: number | null;
1278
1294
  currentPrice: number | null;
1279
1295
  /** Minimum order quantity (units); null = no minimum. Clamp the cart
1280
1296
  * stepper's lower bound to this (GAP-48). */
@@ -1362,8 +1378,11 @@ interface Cart {
1362
1378
  * `INCL_VAT`, VAT excluded when it runs `EXCL_VAT`. Not the payable amount,
1363
1379
  * that is `grandTotal`. */
1364
1380
  subtotal: number;
1365
- /** Discount from the applied code. Always based on `subtotal`, i.e. on the
1366
- * prices the customer sees, so "10 % off 200" is 20 in both price modes. */
1381
+ /** Discount from the applied code, VAT-inclusive. The base is always the
1382
+ * VAT-inclusive amount, also when the shop shows prices without VAT: a
1383
+ * discount is never taken from the net base (SDK 2.12.0; before, "10 % off
1384
+ * 200 net" was 20, now it is 24.20 at 21 %). It lowers base and VAT, see
1385
+ * `taxBreakdown` and `vatTotal`. */
1367
1386
  discountTotal: number;
1368
1387
  discount?: CartDiscount;
1369
1388
  /** Auto-apply promotion discount lines (sale/BOGO). */
@@ -1380,11 +1399,16 @@ interface Cart {
1380
1399
  * back to the catalog price), under `EXCL_VAT` it is added on top. Render
1381
1400
  * this as the cart total; do not add `taxTotal` to it. */
1382
1401
  grandTotal: number;
1383
- /** VAT contained in the prices (`INCL_VAT`) or added on top of them
1384
- * (`EXCL_VAT`), across all lines (GAP-30). An estimate finalized at checkout
1385
- * once the shipping country is known. */
1402
+ /** Goods VAT BEFORE order discounts: contained in the prices (`INCL_VAT`) or
1403
+ * added on top (`EXCL_VAT`). Use it for the goods subtotal
1404
+ * (`subtotal` net + `taxTotal`); the VAT the customer pays is `vatTotal`. */
1386
1405
  taxTotal: number;
1387
- /** VAT split by rate for "DPH 21 %: X Kč" summary rows. Empty for a
1406
+ /** VAT contained in `grandTotal`, after the order discount, as on the
1407
+ * invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1408
+ vatTotal?: number;
1409
+ /** VAT of the payable amount split by rate for "DPH 21 %: X Kč" rows. The
1410
+ * order discount reduces base and VAT per rate (since SDK 2.12.0; before it
1411
+ * showed the VAT of the goods before the discount). Empty for a
1388
1412
  * non-VAT-payer shop. */
1389
1413
  taxBreakdown: TaxBreakdownLine[];
1390
1414
  /** Delivery country set via `cart.setDestination()`, null until known. SDK 1.17.0. */
@@ -1497,6 +1521,14 @@ interface CheckoutInput {
1497
1521
  termsConsent?: boolean;
1498
1522
  gdprConsent?: boolean;
1499
1523
  newsletterOptIn?: boolean;
1524
+ /**
1525
+ * Consent to start delivering digital content (courses, downloads,
1526
+ * services) before the withdrawal period ends, which waives the right of
1527
+ * withdrawal (EU Directive 2011/83 art. 16(m)). Render the checkbox for carts
1528
+ * without physical goods (`cart.requiresShipping === false`). Stored on the
1529
+ * order consent record; it does not block the order. SDK 2.13.0.
1530
+ */
1531
+ digitalDeliveryConsent?: boolean;
1500
1532
  /**
1501
1533
  * Consent to marketing SMS, from the optional checkout checkbox. Render it
1502
1534
  * only when `ShopInfo.checkout.collectSmsConsent` is true; shops that do not
@@ -1610,6 +1642,8 @@ interface OrderTracking {
1610
1642
  paymentFee?: number | null;
1611
1643
  discountTotal?: number;
1612
1644
  taxTotal?: number;
1645
+ /** VAT contained in `grandTotal`, as on the invoice. SDK 2.12.0. */
1646
+ vatTotal?: number;
1613
1647
  taxBreakdown?: TaxBreakdownLine[];
1614
1648
  /** Shipping method as the customer chose it (SDK 2.8.0). */
1615
1649
  shippingMethodName?: string | null;
@@ -1642,6 +1676,18 @@ interface OrderStatusHistory {
1642
1676
  changedBy?: string;
1643
1677
  createdAt: number;
1644
1678
  }
1679
+ /** Bank transfer details of an unpaid order (SDK 2.13.0). */
1680
+ interface OrderPaymentInstructions {
1681
+ accountNumber: string | null;
1682
+ iban: string | null;
1683
+ bic: string | null;
1684
+ bankName: string | null;
1685
+ /** Digits only, at most 10 (Czech banks); from the method pattern with the order number. */
1686
+ variableSymbol: string | null;
1687
+ amount: number;
1688
+ currency: string;
1689
+ instructions: string | null;
1690
+ }
1645
1691
  interface OrderDetail extends OrderListItem {
1646
1692
  /** Payment is recorded; access delivery will retry automatically. Do not place a duplicate order. */
1647
1693
  contentDeliveryPending?: boolean;
@@ -1651,6 +1697,10 @@ interface OrderDetail extends OrderListItem {
1651
1697
  shippingMethodName?: string | null;
1652
1698
  /** Payment method in the order language (SDK 2.8.0). */
1653
1699
  paymentMethodName?: string | null;
1700
+ /** Bank transfer details while the order is unpaid; render them on the
1701
+ * confirmation (account, IBAN, variable symbol, amount). Null for other
1702
+ * methods and paid orders. SDK 2.13.0. */
1703
+ paymentInstructions?: OrderPaymentInstructions | null;
1654
1704
  /** Pickup point the customer chose, a public place (SDK 2.8.0). */
1655
1705
  pickupPoint?: OrderPickupPoint | null;
1656
1706
  /** Parcels the customer can follow (SDK 2.8.0). */
@@ -1662,9 +1712,15 @@ interface OrderDetail extends OrderListItem {
1662
1712
  phone?: string;
1663
1713
  customerNote?: string;
1664
1714
  subtotal: number;
1715
+ /** Goods VAT before order discounts (goods subtotal = `subtotal` + `taxTotal`). */
1665
1716
  taxTotal: number;
1666
- /** VAT split by rate (GAP-30), summed from the order lines. Render
1667
- * "DPH 21 %: X Kč" rows. Empty for a non-VAT order. */
1717
+ /** VAT contained in `grandTotal` (after discounts, incl. shipping), the same
1718
+ * as on the invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1719
+ vatTotal?: number;
1720
+ /** VAT of the amount paid split by rate (GAP-30) for "DPH 21 %: X Kč" rows.
1721
+ * Order discounts reduce base and VAT, shipping and the payment fee carry
1722
+ * the goods rates (since SDK 2.12.0, matching the invoice). Empty for a
1723
+ * non-VAT order. */
1668
1724
  taxBreakdown: TaxBreakdownLine[];
1669
1725
  /** DOMESTIC, OSS, REVERSE_CHARGE (no VAT, buyer accounts for it) or EXPORT (no VAT, outside EU). SDK 1.17.0. */
1670
1726
  vatMode?: "DOMESTIC" | "OSS" | "REVERSE_CHARGE" | "EXPORT" | null;
@@ -3985,4 +4041,4 @@ declare function clearCartSummary(): void;
3985
4041
  /** Publish only authoritative current totals; server cart consumers call this after hydration and revalidation. */
3986
4042
  declare function publishCartSummary(summary: CartSummaryEvent): void;
3987
4043
 
3988
- export { type CourseCommentReply as $, type ActivePromotion as A, BehioStorefront as B, type CookieConsent as C, type Cart as D, type CartBundleLine as E, type CartBundleLineItem as F, type CartDiscount as G, type CartItem as H, type CartItemProduct as I, type CartLinkClaimed as J, type CartPromotion as K, type CartSummaryEvent as L, type Category as M, type CategoryDetail as N, type CertificateVerification as O, type ProductDetail as P, type CheckoutAddress as Q, type CheckoutInput as R, type SdkResult as S, type CheckoutPaymentMethod as T, type CheckoutPreview as U, type CheckoutResult as V, type CheckoutSettings as W, type CookieConsentInput as X, type CourseAttachment as Y, type CourseCertificate as Z, type CourseComment as _, type ProductVariant as a, type OrderShipment as a$, type CourseCommentsList as a0, type CourseDetail as a1, type CourseLesson as a2, type CourseListItem as a3, type CourseModule as a4, type CoursePostedComment as a5, type CourseProgress as a6, type CourseTutorMessage as a7, type CourseTutorThread as a8, type CrossSellItem as a9, type LessonNote as aA, type LessonQuiz as aB, type LoginInput as aC, type LoyaltyBalance as aD, type LoyaltyNextTier as aE, type LoyaltyProgram as aF, type LoyaltyQuery as aG, type LoyaltyReferralResult as aH, type LoyaltySummary as aI, type LoyaltyTier as aJ, type LoyaltyTierPerks as aK, type LoyaltyTransaction as aL, type Menu as aM, type MenuItem as aN, type MenuItemRef as aO, type MenuItemType as aP, type MessageResponse as aQ, type NewsletterOptInDefault as aR, type NewsletterSubscribeInput as aS, type NewsletterSubscribeResult as aT, type NewsletterUnsubscribeResult as aU, type OrderAccessRequestResponse as aV, type OrderAccessVerifyResponse as aW, type OrderDetail as aX, type OrderItem as aY, type OrderListItem as aZ, type OrderPickupPoint as a_, type CurrencyDisplayFormat as aa, type CustomerAddress as ab, type CustomerBadge as ac, type CustomerChallenge as ad, type CustomerGamification as ae, type CustomerGamificationQuery as af, type CustomerProfile as ag, type DigitalDownload as ah, type DownloadUrl as ai, type Facet as aj, type FacetAvailability as ak, type FacetCategory as al, type FacetLabel as am, type FacetPriceRange as an, type FacetRange as ao, type FacetRatingBucket as ap, type FacetValue as aq, type FacetsResponse as ar, type FilterField as as, type FulfillmentStatus as at, FulfillmentStatuses as au, type GamificationRefreshResult as av, type GiftCardBalance as aw, type GiftCardPurchaseInput as ax, type GiftCardPurchaseResult as ay, type GiftCardSummary as az, type StorefrontFormFieldError as b, type ShopScriptType as b$, type OrderStatus as b0, type OrderStatusHistory as b1, OrderStatuses as b2, type OrderTracking as b3, type Page as b4, type PageAttachment as b5, type PageDetail as b6, type PaginatedResponse as b7, type PaymentInstrument as b8, type PaymentStatus as b9, type ProductsQuery as bA, type QuizAnswerInput as bB, type QuizAnswerResult as bC, type QuizQuestion as bD, type QuizResult as bE, type QuoteItem as bF, type QuoteRequest as bG, type RegisterInput as bH, type RegisterResult as bI, type RequestInterceptor as bJ, type RequestInterceptorConfig as bK, type ResponseInterceptor as bL, type ResponseInterceptorData as bM, type ReturnRequest as bN, type ReturnRequestItem as bO, type ReturnStatus as bP, type ReturnStatusItem as bQ, type ReturnableOrder as bR, type ReturnableOrderItem as bS, type SdkError as bT, type ShippingMethodSummary as bU, type ShippingQuote as bV, type ShippingQuoteInput as bW, type ShopAppearance as bX, type ShopInfo as bY, type ShopScript as bZ, type ShopScriptPlacement as b_, PaymentStatuses as ba, type PaymentSwift as bb, type PickupPoint as bc, type PickupPointHours as bd, type PickupPointsInput as be, type PickupWidgetConfig as bf, type PriceDisplay as bg, type ProductAssetGroup as bh, type ProductAssetItem as bi, type ProductAvailability as bj, type ProductGroup as bk, type ProductLabel as bl, type ProductListItem as bm, type ProductMedia as bn, type ProductMediaVariant as bo, type ProductParameter as bp, type ProductParameterGroup as bq, type ProductParametersResponse as br, type ProductPrice as bs, type ProductPromotionSummary as bt, type ProductReview as bu, type ProductReviewsResponse as bv, type ProductSibling as bw, ProductSort as bx, type ProductSortValue as by, type ProductVolumePrice as bz, type AddToCartInput as c, type ShopScripts as c0, type ShopSeo as c1, type ShopSeoIdentity as c2, type SiteFormField as c3, type SiteFormFieldOption as c4, type SiteFormFieldType as c5, type Sitemap as c6, type SitemapEntry as c7, type StockBehavior as c8, type StockMode as c9, type StorefrontForm as ca, type StorefrontFormFieldErrorCode as cb, type StorefrontFormFile as cc, type StorefrontFormSettings as cd, type StorefrontFormSubmitInput as ce, type StorefrontFormSubmitResult as cf, type StorefrontFormUpload as cg, type SubmitQuoteInput as ch, type SubmitReturnInput as ci, type SubmitReviewInput as cj, type Subscription as ck, type SubscriptionAction as cl, type SubscriptionFrequency as cm, type SubscriptionItem as cn, type SubscriptionStatus as co, type TaxBreakdownLine as cp, type VariantAxis as cq, type VariantAxisValue as cr, type WishlistItem as cs, clearCartSummary as ct, err as cu, ok as cv, publishCartSummary as cw, toSdkError as cx, type AddressDetail as d, type AddressSuggestion as e, type AddressType as f, AddressTypes as g, type AuthTokens as h, type BackInStockSubscription as i, type BadgeTone as j, BehioApiError as k, type BehioErrorCode as l, type BehioEventHandler as m, type BehioEventType as n, BehioNetworkError as o, type BehioStorefrontConfig as p, type Blog as q, type BlogPostDetail as r, type BlogPostListItem as s, type BlogPostsPage as t, type BlogPostsQuery as u, type BlogSettings as v, type BlogTag as w, type Bundle as x, type BundleCatalogQuery as y, type BundleItem as z };
4044
+ export { type CourseCommentReply as $, type ActivePromotion as A, BehioStorefront as B, type CookieConsent as C, type Cart as D, type CartBundleLine as E, type CartBundleLineItem as F, type CartDiscount as G, type CartItem as H, type CartItemProduct as I, type CartLinkClaimed as J, type CartPromotion as K, type CartSummaryEvent as L, type Category as M, type CategoryDetail as N, type CertificateVerification as O, type ProductDetail as P, type CheckoutAddress as Q, type CheckoutInput as R, type SdkResult as S, type CheckoutPaymentMethod as T, type CheckoutPreview as U, type CheckoutResult as V, type CheckoutSettings as W, type CookieConsentInput as X, type CourseAttachment as Y, type CourseCertificate as Z, type CourseComment as _, type ProductVariant as a, type OrderPickupPoint as a$, type CourseCommentsList as a0, type CourseDetail as a1, type CourseLesson as a2, type CourseListItem as a3, type CourseModule as a4, type CoursePostedComment as a5, type CourseProgress as a6, type CourseTutorMessage as a7, type CourseTutorThread as a8, type CrossSellItem as a9, type LessonNote as aA, type LessonQuiz as aB, type LoginInput as aC, type LoyaltyBalance as aD, type LoyaltyNextTier as aE, type LoyaltyProgram as aF, type LoyaltyQuery as aG, type LoyaltyReferralResult as aH, type LoyaltySummary as aI, type LoyaltyTier as aJ, type LoyaltyTierPerks as aK, type LoyaltyTransaction as aL, type Menu as aM, type MenuItem as aN, type MenuItemRef as aO, type MenuItemType as aP, type MessageResponse as aQ, type NewsletterOptInDefault as aR, type NewsletterSubscribeInput as aS, type NewsletterSubscribeResult as aT, type NewsletterUnsubscribeResult as aU, type OrderAccessRequestResponse as aV, type OrderAccessVerifyResponse as aW, type OrderDetail as aX, type OrderItem as aY, type OrderListItem as aZ, type OrderPaymentInstructions as a_, type CurrencyDisplayFormat as aa, type CustomerAddress as ab, type CustomerBadge as ac, type CustomerChallenge as ad, type CustomerGamification as ae, type CustomerGamificationQuery as af, type CustomerProfile as ag, type DigitalDownload as ah, type DownloadUrl as ai, type Facet as aj, type FacetAvailability as ak, type FacetCategory as al, type FacetLabel as am, type FacetPriceRange as an, type FacetRange as ao, type FacetRatingBucket as ap, type FacetValue as aq, type FacetsResponse as ar, type FilterField as as, type FulfillmentStatus as at, FulfillmentStatuses as au, type GamificationRefreshResult as av, type GiftCardBalance as aw, type GiftCardPurchaseInput as ax, type GiftCardPurchaseResult as ay, type GiftCardSummary as az, type StorefrontFormFieldError as b, type ShopScriptPlacement as b$, type OrderShipment as b0, type OrderStatus as b1, type OrderStatusHistory as b2, OrderStatuses as b3, type OrderTracking as b4, type Page as b5, type PageAttachment as b6, type PageDetail as b7, type PaginatedResponse as b8, type PaymentInstrument as b9, type ProductVolumePrice as bA, type ProductsQuery as bB, type QuizAnswerInput as bC, type QuizAnswerResult as bD, type QuizQuestion as bE, type QuizResult as bF, type QuoteItem as bG, type QuoteRequest as bH, type RegisterInput as bI, type RegisterResult as bJ, type RequestInterceptor as bK, type RequestInterceptorConfig as bL, type ResponseInterceptor as bM, type ResponseInterceptorData as bN, type ReturnRequest as bO, type ReturnRequestItem as bP, type ReturnStatus as bQ, type ReturnStatusItem as bR, type ReturnableOrder as bS, type ReturnableOrderItem as bT, type SdkError as bU, type ShippingMethodSummary as bV, type ShippingQuote as bW, type ShippingQuoteInput as bX, type ShopAppearance as bY, type ShopInfo as bZ, type ShopScript as b_, type PaymentStatus as ba, PaymentStatuses as bb, type PaymentSwift as bc, type PickupPoint as bd, type PickupPointHours as be, type PickupPointsInput as bf, type PickupWidgetConfig as bg, type PriceDisplay as bh, type ProductAssetGroup as bi, type ProductAssetItem as bj, type ProductAvailability as bk, type ProductGroup as bl, type ProductLabel as bm, type ProductListItem as bn, type ProductMedia as bo, type ProductMediaVariant as bp, type ProductParameter as bq, type ProductParameterGroup as br, type ProductParametersResponse as bs, type ProductPrice as bt, type ProductPromotionSummary as bu, type ProductReview as bv, type ProductReviewsResponse as bw, type ProductSibling as bx, ProductSort as by, type ProductSortValue as bz, type AddToCartInput as c, type ShopScriptType as c0, type ShopScripts as c1, type ShopSeo as c2, type ShopSeoIdentity as c3, type SiteFormField as c4, type SiteFormFieldOption as c5, type SiteFormFieldType as c6, type Sitemap as c7, type SitemapEntry as c8, type StockBehavior as c9, type StockMode as ca, type StorefrontForm as cb, type StorefrontFormFieldErrorCode as cc, type StorefrontFormFile as cd, type StorefrontFormSettings as ce, type StorefrontFormSubmitInput as cf, type StorefrontFormSubmitResult as cg, type StorefrontFormUpload as ch, type SubmitQuoteInput as ci, type SubmitReturnInput as cj, type SubmitReviewInput as ck, type Subscription as cl, type SubscriptionAction as cm, type SubscriptionFrequency as cn, type SubscriptionItem as co, type SubscriptionStatus as cp, type TaxBreakdownLine as cq, type VariantAxis as cr, type VariantAxisValue as cs, type WishlistItem as ct, clearCartSummary as cu, err as cv, ok as cw, publishCartSummary as cx, toSdkError as cy, type AddressDetail as d, type AddressSuggestion as e, type AddressType as f, AddressTypes as g, type AuthTokens as h, type BackInStockSubscription as i, type BadgeTone as j, BehioApiError as k, type BehioErrorCode as l, type BehioEventHandler as m, type BehioEventType as n, BehioNetworkError as o, type BehioStorefrontConfig as p, type Blog as q, type BlogPostDetail as r, type BlogPostListItem as s, type BlogPostsPage as t, type BlogPostsQuery as u, type BlogSettings as v, type BlogTag as w, type Bundle as x, type BundleCatalogQuery as y, type BundleItem as z };
@@ -482,6 +482,8 @@ interface ProductVariant {
482
482
  stockQuantity?: number | null;
483
483
  /** "Only X left" for this variant — same contract as ProductListItem.lowStockRemaining. */
484
484
  lowStockRemaining?: number | null;
485
+ /** Most pieces the cart accepts for this variant; null = uncapped or hidden stock. SDK 2.13.0. */
486
+ maxPurchasableQuantity?: number | null;
485
487
  /**
486
488
  * Cover image URL for the variant. Falls back to the parent product's
487
489
  * cover when the variant has no photo of its own — see `imageIsInherited`.
@@ -837,6 +839,10 @@ interface ProductAssetGroup {
837
839
  items: ProductAssetItem[];
838
840
  }
839
841
  interface ProductDetail extends ProductListItem {
842
+ /** Most pieces the cart accepts (stock, plus safetyStock under BACKORDER);
843
+ * null when uncapped or the shop hides stock counts. Cap the PDP quantity
844
+ * stepper with it, it is exactly the cart rule. SDK 2.13.0. */
845
+ maxPurchasableQuantity?: number | null;
840
846
  longDescription?: string;
841
847
  /**
842
848
  * @deprecated Legacy per-listing images. Prefer `media`. Each carries its
@@ -1205,6 +1211,13 @@ interface CheckoutPreview {
1205
1211
  giftCardDeducted: number;
1206
1212
  roundingAdjustment: number;
1207
1213
  grandTotal: number;
1214
+ /** VAT contained in `grandTotal` split by rate: order discounts (always
1215
+ * VAT-inclusive) reduce base and VAT per rate, shipping and the payment fee
1216
+ * carry the goods rates. Same numbers as the invoice. SDK 2.12.0. */
1217
+ taxBreakdown?: TaxBreakdownLine[];
1218
+ /** VAT contained in `grandTotal`, the sum of `taxBreakdown[].taxAmount`.
1219
+ * `taxTotal` is the goods VAT before order discounts. SDK 2.12.0. */
1220
+ vatTotal?: number;
1208
1221
  previewToken: string;
1209
1222
  expiresAt: number;
1210
1223
  }
@@ -1275,6 +1288,9 @@ interface CartItemProduct {
1275
1288
  sku: string;
1276
1289
  imageUrl?: string;
1277
1290
  inStock: boolean;
1291
+ /** Pieces left for an "only X left" note on the cart line; null when the
1292
+ * shop does not track stock, hides the nudge or has plenty. SDK 2.13.0. */
1293
+ lowStockRemaining?: number | null;
1278
1294
  currentPrice: number | null;
1279
1295
  /** Minimum order quantity (units); null = no minimum. Clamp the cart
1280
1296
  * stepper's lower bound to this (GAP-48). */
@@ -1362,8 +1378,11 @@ interface Cart {
1362
1378
  * `INCL_VAT`, VAT excluded when it runs `EXCL_VAT`. Not the payable amount,
1363
1379
  * that is `grandTotal`. */
1364
1380
  subtotal: number;
1365
- /** Discount from the applied code. Always based on `subtotal`, i.e. on the
1366
- * prices the customer sees, so "10 % off 200" is 20 in both price modes. */
1381
+ /** Discount from the applied code, VAT-inclusive. The base is always the
1382
+ * VAT-inclusive amount, also when the shop shows prices without VAT: a
1383
+ * discount is never taken from the net base (SDK 2.12.0; before, "10 % off
1384
+ * 200 net" was 20, now it is 24.20 at 21 %). It lowers base and VAT, see
1385
+ * `taxBreakdown` and `vatTotal`. */
1367
1386
  discountTotal: number;
1368
1387
  discount?: CartDiscount;
1369
1388
  /** Auto-apply promotion discount lines (sale/BOGO). */
@@ -1380,11 +1399,16 @@ interface Cart {
1380
1399
  * back to the catalog price), under `EXCL_VAT` it is added on top. Render
1381
1400
  * this as the cart total; do not add `taxTotal` to it. */
1382
1401
  grandTotal: number;
1383
- /** VAT contained in the prices (`INCL_VAT`) or added on top of them
1384
- * (`EXCL_VAT`), across all lines (GAP-30). An estimate finalized at checkout
1385
- * once the shipping country is known. */
1402
+ /** Goods VAT BEFORE order discounts: contained in the prices (`INCL_VAT`) or
1403
+ * added on top (`EXCL_VAT`). Use it for the goods subtotal
1404
+ * (`subtotal` net + `taxTotal`); the VAT the customer pays is `vatTotal`. */
1386
1405
  taxTotal: number;
1387
- /** VAT split by rate for "DPH 21 %: X Kč" summary rows. Empty for a
1406
+ /** VAT contained in `grandTotal`, after the order discount, as on the
1407
+ * invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1408
+ vatTotal?: number;
1409
+ /** VAT of the payable amount split by rate for "DPH 21 %: X Kč" rows. The
1410
+ * order discount reduces base and VAT per rate (since SDK 2.12.0; before it
1411
+ * showed the VAT of the goods before the discount). Empty for a
1388
1412
  * non-VAT-payer shop. */
1389
1413
  taxBreakdown: TaxBreakdownLine[];
1390
1414
  /** Delivery country set via `cart.setDestination()`, null until known. SDK 1.17.0. */
@@ -1497,6 +1521,14 @@ interface CheckoutInput {
1497
1521
  termsConsent?: boolean;
1498
1522
  gdprConsent?: boolean;
1499
1523
  newsletterOptIn?: boolean;
1524
+ /**
1525
+ * Consent to start delivering digital content (courses, downloads,
1526
+ * services) before the withdrawal period ends, which waives the right of
1527
+ * withdrawal (EU Directive 2011/83 art. 16(m)). Render the checkbox for carts
1528
+ * without physical goods (`cart.requiresShipping === false`). Stored on the
1529
+ * order consent record; it does not block the order. SDK 2.13.0.
1530
+ */
1531
+ digitalDeliveryConsent?: boolean;
1500
1532
  /**
1501
1533
  * Consent to marketing SMS, from the optional checkout checkbox. Render it
1502
1534
  * only when `ShopInfo.checkout.collectSmsConsent` is true; shops that do not
@@ -1610,6 +1642,8 @@ interface OrderTracking {
1610
1642
  paymentFee?: number | null;
1611
1643
  discountTotal?: number;
1612
1644
  taxTotal?: number;
1645
+ /** VAT contained in `grandTotal`, as on the invoice. SDK 2.12.0. */
1646
+ vatTotal?: number;
1613
1647
  taxBreakdown?: TaxBreakdownLine[];
1614
1648
  /** Shipping method as the customer chose it (SDK 2.8.0). */
1615
1649
  shippingMethodName?: string | null;
@@ -1642,6 +1676,18 @@ interface OrderStatusHistory {
1642
1676
  changedBy?: string;
1643
1677
  createdAt: number;
1644
1678
  }
1679
+ /** Bank transfer details of an unpaid order (SDK 2.13.0). */
1680
+ interface OrderPaymentInstructions {
1681
+ accountNumber: string | null;
1682
+ iban: string | null;
1683
+ bic: string | null;
1684
+ bankName: string | null;
1685
+ /** Digits only, at most 10 (Czech banks); from the method pattern with the order number. */
1686
+ variableSymbol: string | null;
1687
+ amount: number;
1688
+ currency: string;
1689
+ instructions: string | null;
1690
+ }
1645
1691
  interface OrderDetail extends OrderListItem {
1646
1692
  /** Payment is recorded; access delivery will retry automatically. Do not place a duplicate order. */
1647
1693
  contentDeliveryPending?: boolean;
@@ -1651,6 +1697,10 @@ interface OrderDetail extends OrderListItem {
1651
1697
  shippingMethodName?: string | null;
1652
1698
  /** Payment method in the order language (SDK 2.8.0). */
1653
1699
  paymentMethodName?: string | null;
1700
+ /** Bank transfer details while the order is unpaid; render them on the
1701
+ * confirmation (account, IBAN, variable symbol, amount). Null for other
1702
+ * methods and paid orders. SDK 2.13.0. */
1703
+ paymentInstructions?: OrderPaymentInstructions | null;
1654
1704
  /** Pickup point the customer chose, a public place (SDK 2.8.0). */
1655
1705
  pickupPoint?: OrderPickupPoint | null;
1656
1706
  /** Parcels the customer can follow (SDK 2.8.0). */
@@ -1662,9 +1712,15 @@ interface OrderDetail extends OrderListItem {
1662
1712
  phone?: string;
1663
1713
  customerNote?: string;
1664
1714
  subtotal: number;
1715
+ /** Goods VAT before order discounts (goods subtotal = `subtotal` + `taxTotal`). */
1665
1716
  taxTotal: number;
1666
- /** VAT split by rate (GAP-30), summed from the order lines. Render
1667
- * "DPH 21 %: X Kč" rows. Empty for a non-VAT order. */
1717
+ /** VAT contained in `grandTotal` (after discounts, incl. shipping), the same
1718
+ * as on the invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1719
+ vatTotal?: number;
1720
+ /** VAT of the amount paid split by rate (GAP-30) for "DPH 21 %: X Kč" rows.
1721
+ * Order discounts reduce base and VAT, shipping and the payment fee carry
1722
+ * the goods rates (since SDK 2.12.0, matching the invoice). Empty for a
1723
+ * non-VAT order. */
1668
1724
  taxBreakdown: TaxBreakdownLine[];
1669
1725
  /** DOMESTIC, OSS, REVERSE_CHARGE (no VAT, buyer accounts for it) or EXPORT (no VAT, outside EU). SDK 1.17.0. */
1670
1726
  vatMode?: "DOMESTIC" | "OSS" | "REVERSE_CHARGE" | "EXPORT" | null;
@@ -3985,4 +4041,4 @@ declare function clearCartSummary(): void;
3985
4041
  /** Publish only authoritative current totals; server cart consumers call this after hydration and revalidation. */
3986
4042
  declare function publishCartSummary(summary: CartSummaryEvent): void;
3987
4043
 
3988
- export { type CourseCommentReply as $, type ActivePromotion as A, BehioStorefront as B, type CookieConsent as C, type Cart as D, type CartBundleLine as E, type CartBundleLineItem as F, type CartDiscount as G, type CartItem as H, type CartItemProduct as I, type CartLinkClaimed as J, type CartPromotion as K, type CartSummaryEvent as L, type Category as M, type CategoryDetail as N, type CertificateVerification as O, type ProductDetail as P, type CheckoutAddress as Q, type CheckoutInput as R, type SdkResult as S, type CheckoutPaymentMethod as T, type CheckoutPreview as U, type CheckoutResult as V, type CheckoutSettings as W, type CookieConsentInput as X, type CourseAttachment as Y, type CourseCertificate as Z, type CourseComment as _, type ProductVariant as a, type OrderShipment as a$, type CourseCommentsList as a0, type CourseDetail as a1, type CourseLesson as a2, type CourseListItem as a3, type CourseModule as a4, type CoursePostedComment as a5, type CourseProgress as a6, type CourseTutorMessage as a7, type CourseTutorThread as a8, type CrossSellItem as a9, type LessonNote as aA, type LessonQuiz as aB, type LoginInput as aC, type LoyaltyBalance as aD, type LoyaltyNextTier as aE, type LoyaltyProgram as aF, type LoyaltyQuery as aG, type LoyaltyReferralResult as aH, type LoyaltySummary as aI, type LoyaltyTier as aJ, type LoyaltyTierPerks as aK, type LoyaltyTransaction as aL, type Menu as aM, type MenuItem as aN, type MenuItemRef as aO, type MenuItemType as aP, type MessageResponse as aQ, type NewsletterOptInDefault as aR, type NewsletterSubscribeInput as aS, type NewsletterSubscribeResult as aT, type NewsletterUnsubscribeResult as aU, type OrderAccessRequestResponse as aV, type OrderAccessVerifyResponse as aW, type OrderDetail as aX, type OrderItem as aY, type OrderListItem as aZ, type OrderPickupPoint as a_, type CurrencyDisplayFormat as aa, type CustomerAddress as ab, type CustomerBadge as ac, type CustomerChallenge as ad, type CustomerGamification as ae, type CustomerGamificationQuery as af, type CustomerProfile as ag, type DigitalDownload as ah, type DownloadUrl as ai, type Facet as aj, type FacetAvailability as ak, type FacetCategory as al, type FacetLabel as am, type FacetPriceRange as an, type FacetRange as ao, type FacetRatingBucket as ap, type FacetValue as aq, type FacetsResponse as ar, type FilterField as as, type FulfillmentStatus as at, FulfillmentStatuses as au, type GamificationRefreshResult as av, type GiftCardBalance as aw, type GiftCardPurchaseInput as ax, type GiftCardPurchaseResult as ay, type GiftCardSummary as az, type StorefrontFormFieldError as b, type ShopScriptType as b$, type OrderStatus as b0, type OrderStatusHistory as b1, OrderStatuses as b2, type OrderTracking as b3, type Page as b4, type PageAttachment as b5, type PageDetail as b6, type PaginatedResponse as b7, type PaymentInstrument as b8, type PaymentStatus as b9, type ProductsQuery as bA, type QuizAnswerInput as bB, type QuizAnswerResult as bC, type QuizQuestion as bD, type QuizResult as bE, type QuoteItem as bF, type QuoteRequest as bG, type RegisterInput as bH, type RegisterResult as bI, type RequestInterceptor as bJ, type RequestInterceptorConfig as bK, type ResponseInterceptor as bL, type ResponseInterceptorData as bM, type ReturnRequest as bN, type ReturnRequestItem as bO, type ReturnStatus as bP, type ReturnStatusItem as bQ, type ReturnableOrder as bR, type ReturnableOrderItem as bS, type SdkError as bT, type ShippingMethodSummary as bU, type ShippingQuote as bV, type ShippingQuoteInput as bW, type ShopAppearance as bX, type ShopInfo as bY, type ShopScript as bZ, type ShopScriptPlacement as b_, PaymentStatuses as ba, type PaymentSwift as bb, type PickupPoint as bc, type PickupPointHours as bd, type PickupPointsInput as be, type PickupWidgetConfig as bf, type PriceDisplay as bg, type ProductAssetGroup as bh, type ProductAssetItem as bi, type ProductAvailability as bj, type ProductGroup as bk, type ProductLabel as bl, type ProductListItem as bm, type ProductMedia as bn, type ProductMediaVariant as bo, type ProductParameter as bp, type ProductParameterGroup as bq, type ProductParametersResponse as br, type ProductPrice as bs, type ProductPromotionSummary as bt, type ProductReview as bu, type ProductReviewsResponse as bv, type ProductSibling as bw, ProductSort as bx, type ProductSortValue as by, type ProductVolumePrice as bz, type AddToCartInput as c, type ShopScripts as c0, type ShopSeo as c1, type ShopSeoIdentity as c2, type SiteFormField as c3, type SiteFormFieldOption as c4, type SiteFormFieldType as c5, type Sitemap as c6, type SitemapEntry as c7, type StockBehavior as c8, type StockMode as c9, type StorefrontForm as ca, type StorefrontFormFieldErrorCode as cb, type StorefrontFormFile as cc, type StorefrontFormSettings as cd, type StorefrontFormSubmitInput as ce, type StorefrontFormSubmitResult as cf, type StorefrontFormUpload as cg, type SubmitQuoteInput as ch, type SubmitReturnInput as ci, type SubmitReviewInput as cj, type Subscription as ck, type SubscriptionAction as cl, type SubscriptionFrequency as cm, type SubscriptionItem as cn, type SubscriptionStatus as co, type TaxBreakdownLine as cp, type VariantAxis as cq, type VariantAxisValue as cr, type WishlistItem as cs, clearCartSummary as ct, err as cu, ok as cv, publishCartSummary as cw, toSdkError as cx, type AddressDetail as d, type AddressSuggestion as e, type AddressType as f, AddressTypes as g, type AuthTokens as h, type BackInStockSubscription as i, type BadgeTone as j, BehioApiError as k, type BehioErrorCode as l, type BehioEventHandler as m, type BehioEventType as n, BehioNetworkError as o, type BehioStorefrontConfig as p, type Blog as q, type BlogPostDetail as r, type BlogPostListItem as s, type BlogPostsPage as t, type BlogPostsQuery as u, type BlogSettings as v, type BlogTag as w, type Bundle as x, type BundleCatalogQuery as y, type BundleItem as z };
4044
+ export { type CourseCommentReply as $, type ActivePromotion as A, BehioStorefront as B, type CookieConsent as C, type Cart as D, type CartBundleLine as E, type CartBundleLineItem as F, type CartDiscount as G, type CartItem as H, type CartItemProduct as I, type CartLinkClaimed as J, type CartPromotion as K, type CartSummaryEvent as L, type Category as M, type CategoryDetail as N, type CertificateVerification as O, type ProductDetail as P, type CheckoutAddress as Q, type CheckoutInput as R, type SdkResult as S, type CheckoutPaymentMethod as T, type CheckoutPreview as U, type CheckoutResult as V, type CheckoutSettings as W, type CookieConsentInput as X, type CourseAttachment as Y, type CourseCertificate as Z, type CourseComment as _, type ProductVariant as a, type OrderPickupPoint as a$, type CourseCommentsList as a0, type CourseDetail as a1, type CourseLesson as a2, type CourseListItem as a3, type CourseModule as a4, type CoursePostedComment as a5, type CourseProgress as a6, type CourseTutorMessage as a7, type CourseTutorThread as a8, type CrossSellItem as a9, type LessonNote as aA, type LessonQuiz as aB, type LoginInput as aC, type LoyaltyBalance as aD, type LoyaltyNextTier as aE, type LoyaltyProgram as aF, type LoyaltyQuery as aG, type LoyaltyReferralResult as aH, type LoyaltySummary as aI, type LoyaltyTier as aJ, type LoyaltyTierPerks as aK, type LoyaltyTransaction as aL, type Menu as aM, type MenuItem as aN, type MenuItemRef as aO, type MenuItemType as aP, type MessageResponse as aQ, type NewsletterOptInDefault as aR, type NewsletterSubscribeInput as aS, type NewsletterSubscribeResult as aT, type NewsletterUnsubscribeResult as aU, type OrderAccessRequestResponse as aV, type OrderAccessVerifyResponse as aW, type OrderDetail as aX, type OrderItem as aY, type OrderListItem as aZ, type OrderPaymentInstructions as a_, type CurrencyDisplayFormat as aa, type CustomerAddress as ab, type CustomerBadge as ac, type CustomerChallenge as ad, type CustomerGamification as ae, type CustomerGamificationQuery as af, type CustomerProfile as ag, type DigitalDownload as ah, type DownloadUrl as ai, type Facet as aj, type FacetAvailability as ak, type FacetCategory as al, type FacetLabel as am, type FacetPriceRange as an, type FacetRange as ao, type FacetRatingBucket as ap, type FacetValue as aq, type FacetsResponse as ar, type FilterField as as, type FulfillmentStatus as at, FulfillmentStatuses as au, type GamificationRefreshResult as av, type GiftCardBalance as aw, type GiftCardPurchaseInput as ax, type GiftCardPurchaseResult as ay, type GiftCardSummary as az, type StorefrontFormFieldError as b, type ShopScriptPlacement as b$, type OrderShipment as b0, type OrderStatus as b1, type OrderStatusHistory as b2, OrderStatuses as b3, type OrderTracking as b4, type Page as b5, type PageAttachment as b6, type PageDetail as b7, type PaginatedResponse as b8, type PaymentInstrument as b9, type ProductVolumePrice as bA, type ProductsQuery as bB, type QuizAnswerInput as bC, type QuizAnswerResult as bD, type QuizQuestion as bE, type QuizResult as bF, type QuoteItem as bG, type QuoteRequest as bH, type RegisterInput as bI, type RegisterResult as bJ, type RequestInterceptor as bK, type RequestInterceptorConfig as bL, type ResponseInterceptor as bM, type ResponseInterceptorData as bN, type ReturnRequest as bO, type ReturnRequestItem as bP, type ReturnStatus as bQ, type ReturnStatusItem as bR, type ReturnableOrder as bS, type ReturnableOrderItem as bT, type SdkError as bU, type ShippingMethodSummary as bV, type ShippingQuote as bW, type ShippingQuoteInput as bX, type ShopAppearance as bY, type ShopInfo as bZ, type ShopScript as b_, type PaymentStatus as ba, PaymentStatuses as bb, type PaymentSwift as bc, type PickupPoint as bd, type PickupPointHours as be, type PickupPointsInput as bf, type PickupWidgetConfig as bg, type PriceDisplay as bh, type ProductAssetGroup as bi, type ProductAssetItem as bj, type ProductAvailability as bk, type ProductGroup as bl, type ProductLabel as bm, type ProductListItem as bn, type ProductMedia as bo, type ProductMediaVariant as bp, type ProductParameter as bq, type ProductParameterGroup as br, type ProductParametersResponse as bs, type ProductPrice as bt, type ProductPromotionSummary as bu, type ProductReview as bv, type ProductReviewsResponse as bw, type ProductSibling as bx, ProductSort as by, type ProductSortValue as bz, type AddToCartInput as c, type ShopScriptType as c0, type ShopScripts as c1, type ShopSeo as c2, type ShopSeoIdentity as c3, type SiteFormField as c4, type SiteFormFieldOption as c5, type SiteFormFieldType as c6, type Sitemap as c7, type SitemapEntry as c8, type StockBehavior as c9, type StockMode as ca, type StorefrontForm as cb, type StorefrontFormFieldErrorCode as cc, type StorefrontFormFile as cd, type StorefrontFormSettings as ce, type StorefrontFormSubmitInput as cf, type StorefrontFormSubmitResult as cg, type StorefrontFormUpload as ch, type SubmitQuoteInput as ci, type SubmitReturnInput as cj, type SubmitReviewInput as ck, type Subscription as cl, type SubscriptionAction as cm, type SubscriptionFrequency as cn, type SubscriptionItem as co, type SubscriptionStatus as cp, type TaxBreakdownLine as cq, type VariantAxis as cr, type VariantAxisValue as cs, type WishlistItem as ct, clearCartSummary as cu, err as cv, ok as cw, publishCartSummary as cx, toSdkError as cy, type AddressDetail as d, type AddressSuggestion as e, type AddressType as f, AddressTypes as g, type AuthTokens as h, type BackInStockSubscription as i, type BadgeTone as j, BehioApiError as k, type BehioErrorCode as l, type BehioEventHandler as m, type BehioEventType as n, BehioNetworkError as o, type BehioStorefrontConfig as p, type Blog as q, type BlogPostDetail as r, type BlogPostListItem as s, type BlogPostsPage as t, type BlogPostsQuery as u, type BlogSettings as v, type BlogTag as w, type Bundle as x, type BundleCatalogQuery as y, type BundleItem as z };
package/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as ProductDetail, a as ProductVariant, B as BehioStorefront, S as SdkResult, C as CookieConsent, b as StorefrontFormFieldError } from './client-CmbuYuof.mjs';
2
- export { A as ActivePromotion, c as AddToCartInput, d as AddressDetail, e as AddressSuggestion, f as AddressType, g as AddressTypes, h as AuthTokens, i as BackInStockSubscription, j as BadgeTone, k as BehioApiError, l as BehioErrorCode, m as BehioEventHandler, n as BehioEventType, o as BehioNetworkError, p as BehioStorefrontConfig, q as Blog, r as BlogPostDetail, s as BlogPostListItem, t as BlogPostsPage, u as BlogPostsQuery, v as BlogSettings, w as BlogTag, x as Bundle, y as BundleCatalogQuery, z as BundleItem, D as Cart, E as CartBundleLine, F as CartBundleLineItem, G as CartDiscount, H as CartItem, I as CartItemProduct, J as CartLinkClaimed, K as CartPromotion, L as CartSummaryEvent, M as Category, N as CategoryDetail, O as CertificateVerification, Q as CheckoutAddress, R as CheckoutInput, T as CheckoutPaymentMethod, U as CheckoutPreview, V as CheckoutResult, W as CheckoutSettings, X as CookieConsentInput, Y as CourseAttachment, Z as CourseCertificate, _ as CourseComment, $ as CourseCommentReply, a0 as CourseCommentsList, a1 as CourseDetail, a2 as CourseLesson, a3 as CourseListItem, a4 as CourseModule, a5 as CoursePostedComment, a6 as CourseProgress, a7 as CourseTutorMessage, a8 as CourseTutorThread, a9 as CrossSellItem, aa as CurrencyDisplayFormat, ab as CustomerAddress, ac as CustomerBadge, ad as CustomerChallenge, ae as CustomerGamification, af as CustomerGamificationQuery, ag as CustomerProfile, ah as DigitalDownload, ai as DownloadUrl, aj as Facet, ak as FacetAvailability, al as FacetCategory, am as FacetLabel, an as FacetPriceRange, ao as FacetRange, ap as FacetRatingBucket, aq as FacetValue, ar as FacetsResponse, as as FilterField, at as FulfillmentStatus, au as FulfillmentStatuses, av as GamificationRefreshResult, aw as GiftCardBalance, ax as GiftCardPurchaseInput, ay as GiftCardPurchaseResult, az as GiftCardSummary, aA as LessonNote, aB as LessonQuiz, aC as LoginInput, aD as LoyaltyBalance, aE as LoyaltyNextTier, aF as LoyaltyProgram, aG as LoyaltyQuery, aH as LoyaltyReferralResult, aI as LoyaltySummary, aJ as LoyaltyTier, aK as LoyaltyTierPerks, aL as LoyaltyTransaction, aM as Menu, aN as MenuItem, aO as MenuItemRef, aP as MenuItemType, aQ as MessageResponse, aR as NewsletterOptInDefault, aS as NewsletterSubscribeInput, aT as NewsletterSubscribeResult, aU as NewsletterUnsubscribeResult, aV as OrderAccessRequestResponse, aW as OrderAccessVerifyResponse, aX as OrderDetail, aY as OrderItem, aZ as OrderListItem, a_ as OrderPickupPoint, a$ as OrderShipment, b0 as OrderStatus, b1 as OrderStatusHistory, b2 as OrderStatuses, b3 as OrderTracking, b4 as Page, b5 as PageAttachment, b6 as PageDetail, b7 as PaginatedResponse, b8 as PaymentInstrument, b9 as PaymentStatus, ba as PaymentStatuses, bb as PaymentSwift, bc as PickupPoint, bd as PickupPointHours, be as PickupPointsInput, bf as PickupWidgetConfig, bg as PriceDisplay, bh as ProductAssetGroup, bi as ProductAssetItem, bj as ProductAvailability, bk as ProductGroup, bl as ProductLabel, bm as ProductListItem, bn as ProductMedia, bo as ProductMediaVariant, bp as ProductParameter, bq as ProductParameterGroup, br as ProductParametersResponse, bs as ProductPrice, bt as ProductPromotionSummary, bu as ProductReview, bv as ProductReviewsResponse, bw as ProductSibling, bx as ProductSort, by as ProductSortValue, bz as ProductVolumePrice, bA as ProductsQuery, bB as QuizAnswerInput, bC as QuizAnswerResult, bD as QuizQuestion, bE as QuizResult, bF as QuoteItem, bG as QuoteRequest, bH as RegisterInput, bI as RegisterResult, bJ as RequestInterceptor, bK as RequestInterceptorConfig, bL as ResponseInterceptor, bM as ResponseInterceptorData, bN as ReturnRequest, bO as ReturnRequestItem, bP as ReturnStatus, bQ as ReturnStatusItem, bR as ReturnableOrder, bS as ReturnableOrderItem, bT as SdkError, bU as ShippingMethodSummary, bV as ShippingQuote, bW as ShippingQuoteInput, bX as ShopAppearance, bY as ShopInfo, bZ as ShopScript, b_ as ShopScriptPlacement, b$ as ShopScriptType, c0 as ShopScripts, c1 as ShopSeo, c2 as ShopSeoIdentity, c3 as SiteFormField, c4 as SiteFormFieldOption, c5 as SiteFormFieldType, c6 as Sitemap, c7 as SitemapEntry, c8 as StockBehavior, c9 as StockMode, ca as StorefrontForm, cb as StorefrontFormFieldErrorCode, cc as StorefrontFormFile, cd as StorefrontFormSettings, ce as StorefrontFormSubmitInput, cf as StorefrontFormSubmitResult, cg as StorefrontFormUpload, ch as SubmitQuoteInput, ci as SubmitReturnInput, cj as SubmitReviewInput, ck as Subscription, cl as SubscriptionAction, cm as SubscriptionFrequency, cn as SubscriptionItem, co as SubscriptionStatus, cp as TaxBreakdownLine, cq as VariantAxis, cr as VariantAxisValue, cs as WishlistItem, ct as clearCartSummary, cu as err, cv as ok, cw as publishCartSummary, cx as toSdkError } from './client-CmbuYuof.mjs';
1
+ import { P as ProductDetail, a as ProductVariant, B as BehioStorefront, S as SdkResult, C as CookieConsent, b as StorefrontFormFieldError } from './client-Cf_xibuw.mjs';
2
+ export { A as ActivePromotion, c as AddToCartInput, d as AddressDetail, e as AddressSuggestion, f as AddressType, g as AddressTypes, h as AuthTokens, i as BackInStockSubscription, j as BadgeTone, k as BehioApiError, l as BehioErrorCode, m as BehioEventHandler, n as BehioEventType, o as BehioNetworkError, p as BehioStorefrontConfig, q as Blog, r as BlogPostDetail, s as BlogPostListItem, t as BlogPostsPage, u as BlogPostsQuery, v as BlogSettings, w as BlogTag, x as Bundle, y as BundleCatalogQuery, z as BundleItem, D as Cart, E as CartBundleLine, F as CartBundleLineItem, G as CartDiscount, H as CartItem, I as CartItemProduct, J as CartLinkClaimed, K as CartPromotion, L as CartSummaryEvent, M as Category, N as CategoryDetail, O as CertificateVerification, Q as CheckoutAddress, R as CheckoutInput, T as CheckoutPaymentMethod, U as CheckoutPreview, V as CheckoutResult, W as CheckoutSettings, X as CookieConsentInput, Y as CourseAttachment, Z as CourseCertificate, _ as CourseComment, $ as CourseCommentReply, a0 as CourseCommentsList, a1 as CourseDetail, a2 as CourseLesson, a3 as CourseListItem, a4 as CourseModule, a5 as CoursePostedComment, a6 as CourseProgress, a7 as CourseTutorMessage, a8 as CourseTutorThread, a9 as CrossSellItem, aa as CurrencyDisplayFormat, ab as CustomerAddress, ac as CustomerBadge, ad as CustomerChallenge, ae as CustomerGamification, af as CustomerGamificationQuery, ag as CustomerProfile, ah as DigitalDownload, ai as DownloadUrl, aj as Facet, ak as FacetAvailability, al as FacetCategory, am as FacetLabel, an as FacetPriceRange, ao as FacetRange, ap as FacetRatingBucket, aq as FacetValue, ar as FacetsResponse, as as FilterField, at as FulfillmentStatus, au as FulfillmentStatuses, av as GamificationRefreshResult, aw as GiftCardBalance, ax as GiftCardPurchaseInput, ay as GiftCardPurchaseResult, az as GiftCardSummary, aA as LessonNote, aB as LessonQuiz, aC as LoginInput, aD as LoyaltyBalance, aE as LoyaltyNextTier, aF as LoyaltyProgram, aG as LoyaltyQuery, aH as LoyaltyReferralResult, aI as LoyaltySummary, aJ as LoyaltyTier, aK as LoyaltyTierPerks, aL as LoyaltyTransaction, aM as Menu, aN as MenuItem, aO as MenuItemRef, aP as MenuItemType, aQ as MessageResponse, aR as NewsletterOptInDefault, aS as NewsletterSubscribeInput, aT as NewsletterSubscribeResult, aU as NewsletterUnsubscribeResult, aV as OrderAccessRequestResponse, aW as OrderAccessVerifyResponse, aX as OrderDetail, aY as OrderItem, aZ as OrderListItem, a_ as OrderPaymentInstructions, a$ as OrderPickupPoint, b0 as OrderShipment, b1 as OrderStatus, b2 as OrderStatusHistory, b3 as OrderStatuses, b4 as OrderTracking, b5 as Page, b6 as PageAttachment, b7 as PageDetail, b8 as PaginatedResponse, b9 as PaymentInstrument, ba as PaymentStatus, bb as PaymentStatuses, bc as PaymentSwift, bd as PickupPoint, be as PickupPointHours, bf as PickupPointsInput, bg as PickupWidgetConfig, bh as PriceDisplay, bi as ProductAssetGroup, bj as ProductAssetItem, bk as ProductAvailability, bl as ProductGroup, bm as ProductLabel, bn as ProductListItem, bo as ProductMedia, bp as ProductMediaVariant, bq as ProductParameter, br as ProductParameterGroup, bs as ProductParametersResponse, bt as ProductPrice, bu as ProductPromotionSummary, bv as ProductReview, bw as ProductReviewsResponse, bx as ProductSibling, by as ProductSort, bz as ProductSortValue, bA as ProductVolumePrice, bB as ProductsQuery, bC as QuizAnswerInput, bD as QuizAnswerResult, bE as QuizQuestion, bF as QuizResult, bG as QuoteItem, bH as QuoteRequest, bI as RegisterInput, bJ as RegisterResult, bK as RequestInterceptor, bL as RequestInterceptorConfig, bM as ResponseInterceptor, bN as ResponseInterceptorData, bO as ReturnRequest, bP as ReturnRequestItem, bQ as ReturnStatus, bR as ReturnStatusItem, bS as ReturnableOrder, bT as ReturnableOrderItem, bU as SdkError, bV as ShippingMethodSummary, bW as ShippingQuote, bX as ShippingQuoteInput, bY as ShopAppearance, bZ as ShopInfo, b_ as ShopScript, b$ as ShopScriptPlacement, c0 as ShopScriptType, c1 as ShopScripts, c2 as ShopSeo, c3 as ShopSeoIdentity, c4 as SiteFormField, c5 as SiteFormFieldOption, c6 as SiteFormFieldType, c7 as Sitemap, c8 as SitemapEntry, c9 as StockBehavior, ca as StockMode, cb as StorefrontForm, cc as StorefrontFormFieldErrorCode, cd as StorefrontFormFile, ce as StorefrontFormSettings, cf as StorefrontFormSubmitInput, cg as StorefrontFormSubmitResult, ch as StorefrontFormUpload, ci as SubmitQuoteInput, cj as SubmitReturnInput, ck as SubmitReviewInput, cl as Subscription, cm as SubscriptionAction, cn as SubscriptionFrequency, co as SubscriptionItem, cp as SubscriptionStatus, cq as TaxBreakdownLine, cr as VariantAxis, cs as VariantAxisValue, ct as WishlistItem, cu as clearCartSummary, cv as err, cw as ok, cx as publishCartSummary, cy as toSdkError } from './client-Cf_xibuw.mjs';
3
3
 
4
4
  /**
5
5
  * Format a price amount with currency using Intl.NumberFormat.
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as ProductDetail, a as ProductVariant, B as BehioStorefront, S as SdkResult, C as CookieConsent, b as StorefrontFormFieldError } from './client-CmbuYuof.js';
2
- export { A as ActivePromotion, c as AddToCartInput, d as AddressDetail, e as AddressSuggestion, f as AddressType, g as AddressTypes, h as AuthTokens, i as BackInStockSubscription, j as BadgeTone, k as BehioApiError, l as BehioErrorCode, m as BehioEventHandler, n as BehioEventType, o as BehioNetworkError, p as BehioStorefrontConfig, q as Blog, r as BlogPostDetail, s as BlogPostListItem, t as BlogPostsPage, u as BlogPostsQuery, v as BlogSettings, w as BlogTag, x as Bundle, y as BundleCatalogQuery, z as BundleItem, D as Cart, E as CartBundleLine, F as CartBundleLineItem, G as CartDiscount, H as CartItem, I as CartItemProduct, J as CartLinkClaimed, K as CartPromotion, L as CartSummaryEvent, M as Category, N as CategoryDetail, O as CertificateVerification, Q as CheckoutAddress, R as CheckoutInput, T as CheckoutPaymentMethod, U as CheckoutPreview, V as CheckoutResult, W as CheckoutSettings, X as CookieConsentInput, Y as CourseAttachment, Z as CourseCertificate, _ as CourseComment, $ as CourseCommentReply, a0 as CourseCommentsList, a1 as CourseDetail, a2 as CourseLesson, a3 as CourseListItem, a4 as CourseModule, a5 as CoursePostedComment, a6 as CourseProgress, a7 as CourseTutorMessage, a8 as CourseTutorThread, a9 as CrossSellItem, aa as CurrencyDisplayFormat, ab as CustomerAddress, ac as CustomerBadge, ad as CustomerChallenge, ae as CustomerGamification, af as CustomerGamificationQuery, ag as CustomerProfile, ah as DigitalDownload, ai as DownloadUrl, aj as Facet, ak as FacetAvailability, al as FacetCategory, am as FacetLabel, an as FacetPriceRange, ao as FacetRange, ap as FacetRatingBucket, aq as FacetValue, ar as FacetsResponse, as as FilterField, at as FulfillmentStatus, au as FulfillmentStatuses, av as GamificationRefreshResult, aw as GiftCardBalance, ax as GiftCardPurchaseInput, ay as GiftCardPurchaseResult, az as GiftCardSummary, aA as LessonNote, aB as LessonQuiz, aC as LoginInput, aD as LoyaltyBalance, aE as LoyaltyNextTier, aF as LoyaltyProgram, aG as LoyaltyQuery, aH as LoyaltyReferralResult, aI as LoyaltySummary, aJ as LoyaltyTier, aK as LoyaltyTierPerks, aL as LoyaltyTransaction, aM as Menu, aN as MenuItem, aO as MenuItemRef, aP as MenuItemType, aQ as MessageResponse, aR as NewsletterOptInDefault, aS as NewsletterSubscribeInput, aT as NewsletterSubscribeResult, aU as NewsletterUnsubscribeResult, aV as OrderAccessRequestResponse, aW as OrderAccessVerifyResponse, aX as OrderDetail, aY as OrderItem, aZ as OrderListItem, a_ as OrderPickupPoint, a$ as OrderShipment, b0 as OrderStatus, b1 as OrderStatusHistory, b2 as OrderStatuses, b3 as OrderTracking, b4 as Page, b5 as PageAttachment, b6 as PageDetail, b7 as PaginatedResponse, b8 as PaymentInstrument, b9 as PaymentStatus, ba as PaymentStatuses, bb as PaymentSwift, bc as PickupPoint, bd as PickupPointHours, be as PickupPointsInput, bf as PickupWidgetConfig, bg as PriceDisplay, bh as ProductAssetGroup, bi as ProductAssetItem, bj as ProductAvailability, bk as ProductGroup, bl as ProductLabel, bm as ProductListItem, bn as ProductMedia, bo as ProductMediaVariant, bp as ProductParameter, bq as ProductParameterGroup, br as ProductParametersResponse, bs as ProductPrice, bt as ProductPromotionSummary, bu as ProductReview, bv as ProductReviewsResponse, bw as ProductSibling, bx as ProductSort, by as ProductSortValue, bz as ProductVolumePrice, bA as ProductsQuery, bB as QuizAnswerInput, bC as QuizAnswerResult, bD as QuizQuestion, bE as QuizResult, bF as QuoteItem, bG as QuoteRequest, bH as RegisterInput, bI as RegisterResult, bJ as RequestInterceptor, bK as RequestInterceptorConfig, bL as ResponseInterceptor, bM as ResponseInterceptorData, bN as ReturnRequest, bO as ReturnRequestItem, bP as ReturnStatus, bQ as ReturnStatusItem, bR as ReturnableOrder, bS as ReturnableOrderItem, bT as SdkError, bU as ShippingMethodSummary, bV as ShippingQuote, bW as ShippingQuoteInput, bX as ShopAppearance, bY as ShopInfo, bZ as ShopScript, b_ as ShopScriptPlacement, b$ as ShopScriptType, c0 as ShopScripts, c1 as ShopSeo, c2 as ShopSeoIdentity, c3 as SiteFormField, c4 as SiteFormFieldOption, c5 as SiteFormFieldType, c6 as Sitemap, c7 as SitemapEntry, c8 as StockBehavior, c9 as StockMode, ca as StorefrontForm, cb as StorefrontFormFieldErrorCode, cc as StorefrontFormFile, cd as StorefrontFormSettings, ce as StorefrontFormSubmitInput, cf as StorefrontFormSubmitResult, cg as StorefrontFormUpload, ch as SubmitQuoteInput, ci as SubmitReturnInput, cj as SubmitReviewInput, ck as Subscription, cl as SubscriptionAction, cm as SubscriptionFrequency, cn as SubscriptionItem, co as SubscriptionStatus, cp as TaxBreakdownLine, cq as VariantAxis, cr as VariantAxisValue, cs as WishlistItem, ct as clearCartSummary, cu as err, cv as ok, cw as publishCartSummary, cx as toSdkError } from './client-CmbuYuof.js';
1
+ import { P as ProductDetail, a as ProductVariant, B as BehioStorefront, S as SdkResult, C as CookieConsent, b as StorefrontFormFieldError } from './client-Cf_xibuw.js';
2
+ export { A as ActivePromotion, c as AddToCartInput, d as AddressDetail, e as AddressSuggestion, f as AddressType, g as AddressTypes, h as AuthTokens, i as BackInStockSubscription, j as BadgeTone, k as BehioApiError, l as BehioErrorCode, m as BehioEventHandler, n as BehioEventType, o as BehioNetworkError, p as BehioStorefrontConfig, q as Blog, r as BlogPostDetail, s as BlogPostListItem, t as BlogPostsPage, u as BlogPostsQuery, v as BlogSettings, w as BlogTag, x as Bundle, y as BundleCatalogQuery, z as BundleItem, D as Cart, E as CartBundleLine, F as CartBundleLineItem, G as CartDiscount, H as CartItem, I as CartItemProduct, J as CartLinkClaimed, K as CartPromotion, L as CartSummaryEvent, M as Category, N as CategoryDetail, O as CertificateVerification, Q as CheckoutAddress, R as CheckoutInput, T as CheckoutPaymentMethod, U as CheckoutPreview, V as CheckoutResult, W as CheckoutSettings, X as CookieConsentInput, Y as CourseAttachment, Z as CourseCertificate, _ as CourseComment, $ as CourseCommentReply, a0 as CourseCommentsList, a1 as CourseDetail, a2 as CourseLesson, a3 as CourseListItem, a4 as CourseModule, a5 as CoursePostedComment, a6 as CourseProgress, a7 as CourseTutorMessage, a8 as CourseTutorThread, a9 as CrossSellItem, aa as CurrencyDisplayFormat, ab as CustomerAddress, ac as CustomerBadge, ad as CustomerChallenge, ae as CustomerGamification, af as CustomerGamificationQuery, ag as CustomerProfile, ah as DigitalDownload, ai as DownloadUrl, aj as Facet, ak as FacetAvailability, al as FacetCategory, am as FacetLabel, an as FacetPriceRange, ao as FacetRange, ap as FacetRatingBucket, aq as FacetValue, ar as FacetsResponse, as as FilterField, at as FulfillmentStatus, au as FulfillmentStatuses, av as GamificationRefreshResult, aw as GiftCardBalance, ax as GiftCardPurchaseInput, ay as GiftCardPurchaseResult, az as GiftCardSummary, aA as LessonNote, aB as LessonQuiz, aC as LoginInput, aD as LoyaltyBalance, aE as LoyaltyNextTier, aF as LoyaltyProgram, aG as LoyaltyQuery, aH as LoyaltyReferralResult, aI as LoyaltySummary, aJ as LoyaltyTier, aK as LoyaltyTierPerks, aL as LoyaltyTransaction, aM as Menu, aN as MenuItem, aO as MenuItemRef, aP as MenuItemType, aQ as MessageResponse, aR as NewsletterOptInDefault, aS as NewsletterSubscribeInput, aT as NewsletterSubscribeResult, aU as NewsletterUnsubscribeResult, aV as OrderAccessRequestResponse, aW as OrderAccessVerifyResponse, aX as OrderDetail, aY as OrderItem, aZ as OrderListItem, a_ as OrderPaymentInstructions, a$ as OrderPickupPoint, b0 as OrderShipment, b1 as OrderStatus, b2 as OrderStatusHistory, b3 as OrderStatuses, b4 as OrderTracking, b5 as Page, b6 as PageAttachment, b7 as PageDetail, b8 as PaginatedResponse, b9 as PaymentInstrument, ba as PaymentStatus, bb as PaymentStatuses, bc as PaymentSwift, bd as PickupPoint, be as PickupPointHours, bf as PickupPointsInput, bg as PickupWidgetConfig, bh as PriceDisplay, bi as ProductAssetGroup, bj as ProductAssetItem, bk as ProductAvailability, bl as ProductGroup, bm as ProductLabel, bn as ProductListItem, bo as ProductMedia, bp as ProductMediaVariant, bq as ProductParameter, br as ProductParameterGroup, bs as ProductParametersResponse, bt as ProductPrice, bu as ProductPromotionSummary, bv as ProductReview, bw as ProductReviewsResponse, bx as ProductSibling, by as ProductSort, bz as ProductSortValue, bA as ProductVolumePrice, bB as ProductsQuery, bC as QuizAnswerInput, bD as QuizAnswerResult, bE as QuizQuestion, bF as QuizResult, bG as QuoteItem, bH as QuoteRequest, bI as RegisterInput, bJ as RegisterResult, bK as RequestInterceptor, bL as RequestInterceptorConfig, bM as ResponseInterceptor, bN as ResponseInterceptorData, bO as ReturnRequest, bP as ReturnRequestItem, bQ as ReturnStatus, bR as ReturnStatusItem, bS as ReturnableOrder, bT as ReturnableOrderItem, bU as SdkError, bV as ShippingMethodSummary, bW as ShippingQuote, bX as ShippingQuoteInput, bY as ShopAppearance, bZ as ShopInfo, b_ as ShopScript, b$ as ShopScriptPlacement, c0 as ShopScriptType, c1 as ShopScripts, c2 as ShopSeo, c3 as ShopSeoIdentity, c4 as SiteFormField, c5 as SiteFormFieldOption, c6 as SiteFormFieldType, c7 as Sitemap, c8 as SitemapEntry, c9 as StockBehavior, ca as StockMode, cb as StorefrontForm, cc as StorefrontFormFieldErrorCode, cd as StorefrontFormFile, ce as StorefrontFormSettings, cf as StorefrontFormSubmitInput, cg as StorefrontFormSubmitResult, ch as StorefrontFormUpload, ci as SubmitQuoteInput, cj as SubmitReturnInput, ck as SubmitReviewInput, cl as Subscription, cm as SubscriptionAction, cn as SubscriptionFrequency, co as SubscriptionItem, cp as SubscriptionStatus, cq as TaxBreakdownLine, cr as VariantAxis, cs as VariantAxisValue, ct as WishlistItem, cu as clearCartSummary, cv as err, cw as ok, cx as publishCartSummary, cy as toSdkError } from './client-Cf_xibuw.js';
3
3
 
4
4
  /**
5
5
  * Format a price amount with currency using Intl.NumberFormat.
package/dist/next.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { p as BehioStorefrontConfig, B as BehioStorefront } from './client-CmbuYuof.mjs';
1
+ import { p as BehioStorefrontConfig, B as BehioStorefront } from './client-Cf_xibuw.mjs';
2
2
 
3
3
  interface GetBehioOptions extends Partial<BehioStorefrontConfig> {
4
4
  /** Override the cart session cookie name (default: "behio_cart_session"). */
package/dist/next.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { p as BehioStorefrontConfig, B as BehioStorefront } from './client-CmbuYuof.js';
1
+ import { p as BehioStorefrontConfig, B as BehioStorefront } from './client-Cf_xibuw.js';
2
2
 
3
3
  interface GetBehioOptions extends Partial<BehioStorefrontConfig> {
4
4
  /** Override the cart session cookie name (default: "behio_cart_session"). */
package/dist/react.d.mts CHANGED
@@ -538,6 +538,8 @@ interface ProductVariant {
538
538
  stockQuantity?: number | null;
539
539
  /** "Only X left" for this variant — same contract as ProductListItem.lowStockRemaining. */
540
540
  lowStockRemaining?: number | null;
541
+ /** Most pieces the cart accepts for this variant; null = uncapped or hidden stock. SDK 2.13.0. */
542
+ maxPurchasableQuantity?: number | null;
541
543
  /**
542
544
  * Cover image URL for the variant. Falls back to the parent product's
543
545
  * cover when the variant has no photo of its own — see `imageIsInherited`.
@@ -893,6 +895,10 @@ interface ProductAssetGroup {
893
895
  items: ProductAssetItem[];
894
896
  }
895
897
  interface ProductDetail extends ProductListItem {
898
+ /** Most pieces the cart accepts (stock, plus safetyStock under BACKORDER);
899
+ * null when uncapped or the shop hides stock counts. Cap the PDP quantity
900
+ * stepper with it, it is exactly the cart rule. SDK 2.13.0. */
901
+ maxPurchasableQuantity?: number | null;
896
902
  longDescription?: string;
897
903
  /**
898
904
  * @deprecated Legacy per-listing images. Prefer `media`. Each carries its
@@ -1261,6 +1267,13 @@ interface CheckoutPreview {
1261
1267
  giftCardDeducted: number;
1262
1268
  roundingAdjustment: number;
1263
1269
  grandTotal: number;
1270
+ /** VAT contained in `grandTotal` split by rate: order discounts (always
1271
+ * VAT-inclusive) reduce base and VAT per rate, shipping and the payment fee
1272
+ * carry the goods rates. Same numbers as the invoice. SDK 2.12.0. */
1273
+ taxBreakdown?: TaxBreakdownLine[];
1274
+ /** VAT contained in `grandTotal`, the sum of `taxBreakdown[].taxAmount`.
1275
+ * `taxTotal` is the goods VAT before order discounts. SDK 2.12.0. */
1276
+ vatTotal?: number;
1264
1277
  previewToken: string;
1265
1278
  expiresAt: number;
1266
1279
  }
@@ -1331,6 +1344,9 @@ interface CartItemProduct {
1331
1344
  sku: string;
1332
1345
  imageUrl?: string;
1333
1346
  inStock: boolean;
1347
+ /** Pieces left for an "only X left" note on the cart line; null when the
1348
+ * shop does not track stock, hides the nudge or has plenty. SDK 2.13.0. */
1349
+ lowStockRemaining?: number | null;
1334
1350
  currentPrice: number | null;
1335
1351
  /** Minimum order quantity (units); null = no minimum. Clamp the cart
1336
1352
  * stepper's lower bound to this (GAP-48). */
@@ -1418,8 +1434,11 @@ interface Cart {
1418
1434
  * `INCL_VAT`, VAT excluded when it runs `EXCL_VAT`. Not the payable amount,
1419
1435
  * that is `grandTotal`. */
1420
1436
  subtotal: number;
1421
- /** Discount from the applied code. Always based on `subtotal`, i.e. on the
1422
- * prices the customer sees, so "10 % off 200" is 20 in both price modes. */
1437
+ /** Discount from the applied code, VAT-inclusive. The base is always the
1438
+ * VAT-inclusive amount, also when the shop shows prices without VAT: a
1439
+ * discount is never taken from the net base (SDK 2.12.0; before, "10 % off
1440
+ * 200 net" was 20, now it is 24.20 at 21 %). It lowers base and VAT, see
1441
+ * `taxBreakdown` and `vatTotal`. */
1423
1442
  discountTotal: number;
1424
1443
  discount?: CartDiscount;
1425
1444
  /** Auto-apply promotion discount lines (sale/BOGO). */
@@ -1436,11 +1455,16 @@ interface Cart {
1436
1455
  * back to the catalog price), under `EXCL_VAT` it is added on top. Render
1437
1456
  * this as the cart total; do not add `taxTotal` to it. */
1438
1457
  grandTotal: number;
1439
- /** VAT contained in the prices (`INCL_VAT`) or added on top of them
1440
- * (`EXCL_VAT`), across all lines (GAP-30). An estimate finalized at checkout
1441
- * once the shipping country is known. */
1458
+ /** Goods VAT BEFORE order discounts: contained in the prices (`INCL_VAT`) or
1459
+ * added on top (`EXCL_VAT`). Use it for the goods subtotal
1460
+ * (`subtotal` net + `taxTotal`); the VAT the customer pays is `vatTotal`. */
1442
1461
  taxTotal: number;
1443
- /** VAT split by rate for "DPH 21 %: X Kč" summary rows. Empty for a
1462
+ /** VAT contained in `grandTotal`, after the order discount, as on the
1463
+ * invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1464
+ vatTotal?: number;
1465
+ /** VAT of the payable amount split by rate for "DPH 21 %: X Kč" rows. The
1466
+ * order discount reduces base and VAT per rate (since SDK 2.12.0; before it
1467
+ * showed the VAT of the goods before the discount). Empty for a
1444
1468
  * non-VAT-payer shop. */
1445
1469
  taxBreakdown: TaxBreakdownLine[];
1446
1470
  /** Delivery country set via `cart.setDestination()`, null until known. SDK 1.17.0. */
@@ -1553,6 +1577,14 @@ interface CheckoutInput {
1553
1577
  termsConsent?: boolean;
1554
1578
  gdprConsent?: boolean;
1555
1579
  newsletterOptIn?: boolean;
1580
+ /**
1581
+ * Consent to start delivering digital content (courses, downloads,
1582
+ * services) before the withdrawal period ends, which waives the right of
1583
+ * withdrawal (EU Directive 2011/83 art. 16(m)). Render the checkbox for carts
1584
+ * without physical goods (`cart.requiresShipping === false`). Stored on the
1585
+ * order consent record; it does not block the order. SDK 2.13.0.
1586
+ */
1587
+ digitalDeliveryConsent?: boolean;
1556
1588
  /**
1557
1589
  * Consent to marketing SMS, from the optional checkout checkbox. Render it
1558
1590
  * only when `ShopInfo.checkout.collectSmsConsent` is true; shops that do not
@@ -1666,6 +1698,8 @@ interface OrderTracking {
1666
1698
  paymentFee?: number | null;
1667
1699
  discountTotal?: number;
1668
1700
  taxTotal?: number;
1701
+ /** VAT contained in `grandTotal`, as on the invoice. SDK 2.12.0. */
1702
+ vatTotal?: number;
1669
1703
  taxBreakdown?: TaxBreakdownLine[];
1670
1704
  /** Shipping method as the customer chose it (SDK 2.8.0). */
1671
1705
  shippingMethodName?: string | null;
@@ -1698,6 +1732,18 @@ interface OrderStatusHistory {
1698
1732
  changedBy?: string;
1699
1733
  createdAt: number;
1700
1734
  }
1735
+ /** Bank transfer details of an unpaid order (SDK 2.13.0). */
1736
+ interface OrderPaymentInstructions {
1737
+ accountNumber: string | null;
1738
+ iban: string | null;
1739
+ bic: string | null;
1740
+ bankName: string | null;
1741
+ /** Digits only, at most 10 (Czech banks); from the method pattern with the order number. */
1742
+ variableSymbol: string | null;
1743
+ amount: number;
1744
+ currency: string;
1745
+ instructions: string | null;
1746
+ }
1701
1747
  interface OrderDetail extends OrderListItem {
1702
1748
  /** Payment is recorded; access delivery will retry automatically. Do not place a duplicate order. */
1703
1749
  contentDeliveryPending?: boolean;
@@ -1707,6 +1753,10 @@ interface OrderDetail extends OrderListItem {
1707
1753
  shippingMethodName?: string | null;
1708
1754
  /** Payment method in the order language (SDK 2.8.0). */
1709
1755
  paymentMethodName?: string | null;
1756
+ /** Bank transfer details while the order is unpaid; render them on the
1757
+ * confirmation (account, IBAN, variable symbol, amount). Null for other
1758
+ * methods and paid orders. SDK 2.13.0. */
1759
+ paymentInstructions?: OrderPaymentInstructions | null;
1710
1760
  /** Pickup point the customer chose, a public place (SDK 2.8.0). */
1711
1761
  pickupPoint?: OrderPickupPoint | null;
1712
1762
  /** Parcels the customer can follow (SDK 2.8.0). */
@@ -1718,9 +1768,15 @@ interface OrderDetail extends OrderListItem {
1718
1768
  phone?: string;
1719
1769
  customerNote?: string;
1720
1770
  subtotal: number;
1771
+ /** Goods VAT before order discounts (goods subtotal = `subtotal` + `taxTotal`). */
1721
1772
  taxTotal: number;
1722
- /** VAT split by rate (GAP-30), summed from the order lines. Render
1723
- * "DPH 21 %: X Kč" rows. Empty for a non-VAT order. */
1773
+ /** VAT contained in `grandTotal` (after discounts, incl. shipping), the same
1774
+ * as on the invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1775
+ vatTotal?: number;
1776
+ /** VAT of the amount paid split by rate (GAP-30) for "DPH 21 %: X Kč" rows.
1777
+ * Order discounts reduce base and VAT, shipping and the payment fee carry
1778
+ * the goods rates (since SDK 2.12.0, matching the invoice). Empty for a
1779
+ * non-VAT order. */
1724
1780
  taxBreakdown: TaxBreakdownLine[];
1725
1781
  /** DOMESTIC, OSS, REVERSE_CHARGE (no VAT, buyer accounts for it) or EXPORT (no VAT, outside EU). SDK 1.17.0. */
1726
1782
  vatMode?: "DOMESTIC" | "OSS" | "REVERSE_CHARGE" | "EXPORT" | null;
package/dist/react.d.ts CHANGED
@@ -538,6 +538,8 @@ interface ProductVariant {
538
538
  stockQuantity?: number | null;
539
539
  /** "Only X left" for this variant — same contract as ProductListItem.lowStockRemaining. */
540
540
  lowStockRemaining?: number | null;
541
+ /** Most pieces the cart accepts for this variant; null = uncapped or hidden stock. SDK 2.13.0. */
542
+ maxPurchasableQuantity?: number | null;
541
543
  /**
542
544
  * Cover image URL for the variant. Falls back to the parent product's
543
545
  * cover when the variant has no photo of its own — see `imageIsInherited`.
@@ -893,6 +895,10 @@ interface ProductAssetGroup {
893
895
  items: ProductAssetItem[];
894
896
  }
895
897
  interface ProductDetail extends ProductListItem {
898
+ /** Most pieces the cart accepts (stock, plus safetyStock under BACKORDER);
899
+ * null when uncapped or the shop hides stock counts. Cap the PDP quantity
900
+ * stepper with it, it is exactly the cart rule. SDK 2.13.0. */
901
+ maxPurchasableQuantity?: number | null;
896
902
  longDescription?: string;
897
903
  /**
898
904
  * @deprecated Legacy per-listing images. Prefer `media`. Each carries its
@@ -1261,6 +1267,13 @@ interface CheckoutPreview {
1261
1267
  giftCardDeducted: number;
1262
1268
  roundingAdjustment: number;
1263
1269
  grandTotal: number;
1270
+ /** VAT contained in `grandTotal` split by rate: order discounts (always
1271
+ * VAT-inclusive) reduce base and VAT per rate, shipping and the payment fee
1272
+ * carry the goods rates. Same numbers as the invoice. SDK 2.12.0. */
1273
+ taxBreakdown?: TaxBreakdownLine[];
1274
+ /** VAT contained in `grandTotal`, the sum of `taxBreakdown[].taxAmount`.
1275
+ * `taxTotal` is the goods VAT before order discounts. SDK 2.12.0. */
1276
+ vatTotal?: number;
1264
1277
  previewToken: string;
1265
1278
  expiresAt: number;
1266
1279
  }
@@ -1331,6 +1344,9 @@ interface CartItemProduct {
1331
1344
  sku: string;
1332
1345
  imageUrl?: string;
1333
1346
  inStock: boolean;
1347
+ /** Pieces left for an "only X left" note on the cart line; null when the
1348
+ * shop does not track stock, hides the nudge or has plenty. SDK 2.13.0. */
1349
+ lowStockRemaining?: number | null;
1334
1350
  currentPrice: number | null;
1335
1351
  /** Minimum order quantity (units); null = no minimum. Clamp the cart
1336
1352
  * stepper's lower bound to this (GAP-48). */
@@ -1418,8 +1434,11 @@ interface Cart {
1418
1434
  * `INCL_VAT`, VAT excluded when it runs `EXCL_VAT`. Not the payable amount,
1419
1435
  * that is `grandTotal`. */
1420
1436
  subtotal: number;
1421
- /** Discount from the applied code. Always based on `subtotal`, i.e. on the
1422
- * prices the customer sees, so "10 % off 200" is 20 in both price modes. */
1437
+ /** Discount from the applied code, VAT-inclusive. The base is always the
1438
+ * VAT-inclusive amount, also when the shop shows prices without VAT: a
1439
+ * discount is never taken from the net base (SDK 2.12.0; before, "10 % off
1440
+ * 200 net" was 20, now it is 24.20 at 21 %). It lowers base and VAT, see
1441
+ * `taxBreakdown` and `vatTotal`. */
1423
1442
  discountTotal: number;
1424
1443
  discount?: CartDiscount;
1425
1444
  /** Auto-apply promotion discount lines (sale/BOGO). */
@@ -1436,11 +1455,16 @@ interface Cart {
1436
1455
  * back to the catalog price), under `EXCL_VAT` it is added on top. Render
1437
1456
  * this as the cart total; do not add `taxTotal` to it. */
1438
1457
  grandTotal: number;
1439
- /** VAT contained in the prices (`INCL_VAT`) or added on top of them
1440
- * (`EXCL_VAT`), across all lines (GAP-30). An estimate finalized at checkout
1441
- * once the shipping country is known. */
1458
+ /** Goods VAT BEFORE order discounts: contained in the prices (`INCL_VAT`) or
1459
+ * added on top (`EXCL_VAT`). Use it for the goods subtotal
1460
+ * (`subtotal` net + `taxTotal`); the VAT the customer pays is `vatTotal`. */
1442
1461
  taxTotal: number;
1443
- /** VAT split by rate for "DPH 21 %: X Kč" summary rows. Empty for a
1462
+ /** VAT contained in `grandTotal`, after the order discount, as on the
1463
+ * invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1464
+ vatTotal?: number;
1465
+ /** VAT of the payable amount split by rate for "DPH 21 %: X Kč" rows. The
1466
+ * order discount reduces base and VAT per rate (since SDK 2.12.0; before it
1467
+ * showed the VAT of the goods before the discount). Empty for a
1444
1468
  * non-VAT-payer shop. */
1445
1469
  taxBreakdown: TaxBreakdownLine[];
1446
1470
  /** Delivery country set via `cart.setDestination()`, null until known. SDK 1.17.0. */
@@ -1553,6 +1577,14 @@ interface CheckoutInput {
1553
1577
  termsConsent?: boolean;
1554
1578
  gdprConsent?: boolean;
1555
1579
  newsletterOptIn?: boolean;
1580
+ /**
1581
+ * Consent to start delivering digital content (courses, downloads,
1582
+ * services) before the withdrawal period ends, which waives the right of
1583
+ * withdrawal (EU Directive 2011/83 art. 16(m)). Render the checkbox for carts
1584
+ * without physical goods (`cart.requiresShipping === false`). Stored on the
1585
+ * order consent record; it does not block the order. SDK 2.13.0.
1586
+ */
1587
+ digitalDeliveryConsent?: boolean;
1556
1588
  /**
1557
1589
  * Consent to marketing SMS, from the optional checkout checkbox. Render it
1558
1590
  * only when `ShopInfo.checkout.collectSmsConsent` is true; shops that do not
@@ -1666,6 +1698,8 @@ interface OrderTracking {
1666
1698
  paymentFee?: number | null;
1667
1699
  discountTotal?: number;
1668
1700
  taxTotal?: number;
1701
+ /** VAT contained in `grandTotal`, as on the invoice. SDK 2.12.0. */
1702
+ vatTotal?: number;
1669
1703
  taxBreakdown?: TaxBreakdownLine[];
1670
1704
  /** Shipping method as the customer chose it (SDK 2.8.0). */
1671
1705
  shippingMethodName?: string | null;
@@ -1698,6 +1732,18 @@ interface OrderStatusHistory {
1698
1732
  changedBy?: string;
1699
1733
  createdAt: number;
1700
1734
  }
1735
+ /** Bank transfer details of an unpaid order (SDK 2.13.0). */
1736
+ interface OrderPaymentInstructions {
1737
+ accountNumber: string | null;
1738
+ iban: string | null;
1739
+ bic: string | null;
1740
+ bankName: string | null;
1741
+ /** Digits only, at most 10 (Czech banks); from the method pattern with the order number. */
1742
+ variableSymbol: string | null;
1743
+ amount: number;
1744
+ currency: string;
1745
+ instructions: string | null;
1746
+ }
1701
1747
  interface OrderDetail extends OrderListItem {
1702
1748
  /** Payment is recorded; access delivery will retry automatically. Do not place a duplicate order. */
1703
1749
  contentDeliveryPending?: boolean;
@@ -1707,6 +1753,10 @@ interface OrderDetail extends OrderListItem {
1707
1753
  shippingMethodName?: string | null;
1708
1754
  /** Payment method in the order language (SDK 2.8.0). */
1709
1755
  paymentMethodName?: string | null;
1756
+ /** Bank transfer details while the order is unpaid; render them on the
1757
+ * confirmation (account, IBAN, variable symbol, amount). Null for other
1758
+ * methods and paid orders. SDK 2.13.0. */
1759
+ paymentInstructions?: OrderPaymentInstructions | null;
1710
1760
  /** Pickup point the customer chose, a public place (SDK 2.8.0). */
1711
1761
  pickupPoint?: OrderPickupPoint | null;
1712
1762
  /** Parcels the customer can follow (SDK 2.8.0). */
@@ -1718,9 +1768,15 @@ interface OrderDetail extends OrderListItem {
1718
1768
  phone?: string;
1719
1769
  customerNote?: string;
1720
1770
  subtotal: number;
1771
+ /** Goods VAT before order discounts (goods subtotal = `subtotal` + `taxTotal`). */
1721
1772
  taxTotal: number;
1722
- /** VAT split by rate (GAP-30), summed from the order lines. Render
1723
- * "DPH 21 %: X Kč" rows. Empty for a non-VAT order. */
1773
+ /** VAT contained in `grandTotal` (after discounts, incl. shipping), the same
1774
+ * as on the invoice. Sum of `taxBreakdown[].taxAmount`. SDK 2.12.0. */
1775
+ vatTotal?: number;
1776
+ /** VAT of the amount paid split by rate (GAP-30) for "DPH 21 %: X Kč" rows.
1777
+ * Order discounts reduce base and VAT, shipping and the payment fee carry
1778
+ * the goods rates (since SDK 2.12.0, matching the invoice). Empty for a
1779
+ * non-VAT order. */
1724
1780
  taxBreakdown: TaxBreakdownLine[];
1725
1781
  /** DOMESTIC, OSS, REVERSE_CHARGE (no VAT, buyer accounts for it) or EXPORT (no VAT, outside EU). SDK 1.17.0. */
1726
1782
  vatMode?: "DOMESTIC" | "OSS" | "REVERSE_CHARGE" | "EXPORT" | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@behio/storefront-sdk",
3
- "version": "2.11.0",
3
+ "version": "2.13.0",
4
4
  "description": "TypeScript SDK for Behio headless e-commerce: core client + React hooks",
5
5
  "author": "Behio",
6
6
  "license": "MIT",