@thorprovider/types 7.7.0 → 7.9.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/index.d.ts CHANGED
@@ -82,6 +82,36 @@ interface Country {
82
82
  /** ISO 3166-1 numeric code (optional, e.g., "840", "724") */
83
83
  numCode?: string;
84
84
  }
85
+ /**
86
+ * How a promotion was applied.
87
+ *
88
+ * - `coupon`: the shopper entered a code.
89
+ * - `automatic`: the backend applied it without a code.
90
+ * - `discount`: an adjustment whose promotion identity is not available.
91
+ */
92
+ type PromotionKind = 'coupon' | 'automatic' | 'discount';
93
+ /**
94
+ * Where a promotion was applied, as far as the backend adjustments reveal.
95
+ *
96
+ * `items` and `shipping` are derived from the adjustment location. `order` is
97
+ * used when no adjustment location is available yet (for example a code applied
98
+ * before a shipping method exists).
99
+ */
100
+ type PromotionScope = 'order' | 'items' | 'shipping';
101
+ /**
102
+ * One promotion row from the backend's discount adjustments.
103
+ *
104
+ * `amount` is the sum of the adjustments attributed to this promotion, never a
105
+ * locally computed percentage or configured value.
106
+ */
107
+ interface PromotionSummary {
108
+ id: string;
109
+ code?: string;
110
+ label: string;
111
+ kind: PromotionKind;
112
+ scope: PromotionScope;
113
+ amount: Money;
114
+ }
85
115
 
86
116
  /**
87
117
  * @thorprovider/types — Commerce contracts (type-only)
@@ -213,6 +243,21 @@ interface CheckoutContactValues {
213
243
  lastName: string;
214
244
  phone: string;
215
245
  }
246
+ /**
247
+ * Guest contact stored on the cart/order (never on the Customer record).
248
+ *
249
+ * The email is authoritative on `Cart.email`; this shape carries the display
250
+ * name and phone the shopper entered for the order.
251
+ */
252
+ interface GuestContact {
253
+ firstName: string;
254
+ lastName: string;
255
+ phone: string;
256
+ }
257
+ /** Guest contact payload accepted by the checkout contact route. */
258
+ interface CheckoutGuestContact extends GuestContact {
259
+ email: string;
260
+ }
216
261
  /** Authenticated identity mapped by the host. No token or raw customer object. */
217
262
  interface CheckoutCustomerIdentity {
218
263
  id: string;
@@ -1413,6 +1458,40 @@ type CatalogQueryOutcome = {
1413
1458
  * Cart types - unified interface for all commerce providers
1414
1459
  */
1415
1460
 
1461
+ /**
1462
+ * One quantity-price tier for a cart line.
1463
+ *
1464
+ * `maxQuantity` is absent for an open-ended tier. The unit price is the
1465
+ * backend's effective price for that range; consumers render it and never
1466
+ * derive it from a percentage or a configured amount.
1467
+ */
1468
+ interface PriceTier {
1469
+ minQuantity: number;
1470
+ maxQuantity?: number;
1471
+ unitPrice: Money;
1472
+ }
1473
+ /**
1474
+ * Per-line checkout projection: stock and the effective quantity-price ladder.
1475
+ *
1476
+ * `availableQuantity` is the maximum number of complete units a single
1477
+ * sales-channel warehouse can serve, never the sum across warehouses.
1478
+ * `basePrice` is the effective group's base price when the backend reports one;
1479
+ * `tiers` is the quantity ladder. Both are omitted/empty when the backend does
1480
+ * not expose them.
1481
+ */
1482
+ interface CheckoutLineProjectionLine {
1483
+ lineId: string;
1484
+ variantId: string;
1485
+ availableQuantity?: number;
1486
+ stockStatus?: StockStatus;
1487
+ locationId?: string;
1488
+ basePrice?: Money;
1489
+ tiers: PriceTier[];
1490
+ }
1491
+ interface CheckoutLineProjection {
1492
+ lines: CheckoutLineProjectionLine[];
1493
+ stockValidation: StockValidation;
1494
+ }
1416
1495
  /**
1417
1496
  * Product reference in cart
1418
1497
  */
@@ -1429,6 +1508,15 @@ interface CartItem {
1429
1508
  id: string | undefined;
1430
1509
  quantity: number;
1431
1510
  stockStatus?: StockStatus;
1511
+ /**
1512
+ * Maximum complete units a single sales-channel warehouse can serve, when
1513
+ * the backend exposes stock. Absent for unmanaged inventory or backorder.
1514
+ */
1515
+ availableQuantity?: number;
1516
+ /** Effective quantity-price ladder, when the backend exposes one. */
1517
+ tiers?: PriceTier[];
1518
+ /** Effective price group's base price, when the backend reports one. */
1519
+ basePrice?: Money;
1432
1520
  cost: {
1433
1521
  totalAmount: Money;
1434
1522
  /**
@@ -1516,6 +1604,28 @@ interface Cart {
1516
1604
  * cart that belongs to another shopper.
1517
1605
  */
1518
1606
  customerId?: string;
1607
+ /**
1608
+ * Contact email stored on the cart.
1609
+ *
1610
+ * For a guest checkout the backend copies it to the order and uses it for the
1611
+ * confirmation email. It is the authoritative contact email; the name and
1612
+ * phone live in `guestContact`.
1613
+ */
1614
+ email?: string;
1615
+ /**
1616
+ * Whether the cart's customer is a registered account (`has_account=true`).
1617
+ *
1618
+ * A guest customer created natively by Medusa has `has_account=false`; the
1619
+ * runtime uses this flag to exclude registered-only instruments such as store
1620
+ * credit.
1621
+ */
1622
+ customerHasAccount?: boolean;
1623
+ /**
1624
+ * Guest contact carried in `cart.metadata.guest_contact`.
1625
+ *
1626
+ * Never written to the Customer record; the order inherits the metadata.
1627
+ */
1628
+ guestContact?: GuestContact;
1519
1629
  /** Backend id of the applied shipping method, when one is selected. */
1520
1630
  selectedShippingMethodId?: string;
1521
1631
  /**
@@ -1526,6 +1636,11 @@ interface Cart {
1526
1636
  * (the applied shipping-method record id). Absent when no method is applied.
1527
1637
  */
1528
1638
  selectedShippingOptionId?: string;
1639
+ /**
1640
+ * One row per promotion resolved from the backend's adjustments. Absent when
1641
+ * the provider does not expose a promotion breakdown.
1642
+ */
1643
+ promotions?: PromotionSummary[];
1529
1644
  /** Platform-specific backend metadata, carried through unchanged. */
1530
1645
  metadata?: Record<string, unknown>;
1531
1646
  }
@@ -1935,6 +2050,8 @@ interface OrderDeliveryGroup {
1935
2050
  /**
1936
2051
  * Order-line ids belonging to this group, only when the backend exposes the
1937
2052
  * membership. Consumers MUST NOT invent an assignment when it is absent.
2053
+ * A line whose allocations span more than one group is ambiguous and is
2054
+ * omitted from every group rather than assigned arbitrarily.
1938
2055
  */
1939
2056
  lineIds?: string[];
1940
2057
  }
@@ -1969,6 +2086,14 @@ interface Order {
1969
2086
  fulfillmentStatus: FulfillmentStatus;
1970
2087
  customerId?: string;
1971
2088
  customer?: Customer;
2089
+ /**
2090
+ * Sales channel the order belongs to (Medusa `sales_channel_id`).
2091
+ *
2092
+ * Carried so the runtime can prove a receipt belongs to the validated store
2093
+ * channel before rendering it; a provider that cannot expose it leaves it
2094
+ * absent and the receipt path fails closed.
2095
+ */
2096
+ salesChannelId?: string;
1972
2097
  items: OrderItem[];
1973
2098
  subtotal: Money;
1974
2099
  total: Money;
@@ -1998,6 +2123,11 @@ interface Order {
1998
2123
  * can render its breakdown after a reload without inventing amounts.
1999
2124
  */
2000
2125
  payments?: OrderPayment[];
2126
+ /**
2127
+ * One row per promotion resolved from the order's item and shipping
2128
+ * adjustments. Absent when the backend does not expose a breakdown.
2129
+ */
2130
+ promotions?: PromotionSummary[];
2001
2131
  /** Backend tax rate in basis points, when the order reports one rate. */
2002
2132
  taxRateBps?: number;
2003
2133
  /**
@@ -2074,6 +2204,131 @@ interface GetOrdersOptions {
2074
2204
  * @see {@link GetOrdersCallback} for callback signature
2075
2205
  */
2076
2206
  customFetcher?: GetOrdersCallback;
2207
+ /**
2208
+ * Optional server-side history query. Additive: omitted callers keep the
2209
+ * legacy array-returning behaviour.
2210
+ */
2211
+ query?: CustomerOrderHistoryQuery;
2212
+ }
2213
+ /**
2214
+ * Native Medusa payment status shared by Order Detail and Order History.
2215
+ *
2216
+ * Kept wider than {@link PaymentStatus} because neither surface may collapse
2217
+ * `partially_captured`, `partially_authorized`, `awaiting` or `requires_action`
2218
+ * without lying about the financial state. The host maps it to its own view.
2219
+ */
2220
+ type CustomerOrderPaymentStatus = 'not_paid' | 'awaiting' | 'authorized' | 'partially_authorized' | 'captured' | 'partially_captured' | 'partially_refunded' | 'refunded' | 'canceled' | 'requires_action';
2221
+ /** Native Medusa fulfillment status shared by Order Detail and Order History. */
2222
+ type CustomerOrderFulfillmentStatus = 'not_fulfilled' | 'partially_fulfilled' | 'fulfilled' | 'partially_shipped' | 'shipped' | 'partially_delivered' | 'delivered' | 'canceled';
2223
+ /** Surface-level status of one fulfillment, shared with Order Detail. */
2224
+ type CustomerOrderFulfillmentItemStatus = 'pending' | 'preparing' | 'shipped' | 'delivered' | 'partially_delivered' | 'ready_for_pickup' | 'picked_up' | 'cancelled';
2225
+ /** Actions the backend can prove from the order state. */
2226
+ type CustomerOrderAction = 'reorder' | 'invoice' | 'track' | 'return' | 'exchange' | 'problem' | 'cancel' | 'pay-balance' | 'support';
2227
+ type CustomerOrderHistoryQuick = 'all' | 'in-progress' | 'completed' | 'cancelled' | 'attention';
2228
+ type CustomerOrderHistorySort = 'newest' | 'oldest' | 'total-desc' | 'total-asc' | 'updated';
2229
+ type CustomerOrderHistoryDatePreset = 'today' | '7d' | '30d' | '90d' | 'year' | 'custom';
2230
+ type CustomerOrderHistoryCommercialStatus = 'pending' | 'processing' | 'completed' | 'cancelled';
2231
+ type CustomerOrderHistoryCommercialFilter = CustomerOrderHistoryCommercialStatus | 'requires-action';
2232
+ type CustomerOrderHistoryPaymentFilter = 'unpaid' | 'authorized' | 'partially_paid' | 'paid';
2233
+ type CustomerOrderHistoryRefundFilter = 'none' | 'partial' | 'full';
2234
+ type CustomerOrderHistoryFulfilmentFilter = 'unfulfilled' | 'preparing' | 'shipped' | 'partially_delivered' | 'delivered' | 'delayed' | 'ready_for_pickup';
2235
+ type CustomerOrderHistoryDeliveryMode = 'shipping' | 'pickup' | 'mixed';
2236
+ type CustomerOrderHistoryReturnStatus = 'none' | 'requested' | 'in_progress' | 'completed';
2237
+ /**
2238
+ * Server-side history filter selection. OR inside a group, AND between groups.
2239
+ *
2240
+ * The B2B groups intentionally have no fields: buyer, company, branch, payment
2241
+ * terms and purchase order have no real source yet and are rejected by the
2242
+ * backend instead of being silently ignored.
2243
+ */
2244
+ interface CustomerOrderHistoryFilters {
2245
+ commercial?: CustomerOrderHistoryCommercialFilter[];
2246
+ payment?: CustomerOrderHistoryPaymentFilter[];
2247
+ refund?: CustomerOrderHistoryRefundFilter[];
2248
+ fulfilment?: CustomerOrderHistoryFulfilmentFilter[];
2249
+ mode?: CustomerOrderHistoryDeliveryMode[];
2250
+ returns?: CustomerOrderHistoryReturnStatus[];
2251
+ products?: string;
2252
+ }
2253
+ /** One server-side Order History query. */
2254
+ interface CustomerOrderHistoryQuery {
2255
+ search?: string;
2256
+ quick?: CustomerOrderHistoryQuick;
2257
+ filters?: CustomerOrderHistoryFilters;
2258
+ date?: {
2259
+ preset: CustomerOrderHistoryDatePreset;
2260
+ from?: string;
2261
+ to?: string;
2262
+ };
2263
+ /** Integer minor units in `currency`; never converted. */
2264
+ amount?: {
2265
+ min?: number;
2266
+ max?: number;
2267
+ currency: string;
2268
+ };
2269
+ sort?: CustomerOrderHistorySort;
2270
+ page?: number;
2271
+ pageSize?: number;
2272
+ }
2273
+ /** Options for one authenticated customer history read. */
2274
+ interface CustomerOrderHistoryOptions extends CustomerOrderHistoryQuery {
2275
+ salesChannelId?: string;
2276
+ signal?: AbortSignal;
2277
+ }
2278
+ /** One shipment summary inside an Order History record. */
2279
+ interface CustomerOrderHistoryShipment {
2280
+ id: string;
2281
+ mode: 'shipping' | 'pickup';
2282
+ status: CustomerOrderFulfillmentItemStatus;
2283
+ itemCount: number;
2284
+ shippedAt?: string;
2285
+ deliveredAt?: string;
2286
+ trackingNumber?: string;
2287
+ trackingUrl?: string;
2288
+ }
2289
+ /**
2290
+ * One normalised Order History row.
2291
+ *
2292
+ * Native payment and fulfillment statuses are preserved. The host maps them to
2293
+ * the block contract; this type never invents credit terms, buyer context or
2294
+ * partial cancellations.
2295
+ */
2296
+ interface CustomerOrderHistoryRecord {
2297
+ id: string;
2298
+ orderNumber: string;
2299
+ placedAt: string;
2300
+ updatedAt: string;
2301
+ total: Money;
2302
+ items: OrderItem[];
2303
+ itemCount: number;
2304
+ commercial: OrderStatus;
2305
+ payment: {
2306
+ status: CustomerOrderPaymentStatus;
2307
+ due: Money;
2308
+ paid: Money;
2309
+ refunded: Money;
2310
+ credit?: Money;
2311
+ creditTerms: boolean;
2312
+ };
2313
+ refund: 'none' | 'partial' | 'full';
2314
+ fulfilment: {
2315
+ status: CustomerOrderFulfillmentStatus;
2316
+ shipments: CustomerOrderHistoryShipment[];
2317
+ };
2318
+ deliveryMode: CustomerOrderHistoryDeliveryMode;
2319
+ returns: CustomerOrderHistoryReturnStatus;
2320
+ availableActions: CustomerOrderAction[];
2321
+ }
2322
+ /** One server-side Order History page. */
2323
+ interface CustomerOrderHistoryPage {
2324
+ items: CustomerOrderHistoryRecord[];
2325
+ total: number;
2326
+ totalAll: number;
2327
+ pageCount: number;
2328
+ counts?: Record<CustomerOrderHistoryQuick, number>;
2329
+ warning?: boolean;
2330
+ limit: number;
2331
+ offset: number;
2077
2332
  }
2078
2333
  /**
2079
2334
  * Options for the additive paginated order-history contract.
@@ -2091,6 +2346,8 @@ interface GetCustomerOrdersPageOptions {
2091
2346
  pageSize?: number;
2092
2347
  /** The store's configured sales channel id (explicit; never a blind first id). */
2093
2348
  salesChannelId?: string;
2349
+ /** Optional server-side history filters. Additive. */
2350
+ query?: CustomerOrderHistoryQuery;
2094
2351
  }
2095
2352
  /**
2096
2353
  * The additive paginated order-history result.
@@ -2106,6 +2363,355 @@ interface CustomerOrdersPage {
2106
2363
  limit: number;
2107
2364
  offset: number;
2108
2365
  }
2366
+ /**
2367
+ * Sections of one authenticated customer order detail.
2368
+ *
2369
+ * The identifiers match the `OrderDetailPort` section ids so a host can map a
2370
+ * per-section issue without translating names.
2371
+ */
2372
+ type CustomerOrderDetailSection = 'logistics' | 'items' | 'pricing' | 'payments' | 'afterSales' | 'documents' | 'b2b' | 'revisions';
2373
+ /** Why one section of a detail read could not be delivered. */
2374
+ type CustomerOrderDetailIssue = 'unavailable' | 'error' | 'forbidden';
2375
+ /** Native Medusa payment status for a detail read (shared with history). */
2376
+ type CustomerOrderDetailPaymentStatus = CustomerOrderPaymentStatus;
2377
+ /** Native Medusa fulfillment status for a detail read (shared with history). */
2378
+ type CustomerOrderDetailFulfillmentStatus = CustomerOrderFulfillmentStatus;
2379
+ type CustomerOrderDetailAdjustmentScope = 'product' | 'order' | 'shipping' | 'payment';
2380
+ type CustomerOrderDetailAdjustmentDirection = 'discount' | 'surcharge';
2381
+ type CustomerOrderDetailAdjustmentSource = 'promotion' | 'manual' | 'contract' | 'tax';
2382
+ /**
2383
+ * One persisted adjustment as read from the order.
2384
+ *
2385
+ * `amount` is the backend's historical amount. A discount is never re-derived
2386
+ * from the current catalog or from a promotion's nominal value.
2387
+ */
2388
+ interface CustomerOrderDetailAdjustment {
2389
+ id: string;
2390
+ label: string;
2391
+ scope: CustomerOrderDetailAdjustmentScope;
2392
+ direction: CustomerOrderDetailAdjustmentDirection;
2393
+ amount: Money;
2394
+ source: CustomerOrderDetailAdjustmentSource;
2395
+ promotionId?: string;
2396
+ code?: string;
2397
+ }
2398
+ /** One persisted tax line attached to a product line or a shipping method. */
2399
+ interface CustomerOrderDetailTaxLine {
2400
+ id: string;
2401
+ label: string;
2402
+ /** Display-only rate (percent). Never used to recalculate the amount. */
2403
+ rate?: number;
2404
+ amount: Money;
2405
+ included?: boolean;
2406
+ exemption?: boolean;
2407
+ }
2408
+ type CustomerOrderDetailAttributeKind = 'variant' | 'commercial' | 'custom';
2409
+ /** One product attribute captured on the order line. */
2410
+ interface CustomerOrderDetailAttribute {
2411
+ id: string;
2412
+ label: string;
2413
+ value: string;
2414
+ kind: CustomerOrderDetailAttributeKind;
2415
+ }
2416
+ type CustomerOrderDetailPriceKind = 'list' | 'volume' | 'contract' | 'customer' | 'promotion';
2417
+ /** Historical unit price: list/original and applied, with its price kind. */
2418
+ interface CustomerOrderDetailLinePrice {
2419
+ original: Money;
2420
+ applied: Money;
2421
+ kind: CustomerOrderDetailPriceKind;
2422
+ }
2423
+ type CustomerOrderDetailProductKind = 'physical' | 'digital' | 'bundle' | 'service' | 'configured' | 'custom' | 'serialized' | 'warranty' | 'measured';
2424
+ /** A file linked to the product variant (manual, warranty, spec sheet). */
2425
+ interface CustomerOrderDetailAttachment {
2426
+ id: string;
2427
+ name: string;
2428
+ url: string;
2429
+ mimeType?: string;
2430
+ size?: number;
2431
+ }
2432
+ /** Units of one line attributed to one fulfillment. */
2433
+ interface CustomerOrderDetailAllocation {
2434
+ fulfillmentId: string;
2435
+ quantity: number;
2436
+ }
2437
+ /**
2438
+ * One historical order line.
2439
+ *
2440
+ * `quantity` is the ordered quantity; `cancelledQuantity` is only non-zero when
2441
+ * Medusa cancelled the whole order, and excludes units already delivered.
2442
+ */
2443
+ interface CustomerOrderDetailLine {
2444
+ id: string;
2445
+ productId?: string;
2446
+ variantId?: string;
2447
+ title: string;
2448
+ variantTitle?: string;
2449
+ sku?: string;
2450
+ image?: Image;
2451
+ quantity: number;
2452
+ cancelledQuantity: number;
2453
+ unitPrice: CustomerOrderDetailLinePrice;
2454
+ subtotal: Money;
2455
+ total: Money;
2456
+ discounts: CustomerOrderDetailAdjustment[];
2457
+ taxes: CustomerOrderDetailTaxLine[];
2458
+ attributes: CustomerOrderDetailAttribute[];
2459
+ attachments?: CustomerOrderDetailAttachment[];
2460
+ kind: CustomerOrderDetailProductKind;
2461
+ serialNumber?: string;
2462
+ warranty?: string;
2463
+ measure?: {
2464
+ quantity: number;
2465
+ unit: string;
2466
+ };
2467
+ bundle?: {
2468
+ name: string;
2469
+ sku: string;
2470
+ quantity: number;
2471
+ }[];
2472
+ note?: string;
2473
+ allocations?: CustomerOrderDetailAllocation[];
2474
+ }
2475
+ /** The selected method of one logistics group. */
2476
+ interface CustomerOrderDetailShippingMethod {
2477
+ id: string;
2478
+ name: string;
2479
+ description?: string;
2480
+ /** Internal warehouse/profile id; never rendered by the surface. */
2481
+ profileId?: string;
2482
+ }
2483
+ type CustomerOrderDetailPickupStatus = 'scheduled' | 'ready' | 'picked_up' | 'expired';
2484
+ /**
2485
+ * Pickup point details the backend can prove.
2486
+ *
2487
+ * Schedule, instructions and evidence are absent when the backend does not
2488
+ * report them; the host must not invent them.
2489
+ */
2490
+ interface CustomerOrderDetailPickup {
2491
+ locationName: string;
2492
+ address?: Address;
2493
+ status: CustomerOrderDetailPickupStatus;
2494
+ code?: string;
2495
+ availableFrom?: string;
2496
+ expiresAt?: string;
2497
+ }
2498
+ /** One confirmed logistics group on the order. */
2499
+ interface CustomerOrderDetailGroup {
2500
+ id: string;
2501
+ mode: 'shipping' | 'pickup';
2502
+ method: CustomerOrderDetailShippingMethod;
2503
+ shippingSubtotal: Money;
2504
+ discounts: CustomerOrderDetailAdjustment[];
2505
+ taxes: CustomerOrderDetailTaxLine[];
2506
+ total: Money;
2507
+ etaLabel?: string;
2508
+ pickup?: CustomerOrderDetailPickup;
2509
+ }
2510
+ /** Surface-level status of one fulfillment (shared with history). */
2511
+ type CustomerOrderDetailFulfillmentItemStatus = CustomerOrderFulfillmentItemStatus;
2512
+ /** One package/label attached to a fulfillment. */
2513
+ interface CustomerOrderDetailPackage {
2514
+ id: string;
2515
+ label?: string;
2516
+ }
2517
+ /** One fulfillment with its allocations, packages and tracking. */
2518
+ interface CustomerOrderDetailFulfillment {
2519
+ id: string;
2520
+ groupId: string;
2521
+ status: CustomerOrderDetailFulfillmentItemStatus;
2522
+ providerId?: string;
2523
+ carrier?: string;
2524
+ trackingNumber?: string;
2525
+ trackingUrl?: string;
2526
+ packedAt?: string;
2527
+ shippedAt?: string;
2528
+ deliveredAt?: string;
2529
+ canceledAt?: string;
2530
+ packages: CustomerOrderDetailPackage[];
2531
+ allocations: CustomerOrderDetailAllocation[];
2532
+ pickup?: CustomerOrderDetailPickup;
2533
+ }
2534
+ type CustomerOrderDetailPromotionScope = 'product' | 'order' | 'shipping' | 'payment';
2535
+ type CustomerOrderDetailPromotionApplication = 'automatic' | 'code';
2536
+ type CustomerOrderDetailPromotionNominal = {
2537
+ kind: 'percent';
2538
+ percent: number;
2539
+ } | {
2540
+ kind: 'fixed';
2541
+ money: Money;
2542
+ };
2543
+ /**
2544
+ * One promotion aggregated from the order's persisted adjustments.
2545
+ *
2546
+ * `discounted` is the sum of the unique adjustment ids in `adjustmentIds`;
2547
+ * `nominal` is display context only and never the charged amount.
2548
+ */
2549
+ interface CustomerOrderDetailPromotion {
2550
+ id: string;
2551
+ code?: string;
2552
+ name?: string;
2553
+ type?: 'standard' | 'buyget';
2554
+ scope: CustomerOrderDetailPromotionScope;
2555
+ application: CustomerOrderDetailPromotionApplication;
2556
+ nominal?: CustomerOrderDetailPromotionNominal;
2557
+ discounted: Money;
2558
+ adjustmentIds: string[];
2559
+ lineIds: string[];
2560
+ groupIds?: string[];
2561
+ buyXGetY?: {
2562
+ conditionLineIds: string[];
2563
+ rewardLineIds: string[];
2564
+ rewardQuantity?: number;
2565
+ freeQuantity?: number;
2566
+ partial?: boolean;
2567
+ };
2568
+ }
2569
+ type CustomerOrderDetailTransactionKind = 'payment' | 'authorization' | 'refund' | 'credit';
2570
+ type CustomerOrderDetailTransactionStatus = 'pending' | 'authorized' | 'captured' | 'refunded' | 'failed' | 'canceled';
2571
+ type CustomerOrderDetailTransactionMethod = 'card' | 'wallet' | 'transfer' | 'credit' | 'cash' | 'system' | 'gift_card' | 'store_credit' | 'other';
2572
+ /** One financial movement (payment, authorization, refund or credit). */
2573
+ interface CustomerOrderDetailTransaction {
2574
+ id: string;
2575
+ kind: CustomerOrderDetailTransactionKind;
2576
+ status: CustomerOrderDetailTransactionStatus;
2577
+ amount: Money;
2578
+ at: string;
2579
+ providerId?: string;
2580
+ method?: CustomerOrderDetailTransactionMethod;
2581
+ reference?: string;
2582
+ }
2583
+ type CustomerOrderDetailCaseType = 'return' | 'exchange' | 'claim';
2584
+ type CustomerOrderDetailCaseStatus = 'requested' | 'approved' | 'in_transit' | 'received' | 'partially_received' | 'completed' | 'rejected' | 'canceled';
2585
+ interface CustomerOrderDetailCaseLine {
2586
+ lineId: string;
2587
+ quantity: number;
2588
+ receivedQuantity?: number;
2589
+ }
2590
+ /** One basic after-sales case (native return, exchange or claim). */
2591
+ interface CustomerOrderDetailCase {
2592
+ id: string;
2593
+ type: CustomerOrderDetailCaseType;
2594
+ status: CustomerOrderDetailCaseStatus;
2595
+ createdAt: string;
2596
+ reason?: string;
2597
+ lines: CustomerOrderDetailCaseLine[];
2598
+ refund?: Money;
2599
+ differenceDue?: Money;
2600
+ replacement?: {
2601
+ name: string;
2602
+ sku: string;
2603
+ quantity: number;
2604
+ }[];
2605
+ shipment?: {
2606
+ carrier?: string;
2607
+ trackingNumber?: string;
2608
+ trackingUrl?: string;
2609
+ status?: string;
2610
+ };
2611
+ }
2612
+ type CustomerOrderDetailDocumentKind = 'invoice' | 'receipt' | 'payment-proof' | 'credit-note' | 'shipping' | 'business';
2613
+ /** One document the store can actually issue. Absent when none exists. */
2614
+ interface CustomerOrderDetailDocument {
2615
+ id: string;
2616
+ kind: CustomerOrderDetailDocumentKind;
2617
+ label: string;
2618
+ issuedAt?: string;
2619
+ available: boolean;
2620
+ }
2621
+ type CustomerOrderDetailInvoiceStatus = 'not_issued' | 'pending' | 'issued' | 'overdue';
2622
+ type CustomerOrderDetailApprovalStatus = 'pending' | 'approved' | 'rejected';
2623
+ /** B2B extension. Not produced by the current backend. */
2624
+ interface CustomerOrderDetailBusiness {
2625
+ company: string;
2626
+ buyer: string;
2627
+ branch?: string;
2628
+ purchaseOrder?: string;
2629
+ internalReference?: string;
2630
+ costCenter?: string;
2631
+ paymentTerms?: string;
2632
+ creditLimit?: Money;
2633
+ creditUsed?: Money;
2634
+ dueAt?: string;
2635
+ invoiceStatus?: CustomerOrderDetailInvoiceStatus;
2636
+ approval?: {
2637
+ status: CustomerOrderDetailApprovalStatus;
2638
+ by?: string;
2639
+ at?: string;
2640
+ };
2641
+ }
2642
+ type CustomerOrderDetailRevisionKind = 'item-added' | 'item-removed' | 'quantity' | 'price' | 'shipping' | 'tax' | 'cancel';
2643
+ /** Post-creation revision extension. Not produced by the current backend. */
2644
+ interface CustomerOrderDetailRevision {
2645
+ id: string;
2646
+ at: string;
2647
+ kind: CustomerOrderDetailRevisionKind;
2648
+ summary: string;
2649
+ delta?: Money;
2650
+ }
2651
+ /** Actions the backend can prove from the order state (shared with history). */
2652
+ type CustomerOrderDetailAction = CustomerOrderAction;
2653
+ /**
2654
+ * The authoritative economic summary of the detail.
2655
+ *
2656
+ * `paid`, `refunded`, `due` and `credit` are computed by the backend from the
2657
+ * payment collections; no consumer recalculates them from transactions.
2658
+ */
2659
+ interface CustomerOrderDetailTotals {
2660
+ itemsSubtotal: Money;
2661
+ itemDiscounts: Money;
2662
+ orderDiscounts: Money;
2663
+ shippingSubtotal: Money;
2664
+ shippingDiscounts: Money;
2665
+ tax: Money;
2666
+ adjustments: Money;
2667
+ total: Money;
2668
+ authorized?: Money;
2669
+ paid: Money;
2670
+ refunded: Money;
2671
+ due: Money;
2672
+ credit?: Money;
2673
+ }
2674
+ /** One authenticated customer order detail. */
2675
+ interface CustomerOrderDetailOrder {
2676
+ id: string;
2677
+ orderNumber: string;
2678
+ status: OrderStatus;
2679
+ paymentStatus: CustomerOrderDetailPaymentStatus;
2680
+ fulfillmentStatus: CustomerOrderDetailFulfillmentStatus;
2681
+ currencyCode: string;
2682
+ salesChannelId?: string;
2683
+ createdAt: string;
2684
+ updatedAt: string;
2685
+ completedAt?: string;
2686
+ cancelledAt?: string;
2687
+ shippingAddress?: Address;
2688
+ billingAddress?: Address;
2689
+ lines: CustomerOrderDetailLine[];
2690
+ groups: CustomerOrderDetailGroup[];
2691
+ fulfillments: CustomerOrderDetailFulfillment[];
2692
+ promotions: CustomerOrderDetailPromotion[];
2693
+ adjustments: CustomerOrderDetailAdjustment[];
2694
+ payments: OrderPayment[];
2695
+ transactions: CustomerOrderDetailTransaction[];
2696
+ cases: CustomerOrderDetailCase[];
2697
+ documents: CustomerOrderDetailDocument[];
2698
+ business?: CustomerOrderDetailBusiness;
2699
+ revisions: CustomerOrderDetailRevision[];
2700
+ totals: CustomerOrderDetailTotals;
2701
+ availableActions: CustomerOrderDetailAction[];
2702
+ }
2703
+ /**
2704
+ * The detail read snapshot: one order plus truthful per-section issues and a
2705
+ * non-blocking partial-load warning. Absent `issues` means every section is
2706
+ * valid; an affected section must not invalidate the rest of the order.
2707
+ */
2708
+ interface CustomerOrderDetailSnapshot {
2709
+ order: CustomerOrderDetailOrder;
2710
+ issues?: Partial<Record<CustomerOrderDetailSection, CustomerOrderDetailIssue>>;
2711
+ warning?: boolean;
2712
+ }
2713
+ /** Alias kept for the backend/OpenSpec contract name. */
2714
+ type CustomerOrderDetail = CustomerOrderDetailSnapshot;
2109
2715
 
2110
2716
  /**
2111
2717
  * @thorprovider/types — Supported Providers (type-only)
@@ -2684,6 +3290,23 @@ interface AuthProvider {
2684
3290
  * @param metadata - Optional metadata for provider-specific requirements
2685
3291
  */
2686
3292
  resetPassword(token: string, password: string, metadata?: Record<string, unknown>): Promise<void>;
3293
+ /**
3294
+ * Request a verification code for the authenticated customer's email.
3295
+ * Optional: providers that cannot verify omit it, and their
3296
+ * `BackendCapabilities.verifyEmail` stays false.
3297
+ */
3298
+ requestEmailVerification?(): Promise<void>;
3299
+ /**
3300
+ * Verify the authenticated customer's email with a provider-issued code.
3301
+ * Optional, paired with `requestEmailVerification`.
3302
+ */
3303
+ verifyEmail?(code: string): Promise<void>;
3304
+ /**
3305
+ * Check a reset code without consuming it, so a multi-step form can keep the
3306
+ * shopper on the code step. Optional: providers without it validate the code
3307
+ * only when `resetPassword` runs.
3308
+ */
3309
+ verifyPasswordResetCode?(code: string): Promise<boolean>;
2687
3310
  /**
2688
3311
  * Get current authenticated customer
2689
3312
  * @returns Customer object or null if not authenticated
@@ -3080,6 +3703,8 @@ interface BackendCapabilities {
3080
3703
  changePasswordDirect: boolean;
3081
3704
  /** Can request password reset via email */
3082
3705
  changePasswordViaEmail: boolean;
3706
+ /** Can verify a customer's email address (code or link) */
3707
+ verifyEmail: boolean;
3083
3708
  /** Can delete customer account (self-service) */
3084
3709
  deleteAccount: boolean;
3085
3710
  /**
@@ -3465,6 +4090,7 @@ interface CommerceProvider {
3465
4090
  */
3466
4091
  createCart(options?: {
3467
4092
  regionId?: string;
4093
+ salesChannelId?: string;
3468
4094
  }): Promise<Cart>;
3469
4095
  /**
3470
4096
  * Get an existing cart by ID
@@ -3485,6 +4111,19 @@ interface CommerceProvider {
3485
4111
  * @throws {ProviderAPIError} If the cart cannot be transferred
3486
4112
  */
3487
4113
  assignCartToCustomer?(cartId: string): Promise<Cart>;
4114
+ /**
4115
+ * Persist the guest checkout contact (email + name + phone) on the cart.
4116
+ *
4117
+ * The backend writes `cart.email` and merges
4118
+ * `cart.metadata.guest_contact`; it never writes the Customer record. The
4119
+ * provider must carry no customer token: the cart id is the capability and
4120
+ * the backend enforces the guest/channel rules.
4121
+ *
4122
+ * @param cartId - Cart ID
4123
+ * @param contact - Guest contact values
4124
+ * @returns The updated cart with the contact stored
4125
+ */
4126
+ updateCheckoutGuestContact?(cartId: string, contact: CheckoutGuestContact): Promise<Cart>;
3488
4127
  /**
3489
4128
  * Add items to cart
3490
4129
  * @param cartId - Cart ID
@@ -3646,6 +4285,22 @@ interface CommerceProvider {
3646
4285
  * @throws {ProviderAPIError} If the backend rejects the selection set
3647
4286
  */
3648
4287
  applyCheckoutShippingGroups?(cartId: string, selections: ShippingGroupSelection[]): Promise<void>;
4288
+ /**
4289
+ * Project stock and the effective quantity-price ladder for each cart line
4290
+ * (OPTIONAL).
4291
+ *
4292
+ * The backend selects the effective price group with Medusa's pricing engine
4293
+ * and reports the maximum number of complete units a single sales-channel
4294
+ * warehouse can serve. Callers render the values; they never sum stock across
4295
+ * warehouses, mix price groups or derive a price locally.
4296
+ *
4297
+ * Optional for the same reason as `getCheckoutShippingGroups`; its absence
4298
+ * is an unsupported capability, not an empty projection.
4299
+ *
4300
+ * @param cartId - Cart ID
4301
+ * @throws {ProviderAPIError} If the backend fails or returns an invalid projection
4302
+ */
4303
+ getCheckoutLineProjection?(cartId: string): Promise<CheckoutLineProjection>;
3649
4304
  /**
3650
4305
  * Initiate payment session with provider
3651
4306
  *
@@ -3801,6 +4456,17 @@ interface CommerceProvider {
3801
4456
  * @returns Order or undefined if not found
3802
4457
  */
3803
4458
  getOrder?(orderId: string): Promise<Order | undefined>;
4459
+ /**
4460
+ * Read a single order through the channel-scoped guest receipt route
4461
+ * (OPTIONAL).
4462
+ *
4463
+ * Unlike `getOrder`, the backend resolves the sales channel from the
4464
+ * publishable key and returns 404 for an order from another channel. The
4465
+ * runtime uses it for the unauthenticated confirmation page; a provider
4466
+ * without it falls back to `getOrder` and must expose `Order.salesChannelId`
4467
+ * so the runtime can verify the channel itself.
4468
+ */
4469
+ getCheckoutOrder?(orderId: string): Promise<Order | undefined>;
3804
4470
  /**
3805
4471
  * Get all orders for a customer (optional)
3806
4472
  *
@@ -3824,22 +4490,39 @@ interface CommerceProvider {
3824
4490
  */
3825
4491
  customerOrdersPage?(options: GetCustomerOrdersPageOptions): Promise<CustomerOrdersPage>;
3826
4492
  /**
3827
- * Resolve ONE order for the authenticated customer (OPTIONAL, additive).
4493
+ * Resolve ONE order for the authenticated customer (OPTIONAL, legacy/mock).
3828
4494
  *
3829
4495
  * Ownership is enforced by the provider: an order that belongs to another
3830
4496
  * customer, another channel, or no customer resolves as `undefined` — the
3831
- * caller must not learn whether it exists. A provider that does not implement
3832
- * this method (a backend without a customer detail endpoint) fails closed at
3833
- * the runtime boundary; the storefront never derives the detail from the
3834
- * order-list payload.
3835
- *
3836
- * `options.salesChannelId` is the store's explicitly configured channel. A
3837
- * provider that can scope by channel MUST reject a foreign order as
3838
- * `undefined`.
4497
+ * caller must not learn whether it exists.
3839
4498
  */
3840
4499
  customerOrderDetail?(orderId: string, options?: {
3841
4500
  salesChannelId?: string;
3842
4501
  }): Promise<Order | undefined>;
4502
+ /**
4503
+ * Read one server-side Order History page (OPTIONAL, additive).
4504
+ *
4505
+ * The backend applies search, filters, date, amount, sort and pagination to
4506
+ * the authenticated customer + sales channel set and returns the real total,
4507
+ * `totalAll`, `pageCount` and optional quick-filter counts. Native payment and
4508
+ * fulfillment statuses are preserved; the host maps them to the block
4509
+ * contract.
4510
+ */
4511
+ customerOrderHistory?(options: CustomerOrderHistoryOptions): Promise<CustomerOrderHistoryPage>;
4512
+ /**
4513
+ * Read one authenticated customer's order detail snapshot (OPTIONAL).
4514
+ *
4515
+ * The backend enforces customer ownership and sales-channel scope before
4516
+ * returning any data. A foreign, unknown or other-channel order must fail
4517
+ * closed; the provider never receives a partial payload for those cases.
4518
+ *
4519
+ * The snapshot carries a per-section `issues` map and a non-blocking
4520
+ * `warning` for a partial load. A provider without this method (for example
4521
+ * the mock data source) fails closed at the runtime boundary.
4522
+ */
4523
+ customerOrderDetailSnapshot?(orderId: string, options?: {
4524
+ signal?: AbortSignal;
4525
+ }): Promise<CustomerOrderDetailSnapshot>;
3843
4526
  /**
3844
4527
  * Get available payment methods
3845
4528
  *
@@ -7345,4 +8028,4 @@ type UpdateBusinessPolicyResponse = {
7345
8028
  business_policy: string;
7346
8029
  };
7347
8030
 
7348
- export type { AccountDropdownConfig, AccountMenuItem, AcknowledgeCostPriceChangesResponse, ActiveFilter, AddOrderEditItemBody, AddOrderEditItemResponse, Address, AdminApiKey, AdminChannelCategory, AdminChannelCustomer, AdminDropshipperAccount, AdminDropshipperBalance, AdminProduct, AdminProductVariant, AdminSalesChannelRef, AdminSiteConfig, AdminSiteConfigHistoryEntry, AdminSiteConfigHistoryEntryFull, AdminStorefrontConfig, AdminStorefrontSeoDefaults, AdminUser, AdvancedSearchProductsOptions, AssignCategoriesToChannelsBody, AssignCategoriesToChannelsResponse, AssignCollectionsToChannelsBody, AssignCollectionsToChannelsResponse, AuditLog, AuditLogAdapter, AuthConfig, AuthMethod, AuthProvider, AuthResponse, AuthStorage, AuthorConfig, BackendCapabilities, BrandConfig, CachedPaymentMethods, CancelDropshipperOrderResponse, CancelMovementBody, CancelMovementResponse, CancelSettlementBody, Cart, CartCost, CartItem, CartLineInput, CartLineUpdate, CartProduct, CartSession, CatalogAppliedFilters, CatalogFacetDemonstrationSource, CatalogFacetId, CatalogQuery, CatalogQueryFailure, CatalogQueryFailureCode, CatalogQueryFailureRepair, CatalogQueryOutcome, CatalogResults, CatalogSortKey, CategoryMapping, ChartDataPoint, ChatAssistantHealthResponse, ChatIntent, ChatMessage, ChatRequest, ChatResponse, ChatSource, ChatSourceVariant, CheckoutAddressLevel, CheckoutAddressOption, CheckoutAddressValues, CheckoutAdjustmentPayment, CheckoutCapturePolicy, CheckoutContactValues, CheckoutCustomerIdentity, CheckoutInterruption, CheckoutInterruptionAction, CheckoutInterruptionKind, CheckoutLocationOptions, CheckoutPaymentPlanItem, CheckoutPaymentSummary, CheckoutPaymentSummaryPayment, CheckoutPaymentSummaryStatus, CheckoutReadState, CheckoutSavedAddress, CheckoutShippingGroup, CheckoutShippingGroupItem, CheckoutShippingOption, CheckoutSubmission, Collection, CollectionProductsOptions, CommerceProvider, CompareProduct, ConfigHistoryEntry, ConfirmMovementBody, ConfirmMovementResponse, ConfirmOrderEditResponse, ConfirmSettlementBody, Connection, ConvertDropshipperDraftOrderBody, ConvertDropshipperDraftOrderResponse, CostPriceChangeItem, CostPriceChangesCheckResponse, CostPriceChangesResponse, Country, CreateAddressData, CreateAjusteBody, CreateAjusteResponse, CreateCategoryMappingBody, CreateCategoryMappingResponse, CreateCobroBody, CreateCobroResponse, CreateCompensacionBody, CreateCompensacionResponse, CreateDropshipperCategoryBody, CreateDropshipperCustomerBody, CreateDropshipperCustomerResponse, CreateDropshipperDraftOrderBody, CreateDropshipperDraftOrderResponse, CreateDropshipperOrderBody, CreateDropshipperOrderResponse, CreateDropshipperPromotionBody, CreateOrderEditBody, CreateOrderEditResponse, CreateOrderItem, CreateOrderNoteBody, CreateOrderNoteResponse, CreatePagoBody, CreatePagoResponse, CreateReversoBody, CreateReversoResponse, CreateSettlementBody, CreateSettlementResponse, Customer, CustomerOrdersPage, DashboardChanges, DashboardConfig, DashboardMetrics, DashboardMetricsAdapter, DashboardOrdersAdapter, DashboardPeriodMetrics, DashboardProductsAdapter, DashboardStats, DashboardTopProduct, DeleteCategoryMappingResponse, DeleteDropshipperCategoryResponse, DeleteDropshipperDraftOrderResponse, DeleteDropshipperPromotionResponse, DeleteOrderNoteResponse, DesignerConfig, DesignerHistoryEntry, DesignerNavItem, DesignerThemeConfig, DesignerThemePreset, DiscountCode, DropshipperAccount, DropshipperAccountRef, DropshipperAddressBody, DropshipperAddressResponse, DropshipperAttributeDefinition, DropshipperAttributeDefinitionValue, DropshipperBalance, DropshipperCategory, DropshipperCostTier, DropshipperCustomer, DropshipperCustomerAddress, DropshipperCustomerDetail, DropshipperCustomerFinancial, DropshipperCustomerStats, DropshipperDashboardCapabilities, DropshipperDraftOrder, DropshipperDraftOrderItem, DropshipperNotificationEventType, DropshipperNotificationPreference, DropshipperOrder, DropshipperOrderCustomer, DropshipperOrderDetail, DropshipperOrderItem, DropshipperOrderShippingAddress, DropshipperOrderTaxLine, DropshipperOrderTimelineEvent, DropshipperOrderTotals, DropshipperPayableOrder, DropshipperPaymentMethodConfig, DropshipperPendingOrders, DropshipperPriceItem, DropshipperPriceTier, DropshipperProduct, DropshipperProductAttachment, DropshipperProductAttribute, DropshipperProductAttributeValue, DropshipperProductImage, DropshipperProductOption, DropshipperProductOptionValue, DropshipperProductPrivateMedia, DropshipperProfile, DropshipperPromotion, DropshipperReceivableOrder, DropshipperSaleTier, DropshipperShippingGroup, DropshipperShippingGroupOption, DropshipperShippingOption, DropshipperVariant, DynamicSource, Edge, ExtendedCreateDropshipperOrderBody, ExtendedCreateDropshipperOrderResponse, FacetSupport, FilterConfig, FilterOption, FilterSection, FulfillmentOption, FulfillmentSet, FulfillmentStatus, GeoCity, GeoCountry, GeoProvince, GetAdminAccountBalanceResponse, GetAdminDropshipperAccountOrdersResponse, GetAdminDropshipperAccountSettlementsOptions, GetAdminDropshipperAccountSettlementsResponse, GetAdminDropshipperAccountsResponse, GetAdminPriceListsResponse, GetAdminSiteConfigHistoryOptions, GetAdminSiteConfigHistoryResponse, GetAdminSiteConfigResponse, GetAdminStorefrontConfigResponse, GetBusinessPolicyResponse, GetCategoriesCallback, GetCategoriesOptions, GetCategoryMappingsOptions, GetCategoryMappingsResponse, GetCategorySalesChannelsResponse, GetChannelApiKeysResponse, GetChannelCategoriesOptions, GetChannelCategoriesResponse, GetChannelCustomersOptions, GetChannelCustomersResponse, GetCollectionSalesChannelsResponse, GetCollectionsOptions, GetCustomerOrdersPageOptions, GetCustomersCallback, GetCustomersOptions, GetDashboardStatsOptions, GetDashboardStatsResponse, GetDropshipperAccountBalanceResponse, GetDropshipperAccountOrdersOptions, GetDropshipperAccountOrdersResponse, GetDropshipperAccountResponse, GetDropshipperAddressesResponse, GetDropshipperAttributesResponse, GetDropshipperCategoriesOptions, GetDropshipperCategoriesResponse, GetDropshipperCustomerDetailResponse, GetDropshipperCustomersOptions, GetDropshipperCustomersResponse, GetDropshipperDraftOrderDetailResponse, GetDropshipperDraftOrdersOptions, GetDropshipperDraftOrdersResponse, GetDropshipperOrderDetailResponse, GetDropshipperOrdersOptions, GetDropshipperOrdersResponse, GetDropshipperPayableResponse, GetDropshipperProductsOptions, GetDropshipperProductsResponse, GetDropshipperPromotionsOptions, GetDropshipperPromotionsResponse, GetDropshipperReceivableResponse, GetDropshipperShippingOptionsBody, GetDropshipperShippingOptionsResponse, GetFinancialAnalysisResponse, GetGeoCitiesResponse, GetGeoCountriesResponse, GetGeoProvincesResponse, GetMyProfileResponse, GetNotificationPreferencesResponse, GetNotificationsOptions, GetNotificationsResponse, GetOrderNotesResponse, GetOrdersCallback, GetOrdersOptions, GetProductAttributesResponse, GetProductsOptions, GetProviderCategoriesResponse, GetSettlementDetailResponse, GetSettlementsOptions, GetSettlementsResponse, GetStorefrontDropshipperCategoriesResponse, GetUserChannelResponse, GiftCardValidationResult, HeaderLinkItem, HeaderNavigationConfig, IconConfig, Image, InterestCategory, InventoryLevel, LinkCustomerToChannelResponse, LoginCredentials, ManualAdminNotificationData, ModulesConfig, Money, NavigationCalloutItem, NavigationItem, NavigationLinkItem, NotificationData, OnboardDropshipperBody, OnboardDropshipperResponse, Order, OrderDeliveryGroup, OrderItem, OrderNote, OrderPayment, OrderPaymentStatus, OrderReceipt, OrderStatus, OrdersMetrics, PaginationOptions, PasswordResetConfirm, PasswordResetRequest, PaymentMethod$1 as PaymentMethod, PaymentMethodFeatures, PaymentMethodType, PaymentMethodsOptions, PaymentStatus, PreviewDropshipperOrderItem, PreviewDropshipperOrderTotalsBody, PreviewDropshipperOrderTotalsResponse, PriceRange, PriceUpdatedNotificationData, Product, ProductAssignedNotificationData, ProductCategory, ProductOption, ProductPreview, ProductVariant, ProductsMetrics, PromotionRule, ProviderCategory, ProviderConfig, ProviderTypeString, QueryEntitiesInput, QueryEntityInput, QueryErrors, QueryMeta, QueryResponse, QuerySortDirection, RawNotification, RecoveryConfirmResult, Region, RegisterData, RegisterPaymentBody, RegisterPaymentResponse, RequestedProfile, ResolveGuaranteeBody, ResolveGuaranteeResponse, RestoreSiteConfigResponse, Review, SEO, SalesChannelType, SalesMetrics, SearchBarConfig, SearchResultMeta, SelectedOption, SetPaymentCollectorBody, SetPaymentCollectorResponse, SetPaymentMethodBody, SetPaymentMethodResponse, SettlementRecord, SettlementStatus, ShippingGroup, ShippingGroupInput, ShippingGroupItem, ShippingGroupLocation, ShippingGroupOption, ShippingGroupQuote, ShippingGroupSelection, ShippingMethod, ShopperIdentity, SiteConfig, SiteConfigLabels, SiteConfigMetadata, SocialConfig, SortOption, SortOptions, StockChangeNotificationData, StockLocation, StockStatus, StockValidation, StoreContext, StoreCreditAccountSummary, StorefrontConfig, StorefrontContext, StorefrontPlatformType, StorefrontSeoDefaults, SubmitApplicationBody, SubmitApplicationConflictApplication, SubmitApplicationCreated, SubmitApplicationResponse, SubmitApplicationResult, SubmitApplicationSalesChannel, TokenVerifyResult, TokenVerifyState, UnassignCategoriesFromChannelsBody, UnassignCategoriesFromChannelsResponse, UnassignCollectionsFromChannelsBody, UnassignCollectionsFromChannelsResponse, UpdateBusinessPolicyBody, UpdateBusinessPolicyResponse, UpdateCustomerData, UpdateDropshipperCategoryBody, UpdateDropshipperCustomerBody, UpdateDropshipperCustomerResponse, UpdateDropshipperDraftOrderBody, UpdateDropshipperDraftOrderResponse, UpdateDropshipperPricesBody, UpdateDropshipperPricesResponse, UpdateDropshipperProductStatusBody, UpdateDropshipperProductStatusResponse, UpdateDropshipperPromotionBody, UpdateNotificationPreferencesBody, UpdateSettlementStatusResponse, UpdateSiteConfigBody, UpdateSiteConfigResponse, UpdateStorefrontConfigBody, UpdateStorefrontConfigResponse, ValidateCheckoutItemsRequest, ValidateCheckoutItemsResponse, ValidateGiftCardBody, ValidateGiftCardResponse, ValidatedCheckoutItem };
8031
+ export type { AccountDropdownConfig, AccountMenuItem, AcknowledgeCostPriceChangesResponse, ActiveFilter, AddOrderEditItemBody, AddOrderEditItemResponse, Address, AdminApiKey, AdminChannelCategory, AdminChannelCustomer, AdminDropshipperAccount, AdminDropshipperBalance, AdminProduct, AdminProductVariant, AdminSalesChannelRef, AdminSiteConfig, AdminSiteConfigHistoryEntry, AdminSiteConfigHistoryEntryFull, AdminStorefrontConfig, AdminStorefrontSeoDefaults, AdminUser, AdvancedSearchProductsOptions, AssignCategoriesToChannelsBody, AssignCategoriesToChannelsResponse, AssignCollectionsToChannelsBody, AssignCollectionsToChannelsResponse, AuditLog, AuditLogAdapter, AuthConfig, AuthMethod, AuthProvider, AuthResponse, AuthStorage, AuthorConfig, BackendCapabilities, BrandConfig, CachedPaymentMethods, CancelDropshipperOrderResponse, CancelMovementBody, CancelMovementResponse, CancelSettlementBody, Cart, CartCost, CartItem, CartLineInput, CartLineUpdate, CartProduct, CartSession, CatalogAppliedFilters, CatalogFacetDemonstrationSource, CatalogFacetId, CatalogQuery, CatalogQueryFailure, CatalogQueryFailureCode, CatalogQueryFailureRepair, CatalogQueryOutcome, CatalogResults, CatalogSortKey, CategoryMapping, ChartDataPoint, ChatAssistantHealthResponse, ChatIntent, ChatMessage, ChatRequest, ChatResponse, ChatSource, ChatSourceVariant, CheckoutAddressLevel, CheckoutAddressOption, CheckoutAddressValues, CheckoutAdjustmentPayment, CheckoutCapturePolicy, CheckoutContactValues, CheckoutCustomerIdentity, CheckoutGuestContact, CheckoutInterruption, CheckoutInterruptionAction, CheckoutInterruptionKind, CheckoutLineProjection, CheckoutLineProjectionLine, CheckoutLocationOptions, CheckoutPaymentPlanItem, CheckoutPaymentSummary, CheckoutPaymentSummaryPayment, CheckoutPaymentSummaryStatus, CheckoutReadState, CheckoutSavedAddress, CheckoutShippingGroup, CheckoutShippingGroupItem, CheckoutShippingOption, CheckoutSubmission, Collection, CollectionProductsOptions, CommerceProvider, CompareProduct, ConfigHistoryEntry, ConfirmMovementBody, ConfirmMovementResponse, ConfirmOrderEditResponse, ConfirmSettlementBody, Connection, ConvertDropshipperDraftOrderBody, ConvertDropshipperDraftOrderResponse, CostPriceChangeItem, CostPriceChangesCheckResponse, CostPriceChangesResponse, Country, CreateAddressData, CreateAjusteBody, CreateAjusteResponse, CreateCategoryMappingBody, CreateCategoryMappingResponse, CreateCobroBody, CreateCobroResponse, CreateCompensacionBody, CreateCompensacionResponse, CreateDropshipperCategoryBody, CreateDropshipperCustomerBody, CreateDropshipperCustomerResponse, CreateDropshipperDraftOrderBody, CreateDropshipperDraftOrderResponse, CreateDropshipperOrderBody, CreateDropshipperOrderResponse, CreateDropshipperPromotionBody, CreateOrderEditBody, CreateOrderEditResponse, CreateOrderItem, CreateOrderNoteBody, CreateOrderNoteResponse, CreatePagoBody, CreatePagoResponse, CreateReversoBody, CreateReversoResponse, CreateSettlementBody, CreateSettlementResponse, Customer, CustomerOrderAction, CustomerOrderDetail, CustomerOrderDetailAction, CustomerOrderDetailAdjustment, CustomerOrderDetailAdjustmentDirection, CustomerOrderDetailAdjustmentScope, CustomerOrderDetailAdjustmentSource, CustomerOrderDetailAllocation, CustomerOrderDetailApprovalStatus, CustomerOrderDetailAttachment, CustomerOrderDetailAttribute, CustomerOrderDetailAttributeKind, CustomerOrderDetailBusiness, CustomerOrderDetailCase, CustomerOrderDetailCaseLine, CustomerOrderDetailCaseStatus, CustomerOrderDetailCaseType, CustomerOrderDetailDocument, CustomerOrderDetailDocumentKind, CustomerOrderDetailFulfillment, CustomerOrderDetailFulfillmentItemStatus, CustomerOrderDetailFulfillmentStatus, CustomerOrderDetailGroup, CustomerOrderDetailInvoiceStatus, CustomerOrderDetailIssue, CustomerOrderDetailLine, CustomerOrderDetailLinePrice, CustomerOrderDetailOrder, CustomerOrderDetailPackage, CustomerOrderDetailPaymentStatus, CustomerOrderDetailPickup, CustomerOrderDetailPickupStatus, CustomerOrderDetailPriceKind, CustomerOrderDetailProductKind, CustomerOrderDetailPromotion, CustomerOrderDetailPromotionApplication, CustomerOrderDetailPromotionNominal, CustomerOrderDetailPromotionScope, CustomerOrderDetailRevision, CustomerOrderDetailRevisionKind, CustomerOrderDetailSection, CustomerOrderDetailShippingMethod, CustomerOrderDetailSnapshot, CustomerOrderDetailTaxLine, CustomerOrderDetailTotals, CustomerOrderDetailTransaction, CustomerOrderDetailTransactionKind, CustomerOrderDetailTransactionMethod, CustomerOrderDetailTransactionStatus, CustomerOrderFulfillmentItemStatus, CustomerOrderFulfillmentStatus, CustomerOrderHistoryCommercialFilter, CustomerOrderHistoryCommercialStatus, CustomerOrderHistoryDatePreset, CustomerOrderHistoryDeliveryMode, CustomerOrderHistoryFilters, CustomerOrderHistoryFulfilmentFilter, CustomerOrderHistoryOptions, CustomerOrderHistoryPage, CustomerOrderHistoryPaymentFilter, CustomerOrderHistoryQuery, CustomerOrderHistoryQuick, CustomerOrderHistoryRecord, CustomerOrderHistoryRefundFilter, CustomerOrderHistoryReturnStatus, CustomerOrderHistoryShipment, CustomerOrderHistorySort, CustomerOrderPaymentStatus, CustomerOrdersPage, DashboardChanges, DashboardConfig, DashboardMetrics, DashboardMetricsAdapter, DashboardOrdersAdapter, DashboardPeriodMetrics, DashboardProductsAdapter, DashboardStats, DashboardTopProduct, DeleteCategoryMappingResponse, DeleteDropshipperCategoryResponse, DeleteDropshipperDraftOrderResponse, DeleteDropshipperPromotionResponse, DeleteOrderNoteResponse, DesignerConfig, DesignerHistoryEntry, DesignerNavItem, DesignerThemeConfig, DesignerThemePreset, DiscountCode, DropshipperAccount, DropshipperAccountRef, DropshipperAddressBody, DropshipperAddressResponse, DropshipperAttributeDefinition, DropshipperAttributeDefinitionValue, DropshipperBalance, DropshipperCategory, DropshipperCostTier, DropshipperCustomer, DropshipperCustomerAddress, DropshipperCustomerDetail, DropshipperCustomerFinancial, DropshipperCustomerStats, DropshipperDashboardCapabilities, DropshipperDraftOrder, DropshipperDraftOrderItem, DropshipperNotificationEventType, DropshipperNotificationPreference, DropshipperOrder, DropshipperOrderCustomer, DropshipperOrderDetail, DropshipperOrderItem, DropshipperOrderShippingAddress, DropshipperOrderTaxLine, DropshipperOrderTimelineEvent, DropshipperOrderTotals, DropshipperPayableOrder, DropshipperPaymentMethodConfig, DropshipperPendingOrders, DropshipperPriceItem, DropshipperPriceTier, DropshipperProduct, DropshipperProductAttachment, DropshipperProductAttribute, DropshipperProductAttributeValue, DropshipperProductImage, DropshipperProductOption, DropshipperProductOptionValue, DropshipperProductPrivateMedia, DropshipperProfile, DropshipperPromotion, DropshipperReceivableOrder, DropshipperSaleTier, DropshipperShippingGroup, DropshipperShippingGroupOption, DropshipperShippingOption, DropshipperVariant, DynamicSource, Edge, ExtendedCreateDropshipperOrderBody, ExtendedCreateDropshipperOrderResponse, FacetSupport, FilterConfig, FilterOption, FilterSection, FulfillmentOption, FulfillmentSet, FulfillmentStatus, GeoCity, GeoCountry, GeoProvince, GetAdminAccountBalanceResponse, GetAdminDropshipperAccountOrdersResponse, GetAdminDropshipperAccountSettlementsOptions, GetAdminDropshipperAccountSettlementsResponse, GetAdminDropshipperAccountsResponse, GetAdminPriceListsResponse, GetAdminSiteConfigHistoryOptions, GetAdminSiteConfigHistoryResponse, GetAdminSiteConfigResponse, GetAdminStorefrontConfigResponse, GetBusinessPolicyResponse, GetCategoriesCallback, GetCategoriesOptions, GetCategoryMappingsOptions, GetCategoryMappingsResponse, GetCategorySalesChannelsResponse, GetChannelApiKeysResponse, GetChannelCategoriesOptions, GetChannelCategoriesResponse, GetChannelCustomersOptions, GetChannelCustomersResponse, GetCollectionSalesChannelsResponse, GetCollectionsOptions, GetCustomerOrdersPageOptions, GetCustomersCallback, GetCustomersOptions, GetDashboardStatsOptions, GetDashboardStatsResponse, GetDropshipperAccountBalanceResponse, GetDropshipperAccountOrdersOptions, GetDropshipperAccountOrdersResponse, GetDropshipperAccountResponse, GetDropshipperAddressesResponse, GetDropshipperAttributesResponse, GetDropshipperCategoriesOptions, GetDropshipperCategoriesResponse, GetDropshipperCustomerDetailResponse, GetDropshipperCustomersOptions, GetDropshipperCustomersResponse, GetDropshipperDraftOrderDetailResponse, GetDropshipperDraftOrdersOptions, GetDropshipperDraftOrdersResponse, GetDropshipperOrderDetailResponse, GetDropshipperOrdersOptions, GetDropshipperOrdersResponse, GetDropshipperPayableResponse, GetDropshipperProductsOptions, GetDropshipperProductsResponse, GetDropshipperPromotionsOptions, GetDropshipperPromotionsResponse, GetDropshipperReceivableResponse, GetDropshipperShippingOptionsBody, GetDropshipperShippingOptionsResponse, GetFinancialAnalysisResponse, GetGeoCitiesResponse, GetGeoCountriesResponse, GetGeoProvincesResponse, GetMyProfileResponse, GetNotificationPreferencesResponse, GetNotificationsOptions, GetNotificationsResponse, GetOrderNotesResponse, GetOrdersCallback, GetOrdersOptions, GetProductAttributesResponse, GetProductsOptions, GetProviderCategoriesResponse, GetSettlementDetailResponse, GetSettlementsOptions, GetSettlementsResponse, GetStorefrontDropshipperCategoriesResponse, GetUserChannelResponse, GiftCardValidationResult, GuestContact, HeaderLinkItem, HeaderNavigationConfig, IconConfig, Image, InterestCategory, InventoryLevel, LinkCustomerToChannelResponse, LoginCredentials, ManualAdminNotificationData, ModulesConfig, Money, NavigationCalloutItem, NavigationItem, NavigationLinkItem, NotificationData, OnboardDropshipperBody, OnboardDropshipperResponse, Order, OrderDeliveryGroup, OrderItem, OrderNote, OrderPayment, OrderPaymentStatus, OrderReceipt, OrderStatus, OrdersMetrics, PaginationOptions, PasswordResetConfirm, PasswordResetRequest, PaymentMethod$1 as PaymentMethod, PaymentMethodFeatures, PaymentMethodType, PaymentMethodsOptions, PaymentStatus, PreviewDropshipperOrderItem, PreviewDropshipperOrderTotalsBody, PreviewDropshipperOrderTotalsResponse, PriceRange, PriceTier, PriceUpdatedNotificationData, Product, ProductAssignedNotificationData, ProductCategory, ProductOption, ProductPreview, ProductVariant, ProductsMetrics, PromotionKind, PromotionRule, PromotionScope, PromotionSummary, ProviderCategory, ProviderConfig, ProviderTypeString, QueryEntitiesInput, QueryEntityInput, QueryErrors, QueryMeta, QueryResponse, QuerySortDirection, RawNotification, RecoveryConfirmResult, Region, RegisterData, RegisterPaymentBody, RegisterPaymentResponse, RequestedProfile, ResolveGuaranteeBody, ResolveGuaranteeResponse, RestoreSiteConfigResponse, Review, SEO, SalesChannelType, SalesMetrics, SearchBarConfig, SearchResultMeta, SelectedOption, SetPaymentCollectorBody, SetPaymentCollectorResponse, SetPaymentMethodBody, SetPaymentMethodResponse, SettlementRecord, SettlementStatus, ShippingGroup, ShippingGroupInput, ShippingGroupItem, ShippingGroupLocation, ShippingGroupOption, ShippingGroupQuote, ShippingGroupSelection, ShippingMethod, ShopperIdentity, SiteConfig, SiteConfigLabels, SiteConfigMetadata, SocialConfig, SortOption, SortOptions, StockChangeNotificationData, StockLocation, StockStatus, StockValidation, StoreContext, StoreCreditAccountSummary, StorefrontConfig, StorefrontContext, StorefrontPlatformType, StorefrontSeoDefaults, SubmitApplicationBody, SubmitApplicationConflictApplication, SubmitApplicationCreated, SubmitApplicationResponse, SubmitApplicationResult, SubmitApplicationSalesChannel, TokenVerifyResult, TokenVerifyState, UnassignCategoriesFromChannelsBody, UnassignCategoriesFromChannelsResponse, UnassignCollectionsFromChannelsBody, UnassignCollectionsFromChannelsResponse, UpdateBusinessPolicyBody, UpdateBusinessPolicyResponse, UpdateCustomerData, UpdateDropshipperCategoryBody, UpdateDropshipperCustomerBody, UpdateDropshipperCustomerResponse, UpdateDropshipperDraftOrderBody, UpdateDropshipperDraftOrderResponse, UpdateDropshipperPricesBody, UpdateDropshipperPricesResponse, UpdateDropshipperProductStatusBody, UpdateDropshipperProductStatusResponse, UpdateDropshipperPromotionBody, UpdateNotificationPreferencesBody, UpdateSettlementStatusResponse, UpdateSiteConfigBody, UpdateSiteConfigResponse, UpdateStorefrontConfigBody, UpdateStorefrontConfigResponse, ValidateCheckoutItemsRequest, ValidateCheckoutItemsResponse, ValidateGiftCardBody, ValidateGiftCardResponse, ValidatedCheckoutItem };