@thorprovider/types 5.7.10 → 6.0.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.mts CHANGED
@@ -83,6 +83,80 @@ interface Country {
83
83
  numCode?: string;
84
84
  }
85
85
 
86
+ /**
87
+ * @thorprovider/types — Commerce contracts (type-only)
88
+ *
89
+ * Single-tenant, guest-only commerce shapes owned once by this module.
90
+ * Validation lives in `@thorprovider/runtime/contracts` (pure Zod); this
91
+ * module exports types only and emits no runtime values.
92
+ *
93
+ * Canonical product/variant/Money/cart/order shapes are NOT redefined here —
94
+ * they stay owned by `./common`, `./product`, `./cart` and `./order`.
95
+ *
96
+ * @module commerce
97
+ */
98
+
99
+ /**
100
+ * The validated single-store context — the multitenancy seam.
101
+ *
102
+ * Declares store identity, sales channel, region, and currency once and is
103
+ * validated at the boundary before any commerce call. Multitenancy is
104
+ * post-MVP; a future tenancy layer varies these values without redefining
105
+ * the commerce shapes.
106
+ */
107
+ interface StoreContext {
108
+ /** Stable store identity. */
109
+ storeId: string;
110
+ /** Sales channel the store is scoped to (Medusa `sales_channel_id`). */
111
+ salesChannelId: string;
112
+ /** Backend region that supplies currency, countries and shipping. */
113
+ regionId: string;
114
+ /** ISO 4217 currency code from the validated context — never hardcoded. */
115
+ currencyCode: string;
116
+ }
117
+ /**
118
+ * Issued guest shopper identity, scoped to a store.
119
+ *
120
+ * Backed by a cookie the Next host owns; it maps to a persisted backend guest
121
+ * cart so a reload reattaches to the same cart and two shoppers stay isolated.
122
+ */
123
+ interface ShopperIdentity {
124
+ /** Opaque shopper identity issued by the host cookie. */
125
+ shopperId: string;
126
+ /** Store the identity is scoped to. */
127
+ storeId: string;
128
+ }
129
+ /**
130
+ * A persisted backend guest cart session bound to a shopper identity.
131
+ */
132
+ interface CartSession {
133
+ /** Backend cart identifier. */
134
+ cartId: string;
135
+ /** Owning shopper identity. */
136
+ shopperId: string;
137
+ /** Store the session is scoped to. */
138
+ storeId: string;
139
+ }
140
+ /**
141
+ * Safe, buyer/store-authorized order receipt projection.
142
+ *
143
+ * A minimal recoverable subset of the canonical `Order` (`./order`), used by
144
+ * the guest receipt protocol. Access is authorized for the buyer or the
145
+ * store; it is never granted by possession of a bare public order id.
146
+ */
147
+ interface OrderReceipt {
148
+ /** Backend order identifier. */
149
+ orderId: string;
150
+ /** Human-readable order number. */
151
+ orderNumber: string;
152
+ /** Buyer email the order was placed with. */
153
+ email: string;
154
+ /** Order total in major units. */
155
+ total: Money;
156
+ /** ISO 8601 creation timestamp. */
157
+ createdAt: string;
158
+ }
159
+
86
160
  /**
87
161
  * Header Configuration Types
88
162
  *
@@ -663,6 +737,12 @@ interface Product {
663
737
  title: string;
664
738
  handle: string;
665
739
  }>;
740
+ categories?: Array<{
741
+ id: string;
742
+ name: string;
743
+ handle: string;
744
+ parentCategoryId?: string;
745
+ }>;
666
746
  productType?: string;
667
747
  vendor?: string;
668
748
  tags?: string[];
@@ -903,6 +983,201 @@ interface FilterConfig {
903
983
  ranking?: number;
904
984
  }
905
985
 
986
+ /**
987
+ * @thorprovider/types — Canonical catalog query, truthful results, and facet support.
988
+ *
989
+ * Type-only module: no runtime code, constants, or schemas. These types are shared by
990
+ * the URL boundary, the runtime commerce bridge, and the adapters so every product
991
+ * listing asks the backend one well-formed question and reports truthfully what was
992
+ * applied. Validation (Zod) lives in `@thorprovider/runtime/contracts`; translation to
993
+ * backend parameters lives in the adapters.
994
+ *
995
+ * E2 `storefront-catalog-search-filters`. The canonical URL parameter contract is:
996
+ * `q` (text), the route category scope plus `categories`/`collections`, `sort`
997
+ * (`featured` | `name` | `newest`), `page`/`pageSize`, and the optional requested
998
+ * facets `priceMin`/`priceMax`/`inStock`/`attr.<name>`.
999
+ */
1000
+
1001
+ /**
1002
+ * Canonical, backend-verified sort keys.
1003
+ *
1004
+ * Only these three are verified against Medusa v2: `featured` (server default),
1005
+ * `name` (translated to `title`), and `newest` (translated to `-created_at`). Global
1006
+ * price ordering and rating are not verified and are rejected by the boundary as a
1007
+ * typed unsupported-query error. An adapter advertises the subset it can actually
1008
+ * apply; the listing never offers a sort the backend cannot perform.
1009
+ */
1010
+ type CatalogSortKey = 'featured' | 'name' | 'newest';
1011
+ /**
1012
+ * Canonical catalog query crossing the URL boundary, the runtime bridge, and the
1013
+ * adapters.
1014
+ *
1015
+ * Fields mirror the fixed, lowercase URL namespace. They are optional because
1016
+ * documented defaults (`sort` = `featured`, `page` = `1`, `pageSize` = the chosen
1017
+ * target default) are resolved by the URL boundary and apply only to absent
1018
+ * parameters, never to invalid present values.
1019
+ */
1020
+ interface CatalogQuery {
1021
+ /** Free-text term (`q`). Trimmed, bounded, and empty treated as absent. */
1022
+ text?: string;
1023
+ /**
1024
+ * Category scope supplied by the route path (`/categories/[[...slug]]`). The route
1025
+ * scope is always retained, even when both optional features are removed.
1026
+ */
1027
+ categoryScope?: string;
1028
+ /**
1029
+ * Category handles requested by the `category-filters` feature. The effective
1030
+ * scope is `categoryScope ∩ categories`; an empty intersection is a valid
1031
+ * zero-result query, never an invalid-query error.
1032
+ */
1033
+ categories?: string[];
1034
+ /** Collection handles requested by the `category-filters` feature. */
1035
+ collections?: string[];
1036
+ /** Canonical sort key; defaults are resolved at the URL boundary, not here. */
1037
+ sort?: CatalogSortKey;
1038
+ /** 1-based page; bounds are enforced at the URL boundary. */
1039
+ page?: number;
1040
+ /** Page size; bounds are enforced at the URL boundary. */
1041
+ pageSize?: number;
1042
+ /** Minimum price in major units; honored only when the price facet is demonstrated. */
1043
+ priceMin?: number;
1044
+ /** Maximum price in major units; honored only when the price facet is demonstrated. */
1045
+ priceMax?: number;
1046
+ /** In-stock only; honored only when demonstrated, otherwise a typed unsupported error. */
1047
+ inStock?: boolean;
1048
+ /** Requested attribute filters keyed by attribute name (`attr.<name>`). */
1049
+ attributes?: Record<string, string[]>;
1050
+ }
1051
+ /**
1052
+ * Filters the backend actually applied to a successful result.
1053
+ *
1054
+ * A result is reported as success only when every requested filter appears here.
1055
+ */
1056
+ interface CatalogAppliedFilters {
1057
+ /** Text term applied within the current scope. */
1058
+ text?: string;
1059
+ /** Category handles applied (the effective intersected scope). */
1060
+ categories?: string[];
1061
+ /** Collection handles applied. */
1062
+ collections?: string[];
1063
+ /** Minimum price applied. */
1064
+ priceMin?: number;
1065
+ /** Maximum price applied. */
1066
+ priceMax?: number;
1067
+ /** In-stock constraint applied. */
1068
+ inStock?: boolean;
1069
+ /** Attribute filters applied, keyed by attribute name. */
1070
+ attributes?: Record<string, string[]>;
1071
+ }
1072
+ /**
1073
+ * Canonical filter identifiers used by the support descriptor.
1074
+ *
1075
+ * `attr.<name>` covers backend-advertised filterable attributes.
1076
+ */
1077
+ type CatalogFacetId = 'categories' | 'collections' | 'price' | 'inStock' | `attr.${string}`;
1078
+ /**
1079
+ * Real-endpoint demonstration source for an offered facet.
1080
+ *
1081
+ * Records the actual backend endpoint demonstrated with the applied query for the
1082
+ * current scope, not a capability flag or returned facet metadata.
1083
+ */
1084
+ interface CatalogFacetDemonstrationSource {
1085
+ /** Real backend endpoint demonstrated with the applied query (e.g. `/store/products`). */
1086
+ endpoint: string;
1087
+ /** The query and scope the endpoint was demonstrated with. */
1088
+ appliedQuery?: CatalogQuery;
1089
+ /** Store/scope the demonstration applies to. */
1090
+ scope?: string;
1091
+ /** ISO-8601 timestamp of when support was demonstrated. */
1092
+ demonstratedAt?: string;
1093
+ }
1094
+ /**
1095
+ * Truthful facet support descriptor: which filters the backend has demonstrated
1096
+ * (offered) versus which are undemonstrated and held, plus the demonstration source
1097
+ * for each offered filter.
1098
+ *
1099
+ * Contains no counts or ranges. Facet option counts and numeric ranges come only from
1100
+ * backend data returned for the current query and are never synthesized here.
1101
+ */
1102
+ interface FacetSupport {
1103
+ /** Filters demonstrated against the real endpoint for the current scope. */
1104
+ offered: CatalogFacetId[];
1105
+ /** Filters not demonstrated; held and diagnosed, never silently offered. */
1106
+ held: CatalogFacetId[];
1107
+ /** Real-endpoint demonstration source per offered filter, keyed by filter id. */
1108
+ demonstrations?: Record<string, CatalogFacetDemonstrationSource>;
1109
+ /** Diagnostic reason per held filter, keyed by filter id. */
1110
+ heldReasons?: Record<string, string>;
1111
+ }
1112
+ /**
1113
+ * Truthful catalog result for a fully applied query.
1114
+ *
1115
+ * When any requested filter cannot be applied, the query MUST return a typed
1116
+ * unsupported-query error (defined in `@thorprovider/runtime/contracts`) instead of
1117
+ * this shape; a partial result is never labelled success. `total` is present only
1118
+ * when the backend supplies it and is never manufactured.
1119
+ */
1120
+ interface CatalogResults {
1121
+ /** Matching products for the requested scope, sort, and page. */
1122
+ products: Product[];
1123
+ /** Total matches supplied by the backend; absent when the backend returns none. */
1124
+ total?: number;
1125
+ /** Filters the backend actually applied. */
1126
+ appliedFilters: CatalogAppliedFilters;
1127
+ /** Facet support descriptor for the query and scope. */
1128
+ facetSupport?: FacetSupport;
1129
+ }
1130
+ /**
1131
+ * Adapter-seam typed failure code for a canonical catalog query.
1132
+ *
1133
+ * `unsupported-query` is the code an adapter returns when a requested filter
1134
+ * cannot be applied to the backend. `invalid-query` and `unmounted-capability`
1135
+ * are produced by the URL boundary (`@thorprovider/runtime/contracts`); the
1136
+ * adapter seam mirrors them so the runtime bridge can surface either shape
1137
+ * without a translation layer.
1138
+ */
1139
+ type CatalogQueryFailureCode = 'invalid-query' | 'unsupported-query' | 'unmounted-capability';
1140
+ /**
1141
+ * Compact, structured repair metadata: the raw parameter names a host must drop
1142
+ * to reach a valid query. Structurally identical to the URL boundary's repair.
1143
+ */
1144
+ interface CatalogQueryFailureRepair {
1145
+ /** Raw URL parameter names to remove (exactly the offending fields). */
1146
+ remove: string[];
1147
+ }
1148
+ /**
1149
+ * Typed catalog-query failure returned across the adapter seam.
1150
+ *
1151
+ * Structurally identical to `CatalogQueryError` in
1152
+ * `@thorprovider/runtime/contracts`, so the two are mutually assignable and the
1153
+ * runtime bridge can pass one through as the other. `fields` names the
1154
+ * offending raw parameters; `feature` is present only for
1155
+ * `unmounted-capability`.
1156
+ */
1157
+ interface CatalogQueryFailure {
1158
+ code: CatalogQueryFailureCode;
1159
+ fields: string[];
1160
+ message: string;
1161
+ repair: CatalogQueryFailureRepair;
1162
+ feature?: 'catalog-search' | 'category-filters';
1163
+ }
1164
+ /**
1165
+ * Discriminated outcome of a canonical catalog query against a provider.
1166
+ *
1167
+ * A provider returns `{ ok: true, results }` **only** when every requested
1168
+ * filter was applied. When any requested filter cannot be applied it returns
1169
+ * `{ ok: false, error }` with `code: 'unsupported-query'` naming the
1170
+ * unappliable fields; a partial result is never returned as success and a
1171
+ * requested filter is never silently dropped.
1172
+ */
1173
+ type CatalogQueryOutcome = {
1174
+ ok: true;
1175
+ results: CatalogResults;
1176
+ } | {
1177
+ ok: false;
1178
+ error: CatalogQueryFailure;
1179
+ };
1180
+
906
1181
  /**
907
1182
  * @thorprovider/adapters v2.0
908
1183
  * Cart types - unified interface for all commerce providers
@@ -926,6 +1201,13 @@ interface CartItem {
926
1201
  stockStatus?: StockStatus;
927
1202
  cost: {
928
1203
  totalAmount: Money;
1204
+ /**
1205
+ * Backend unit price for a single quantity, when the backend supplies it.
1206
+ *
1207
+ * Carried so the display never derives a unit price locally; absent when
1208
+ * the backend did not return one.
1209
+ */
1210
+ unitPrice?: Money;
929
1211
  };
930
1212
  merchandise: {
931
1213
  id: string;
@@ -936,11 +1218,20 @@ interface CartItem {
936
1218
  }
937
1219
  /**
938
1220
  * Cart cost breakdown
1221
+ *
1222
+ * Every amount is backend-authoritative: the adapter carries the backend's
1223
+ * value through unchanged (including a legitimate `"0"`) and never derives a
1224
+ * total locally. An optional amount is absent only when the backend did not
1225
+ * supply it.
939
1226
  */
940
1227
  interface CartCost {
941
1228
  subtotalAmount: Money;
942
1229
  totalAmount: Money;
943
1230
  totalTaxAmount?: Money;
1231
+ /** Backend discount total, when supplied. */
1232
+ discountAmount?: Money;
1233
+ /** Backend shipping total, when supplied. */
1234
+ shippingAmount?: Money;
944
1235
  }
945
1236
  /**
946
1237
  * Shipping method option
@@ -975,6 +1266,30 @@ interface Cart {
975
1266
  stockValidation?: StockValidation;
976
1267
  /** ISO timestamp when cart was completed/converted to order (undefined if active) */
977
1268
  completedAt?: string;
1269
+ /**
1270
+ * Backend sales channel the cart is scoped to.
1271
+ *
1272
+ * Carried so the runtime can enforce that a cart belongs to the validated
1273
+ * single-store context before it is mutated; absent when a provider does not
1274
+ * expose it.
1275
+ */
1276
+ salesChannelId?: string;
1277
+ /** Backend region the cart is scoped to (context enforcement). */
1278
+ regionId?: string;
1279
+ /** Backend currency code, uppercased (context enforcement). */
1280
+ currencyCode?: string;
1281
+ /** Backend id of the applied shipping method, when one is selected. */
1282
+ selectedShippingMethodId?: string;
1283
+ /**
1284
+ * Backend id of the shipping option the applied method was created from.
1285
+ *
1286
+ * This is the identity the checkout shipping UI selects (the value passed to
1287
+ * `addShippingMethod`), which is distinct from `selectedShippingMethodId`
1288
+ * (the applied shipping-method record id). Absent when no method is applied.
1289
+ */
1290
+ selectedShippingOptionId?: string;
1291
+ /** Platform-specific backend metadata, carried through unchanged. */
1292
+ metadata?: Record<string, unknown>;
978
1293
  }
979
1294
  /**
980
1295
  * Input for adding items to cart
@@ -1041,6 +1356,16 @@ interface GetCollectionsOptions {
1041
1356
  limit?: number;
1042
1357
  /** Search query to filter collections by title */
1043
1358
  query?: string;
1359
+ /**
1360
+ * Scope results to a specific sales channel / storefront channel.
1361
+ * When provided, only collections that contain at least one product available
1362
+ * in the given channel will be returned.
1363
+ *
1364
+ * Maps to: Medusa `sales_channel_id`, Shopify Sales Channel, etc.
1365
+ * Adapters that support native server-side filtering should prefer it;
1366
+ * others may fall back to a client-side post-filter pass.
1367
+ */
1368
+ salesChannelId?: string;
1044
1369
  }
1045
1370
  /**
1046
1371
  * Options for fetching collection products
@@ -1442,50 +1767,57 @@ interface GetOrdersOptions {
1442
1767
  */
1443
1768
  customFetcher?: GetOrdersCallback;
1444
1769
  }
1770
+ /**
1771
+ * Options for the additive paginated order-history contract.
1772
+ *
1773
+ * Unlike {@link GetOrdersOptions}, this carries an explicit 1-based `page` and
1774
+ * `pageSize` so a caller can request a bounded window of the authenticated
1775
+ * customer's channel-scoped history. `salesChannelId` is the store's configured
1776
+ * channel and is validated against the backend's channel scoping; a provider
1777
+ * MUST NOT fall back to a blind first channel id when it is absent.
1778
+ */
1779
+ interface GetCustomerOrdersPageOptions {
1780
+ /** 1-based page number (default 1). */
1781
+ page?: number;
1782
+ /** Rows per page (default 10, bounded by the provider's canonical limit). */
1783
+ pageSize?: number;
1784
+ /** The store's configured sales channel id (explicit; never a blind first id). */
1785
+ salesChannelId?: string;
1786
+ }
1787
+ /**
1788
+ * The additive paginated order-history result.
1789
+ *
1790
+ * `count` is the backend's real total for the authenticated customer and the
1791
+ * store's sales channel, computed after the server-side customer+channel filter
1792
+ * and before pagination — never a page length or a `limit`-floored estimate.
1793
+ * `limit`/`offset` echo the backend's applied window.
1794
+ */
1795
+ interface CustomerOrdersPage {
1796
+ orders: Order[];
1797
+ count: number;
1798
+ limit: number;
1799
+ offset: number;
1800
+ }
1445
1801
 
1446
1802
  /**
1447
- * @thorprovider/types — Supported Providers
1803
+ * @thorprovider/types — Supported Providers (type-only)
1448
1804
  *
1449
- * Centralized list of all supported commerce providers.
1450
- * This is the single source of truth for provider types across the monorepo.
1805
+ * Defines the provider-type union contract shared across the monorepo.
1451
1806
  *
1452
1807
  * @remarks
1453
- * - L1 (Foundation): Defines the contract
1454
- * - L2 (@thorprovider/adapters) imports from here to build the factory
1455
- * - L5 (Starters) uses the factory which is bound to this enum
1456
- *
1457
- * When adding a new provider (e.g., Stel Order):
1458
- * 1. Add to SupportedProviderType enum below
1459
- * 2. Update @thorprovider/adapters factory/index.ts with discriminated union
1460
- * 3. Create packages/adapters/src/providers/shopify/
1461
- * 4. Implement CommerceProvider interface
1462
- * 5. Update StorefrontPlatformType in storefront.ts
1463
- */
1464
- /**
1465
- * All supported commerce platform providers.
1466
- * `mock` is the backend-optional runtime provider used for layout/design mode.
1467
- * `medusa` is fully implemented for real backend usage; others are placeholders for future expansion.
1468
- *
1469
- * @remarks Implementation status:
1470
- * - ✅ mock: Fixture-backed provider for backend-optional storefronts
1471
- * - ✅ medusa: Fully implemented
1472
- * - 🟡 stelorder: In progress (ERP adapter v1)
1473
- * - 🟡 shopify: Planned (Phase 2)
1474
- * - 🟡 bigcommerce: Planned (Phase 2)
1475
- * - 🟡 woocommerce: Planned (Phase 3)
1476
- * - 🟡 spree: Planned (Phase 3)
1477
- * - 🟡 magento: Planned (Phase 3)
1478
- */
1479
- declare enum SupportedProviderType {
1480
- Mock = "mock",
1481
- Medusa = "medusa",
1482
- StelOrder = "stelorder",
1483
- Shopify = "shopify",
1484
- BigCommerce = "bigcommerce",
1485
- WooCommerce = "woocommerce",
1486
- Spree = "spree",
1487
- Magento = "magento"
1488
- }
1808
+ * - L1 (Foundation): owns the `ProviderTypeString` union type only.
1809
+ * - L2 (@thorprovider/adapters) owns the runtime provider registry
1810
+ * (`SupportedProviderType`, `PROVIDER_METADATA`, `isSupportedProviderType`,
1811
+ * `getProviderMetadata`) in `@thorprovider/adapters`.
1812
+ *
1813
+ * When adding a new provider:
1814
+ * 1. Add the string to `ProviderTypeString` below.
1815
+ * 2. Add it to `SupportedProviderType` + `PROVIDER_METADATA` in
1816
+ * packages/adapters/src/factory/provider-types.ts.
1817
+ * 3. Create packages/adapters/src/providers/[platform]/ and implement the
1818
+ * `CommerceProvider` interface.
1819
+ * 4. Update `StorefrontPlatformType` in storefront.ts.
1820
+ */
1489
1821
  /**
1490
1822
  * Union type of all supported provider string values.
1491
1823
  * Use this for type annotations when a provider type is expected.
@@ -1498,41 +1830,6 @@ declare enum SupportedProviderType {
1498
1830
  * ```
1499
1831
  */
1500
1832
  type ProviderTypeString = 'mock' | 'medusa' | 'stelorder' | 'shopify' | 'bigcommerce' | 'woocommerce' | 'spree' | 'magento';
1501
- /**
1502
- * Metadata about each provider.
1503
- * Useful for UI, error messages, validation, and documentation.
1504
- *
1505
- * @internal
1506
- */
1507
- declare const PROVIDER_METADATA: Record<ProviderTypeString, {
1508
- name: string;
1509
- description: string;
1510
- requiresStorefront: boolean;
1511
- requiredEnvVars: string[];
1512
- maxRetries: number;
1513
- }>;
1514
- /**
1515
- * Check if a string is a valid provider type.
1516
- *
1517
- * @example
1518
- * ```typescript
1519
- * if (isSupportedProviderType(process.env.COMMERCE_PROVIDER)) {
1520
- * // type is narrowed to ProviderTypeString
1521
- * }
1522
- * ```
1523
- */
1524
- declare function isSupportedProviderType(value: unknown): value is ProviderTypeString;
1525
- /**
1526
- * Get metadata for a provider type.
1527
- * Useful for validation, error messages, and logging.
1528
- *
1529
- * @example
1530
- * ```typescript
1531
- * const meta = getProviderMetadata('medusa');
1532
- * console.log(`Using ${meta.name} with max ${meta.maxRetries} retries`);
1533
- * ```
1534
- */
1535
- declare function getProviderMetadata(type: ProviderTypeString): (typeof PROVIDER_METADATA)[ProviderTypeString];
1536
1833
 
1537
1834
  /**
1538
1835
  * @thorprovider/types — Storefront Context
@@ -1550,9 +1847,11 @@ declare function getProviderMetadata(type: ProviderTypeString): (typeof PROVIDER
1550
1847
  * Supported commerce platform types for storefront identification.
1551
1848
  *
1552
1849
  * @remarks
1553
- * Keep this type in sync with SupportedProviderType from provider.ts.
1554
- * When adding a new provider, update both packages/types/src/provider.ts
1555
- * and this type.
1850
+ * Keep this type in sync with ProviderTypeString from provider.ts and the
1851
+ * runtime registry in @thorprovider/adapters
1852
+ * (packages/adapters/src/factory/provider-types.ts).
1853
+ * When adding a new provider, update packages/types/src/provider.ts, this
1854
+ * type, and the adapters registry.
1556
1855
  *
1557
1856
  * Currently supported:
1558
1857
  * - ✅ 'mock': Backend-optional layout/design mode using fixture data
@@ -1626,24 +1925,6 @@ interface StorefrontContext {
1626
1925
  */
1627
1926
  metadata?: Record<string, unknown>;
1628
1927
  }
1629
- /**
1630
- * Storefront validation error.
1631
- * Thrown when storefront configuration is invalid or missing.
1632
- *
1633
- * @example
1634
- * ```typescript
1635
- * throw new StorefrontConfigError(
1636
- * 'Medusa requires NEXT_PUBLIC_SALES_CHANNEL_ID',
1637
- * 'medusa',
1638
- * 'NEXT_PUBLIC_SALES_CHANNEL_ID',
1639
- * );
1640
- * ```
1641
- */
1642
- declare class StorefrontConfigError extends Error {
1643
- readonly platformType: string;
1644
- readonly requiredEnvVar?: string;
1645
- constructor(message: string, platformType: string, requiredEnvVar?: string);
1646
- }
1647
1928
 
1648
1929
  /**
1649
1930
  * @thorprovider/types — Storefront Configuration
@@ -2505,6 +2786,21 @@ interface CommerceProvider {
2505
2786
  * ```
2506
2787
  */
2507
2788
  readonly capabilities: BackendCapabilities;
2789
+ /**
2790
+ * Canonical catalog sort keys this provider can actually apply at the query
2791
+ * level (E2 `storefront-catalog-search-filters`, design Decision 6).
2792
+ *
2793
+ * Advertises only backend-verified orderings — for Medusa, `featured`
2794
+ * (server default), `name` (translated to `title`), and `newest` (translated
2795
+ * to `-created_at`). A global price or rating sort is never advertised. The
2796
+ * runtime query boundary consumes this set as `supportedSortKeys` and turns a
2797
+ * requested sort outside it into a typed unsupported-query error, so the
2798
+ * listing never offers an ordering the backend cannot perform.
2799
+ *
2800
+ * Optional and additive: when absent, no ordering beyond the canonical default
2801
+ * is assumed from the advertisement.
2802
+ */
2803
+ readonly supportedCatalogSortKeys?: readonly CatalogSortKey[];
2508
2804
  /**
2509
2805
  * Whether this provider is backed by fixture/mock data instead of a live backend.
2510
2806
  *
@@ -2534,6 +2830,24 @@ interface CommerceProvider {
2534
2830
  * for layout/design workflows until a real backend is configured.
2535
2831
  */
2536
2832
  getProducts(options?: GetProductsOptions): Promise<Product[]>;
2833
+ /**
2834
+ * Run a canonical, validated catalog query against the real listing endpoint
2835
+ * (OPTIONAL — E2 `storefront-catalog-search-filters`, task 2.2).
2836
+ *
2837
+ * The adapter translates the canonical `CatalogQuery` (text, the route
2838
+ * category scope plus `categories`/`collections`, sort, pagination, and
2839
+ * requested filters) into its backend's parameters and returns a truthful
2840
+ * `CatalogQueryOutcome`: `{ ok: true, results }` only when **every** requested
2841
+ * filter was applied, or `{ ok: false, error }` with `code:
2842
+ * 'unsupported-query'` naming the fields it cannot apply. It never returns a
2843
+ * partial result labelled success and never silently drops a requested filter.
2844
+ *
2845
+ * Optional and additive: providers that cannot forward a canonical query omit
2846
+ * it and callers fall back to `getProducts`/`getCategoryProducts`. The legacy
2847
+ * zero-argument and options-based methods keep their `Product[]` return and
2848
+ * are unchanged. This is the typed seam the runtime catalog bridge consumes.
2849
+ */
2850
+ getCatalogProducts?(query: CatalogQuery): Promise<CatalogQueryOutcome>;
2537
2851
  /**
2538
2852
  * Get product recommendations for a given product
2539
2853
  * @param productId - Product ID
@@ -3049,6 +3363,21 @@ interface CommerceProvider {
3049
3363
  * @returns Array of orders
3050
3364
  */
3051
3365
  getOrders?(options: GetOrdersOptions): Promise<Order[]>;
3366
+ /**
3367
+ * Get the authenticated customer's order history as a paginated window
3368
+ * (OPTIONAL, additive).
3369
+ *
3370
+ * Returns `{ orders, count, limit, offset }`, where `count` is the backend's
3371
+ * real total for the authenticated customer and the store's sales channel,
3372
+ * computed after the server-side customer+channel filter and before
3373
+ * pagination. The legacy array-returning `getOrders` stays unchanged for
3374
+ * existing callers.
3375
+ *
3376
+ * A provider that does not implement this method (for example the mock data
3377
+ * source) fails closed at the runtime boundary rather than pretending an
3378
+ * empty history.
3379
+ */
3380
+ customerOrdersPage?(options: GetCustomerOrdersPageOptions): Promise<CustomerOrdersPage>;
3052
3381
  /**
3053
3382
  * Get available payment methods
3054
3383
  *
@@ -4310,6 +4639,8 @@ interface ExtendedCreateDropshipperOrderResponse {
4310
4639
  discount_total: number;
4311
4640
  total: number;
4312
4641
  profit: number;
4642
+ /** Desglose de impuestos por tasa (ítems + envío). `total` es el importe. */
4643
+ tax_lines: DropshipperOrderTaxLine[];
4313
4644
  created_at: string;
4314
4645
  /** One shipping method per group (contract v2). Replaces `shipping_method`. */
4315
4646
  shipping_methods: DropshipperShippingMethod[];
@@ -4363,6 +4694,19 @@ interface DropshipperItemTaxLine {
4363
4694
  total: number;
4364
4695
  subtotal: number;
4365
4696
  }
4697
+ /**
4698
+ * Línea de impuesto del desglose de una orden (ítems + envío).
4699
+ *
4700
+ * `total` es el **importe del impuesto** (no la base imponible). No expone
4701
+ * `subtotal` porque en el contrato de order ese campo también es un importe de
4702
+ * impuesto (impuesto sobre la base pre-descuento), no la base.
4703
+ */
4704
+ interface DropshipperOrderTaxLine {
4705
+ code: string | null;
4706
+ rate: number;
4707
+ total: number;
4708
+ kind: 'item' | 'shipping';
4709
+ }
4366
4710
  interface DropshipperOrderItem {
4367
4711
  id: string;
4368
4712
  title: string;
@@ -4589,6 +4933,8 @@ interface DropshipperShippingMethod {
4589
4933
  original_total: number;
4590
4934
  total: number;
4591
4935
  tax_total: number;
4936
+ /** Tax lines del método de envío (importe por tasa). El backend ya las emite. */
4937
+ tax_lines?: DropshipperItemTaxLine[];
4592
4938
  discount_total: number;
4593
4939
  /** Discount adjustments applied to this shipping method (read-only; [] when none). */
4594
4940
  adjustments?: DropshipperItemAdjustment[];
@@ -4675,9 +5021,63 @@ interface DropshipperOrderFulfillment {
4675
5021
  provider_id: string | null;
4676
5022
  /** Name of the stock location the fulfillment ships from, when resolvable */
4677
5023
  location_name: string | null;
5024
+ /** Delivery type of the fulfillment (a group travels together in one fulfillment). */
5025
+ type: 'pickup' | 'shipping';
5026
+ /** Shipping option of origin, to resolve the method name against `order.shipping_methods`. */
5027
+ shipping_option_id: string | null;
5028
+ /** Pickup store (name + address) for a `pickup` fulfillment; `null` for shipping. */
5029
+ pickup_location: DropshipperPickupLocation | null;
4678
5030
  items: DropshipperFulfillmentItem[];
4679
5031
  labels: DropshipperFulfillmentLabel[];
4680
5032
  }
5033
+ /**
5034
+ * Estado de un grupo de entrega. `configured` = plan aplicado, aún no enviado
5035
+ * al almacén; `preparing` = enviado al almacén (FulfillmentDeliveryInfo) sin
5036
+ * fulfillment; el resto son estados del fulfillment vinculado.
5037
+ */
5038
+ type DropshipperDeliveryGroupStatus = 'configured' | 'preparing' | 'pending' | 'packed' | 'shipped' | 'delivered' | 'canceled';
5039
+ /**
5040
+ * Un grupo de entrega de la orden: un grupo configurado del plan de envío
5041
+ * (`metadata.shipping_plan.configured_groups`), con o sin fulfillment. Los
5042
+ * campos se resuelven progresivamente a medida que la orden avanza.
5043
+ */
5044
+ interface DropshipperDeliveryGroup {
5045
+ id: string;
5046
+ type: 'pickup' | 'shipping';
5047
+ origin: {
5048
+ id: string | null;
5049
+ name: string | null;
5050
+ /** Código corto del almacén (`metadata.code`), si existe. */
5051
+ code: string | null;
5052
+ };
5053
+ method: {
5054
+ id: string | null;
5055
+ name: string | null;
5056
+ estimated_days: string | null;
5057
+ };
5058
+ items: Array<{
5059
+ title: string;
5060
+ sku: string | null;
5061
+ quantity: number;
5062
+ }>;
5063
+ status: DropshipperDeliveryGroupStatus;
5064
+ /** Fulfillment vinculado, cuando el grupo ya fue cumplido; `null` si no. */
5065
+ fulfillment: {
5066
+ id: string;
5067
+ status: string;
5068
+ provider_id: string | null;
5069
+ packed_at: string | null;
5070
+ shipped_at: string | null;
5071
+ delivered_at: string | null;
5072
+ canceled_at: string | null;
5073
+ labels: DropshipperFulfillmentLabel[];
5074
+ } | null;
5075
+ /** Punto de recogida + encargado (solo grupos `pickup`). */
5076
+ pickup: {
5077
+ location: DropshipperPickupLocation | null;
5078
+ person_in_charge: string | null;
5079
+ } | null;
5080
+ }
4681
5081
  /** A credit line applied to an order (read-only; generated from a gift card,
4682
5082
  * store credit or payment collection). `amount` is in major units of
4683
5083
  * `currency_code`. */
@@ -4724,6 +5124,8 @@ interface DropshipperOrderDetail {
4724
5124
  claims?: DropshipperOrderClaim[];
4725
5125
  /** Fulfillments on the order, read-only (optional) */
4726
5126
  fulfillments?: DropshipperOrderFulfillment[];
5127
+ /** Grupos de entrega del plan de envío, con o sin fulfillment (optional). */
5128
+ delivery_groups?: DropshipperDeliveryGroup[];
4727
5129
  transactions: DropshipperTransaction[];
4728
5130
  financial_summary: DropshipperFinancialSummary;
4729
5131
  /** Credit lines applied to the order (read-only; `[]` when none). */
@@ -5046,6 +5448,8 @@ interface PreviewDropshipperOrderTotalsResponse {
5046
5448
  tax_total: number;
5047
5449
  discount_total: number;
5048
5450
  total: number;
5451
+ /** Desglose de impuestos por tasa (ítems + envío). `total` es el importe. */
5452
+ tax_lines: DropshipperOrderTaxLine[];
5049
5453
  }
5050
5454
  /** A dropshipper custom category node */
5051
5455
  interface DropshipperCategory {
@@ -6410,4 +6814,4 @@ type UpdateBusinessPolicyResponse = {
6410
6814
  business_policy: string;
6411
6815
  };
6412
6816
 
6413
- export { type AccountDropdownConfig, type AccountMenuItem, type AcknowledgeCostPriceChangesResponse, type ActiveFilter, type AddOrderEditItemBody, type AddOrderEditItemResponse, type Address, type AdminApiKey, type AdminChannelCategory, type AdminChannelCustomer, type AdminDropshipperAccount, type AdminDropshipperBalance, type AdminProduct, type AdminProductVariant, type AdminSalesChannelRef, type AdminSiteConfig, type AdminSiteConfigHistoryEntry, type AdminSiteConfigHistoryEntryFull, type AdminStorefrontConfig, type AdminStorefrontSeoDefaults, type AdminUser, type AdvancedSearchProductsOptions, type AssignCategoriesToChannelsBody, type AssignCategoriesToChannelsResponse, type AssignCollectionsToChannelsBody, type AssignCollectionsToChannelsResponse, type AuditLog, type AuditLogAdapter, type AuthConfig, type AuthMethod, type AuthProvider, type AuthResponse, type AuthStorage, type AuthorConfig, type BackendCapabilities, type BrandConfig, type CachedPaymentMethods, type CancelDropshipperOrderResponse, type CancelMovementBody, type CancelMovementResponse, type CancelSettlementBody, type Cart, type CartCost, type CartItem, type CartLineInput, type CartLineUpdate, type CartProduct, type CategoryMapping, type ChartDataPoint, type ChatAssistantHealthResponse, type ChatIntent, type ChatMessage, type ChatRequest, type ChatResponse, type ChatSource, type ChatSourceVariant, type Collection, type CollectionProductsOptions, type CommerceProvider, type CompareProduct, type ConfigHistoryEntry, type ConfirmMovementBody, type ConfirmMovementResponse, type ConfirmOrderEditResponse, type ConfirmSettlementBody, type Connection, type ConvertDropshipperDraftOrderBody, type ConvertDropshipperDraftOrderResponse, type CostPriceChangeItem, type CostPriceChangesCheckResponse, type CostPriceChangesResponse, type Country, type CreateAddressData, type CreateAjusteBody, type CreateAjusteResponse, type CreateCategoryMappingBody, type CreateCategoryMappingResponse, type CreateCobroBody, type CreateCobroResponse, type CreateCompensacionBody, type CreateCompensacionResponse, type CreateDropshipperCategoryBody, type CreateDropshipperCustomerBody, type CreateDropshipperCustomerResponse, type CreateDropshipperDraftOrderBody, type CreateDropshipperDraftOrderResponse, type CreateDropshipperOrderBody, type CreateDropshipperOrderResponse, type CreateDropshipperPromotionBody, type CreateOrderEditBody, type CreateOrderEditResponse, type CreateOrderItem, type CreateOrderNoteBody, type CreateOrderNoteResponse, type CreatePagoBody, type CreatePagoResponse, type CreateReversoBody, type CreateReversoResponse, type CreateSettlementBody, type CreateSettlementResponse, type Customer, type DashboardChanges, type DashboardConfig, type DashboardMetrics, type DashboardMetricsAdapter, type DashboardOrdersAdapter, type DashboardPeriodMetrics, type DashboardProductsAdapter, type DashboardStats, type DashboardTopProduct, type DeleteCategoryMappingResponse, type DeleteDropshipperCategoryResponse, type DeleteDropshipperDraftOrderResponse, type DeleteDropshipperPromotionResponse, type DeleteOrderNoteResponse, type DesignerConfig, type DesignerHistoryEntry, type DesignerNavItem, type DesignerThemeConfig, type DesignerThemePreset, type DiscountCode, type DropshipperAccount, type DropshipperAccountRef, type DropshipperAddressBody, type DropshipperAddressResponse, type DropshipperAttributeDefinition, type DropshipperAttributeDefinitionValue, type DropshipperBalance, type DropshipperCategory, type DropshipperCostTier, type DropshipperCustomer, type DropshipperCustomerAddress, type DropshipperCustomerDetail, type DropshipperCustomerFinancial, type DropshipperCustomerStats, type DropshipperDashboardCapabilities, type DropshipperDraftOrder, type DropshipperDraftOrderItem, type DropshipperNotificationEventType, type DropshipperNotificationPreference, type DropshipperOrder, type DropshipperOrderCustomer, type DropshipperOrderDetail, type DropshipperOrderItem, type DropshipperOrderShippingAddress, type DropshipperOrderTimelineEvent, type DropshipperOrderTotals, type DropshipperPayableOrder, type DropshipperPaymentMethodConfig, type DropshipperPendingOrders, type DropshipperPriceItem, type DropshipperPriceTier, type DropshipperProduct, type DropshipperProductAttachment, type DropshipperProductAttribute, type DropshipperProductAttributeValue, type DropshipperProductImage, type DropshipperProductOption, type DropshipperProductOptionValue, type DropshipperProductPrivateMedia, type DropshipperProfile, type DropshipperPromotion, type DropshipperReceivableOrder, type DropshipperSaleTier, type DropshipperShippingGroup, type DropshipperShippingGroupOption, type DropshipperShippingOption, type DropshipperVariant, type DynamicSource, type Edge, type ExtendedCreateDropshipperOrderBody, type ExtendedCreateDropshipperOrderResponse, type FilterConfig, type FilterOption, type FilterSection, type FulfillmentOption, type FulfillmentSet, type FulfillmentStatus, type GeoCity, type GeoCountry, type GeoProvince, type GetAdminAccountBalanceResponse, type GetAdminDropshipperAccountOrdersResponse, type GetAdminDropshipperAccountSettlementsOptions, type GetAdminDropshipperAccountSettlementsResponse, type GetAdminDropshipperAccountsResponse, type GetAdminPriceListsResponse, type GetAdminSiteConfigHistoryOptions, type GetAdminSiteConfigHistoryResponse, type GetAdminSiteConfigResponse, type GetAdminStorefrontConfigResponse, type GetBusinessPolicyResponse, type GetCategoriesCallback, type GetCategoriesOptions, type GetCategoryMappingsOptions, type GetCategoryMappingsResponse, type GetCategorySalesChannelsResponse, type GetChannelApiKeysResponse, type GetChannelCategoriesOptions, type GetChannelCategoriesResponse, type GetChannelCustomersOptions, type GetChannelCustomersResponse, type GetCollectionSalesChannelsResponse, type GetCollectionsOptions, type GetCustomersCallback, type GetCustomersOptions, type GetDashboardStatsOptions, type GetDashboardStatsResponse, type GetDropshipperAccountBalanceResponse, type GetDropshipperAccountOrdersOptions, type GetDropshipperAccountOrdersResponse, type GetDropshipperAccountResponse, type GetDropshipperAddressesResponse, type GetDropshipperAttributesResponse, type GetDropshipperCategoriesOptions, type GetDropshipperCategoriesResponse, type GetDropshipperCustomerDetailResponse, type GetDropshipperCustomersOptions, type GetDropshipperCustomersResponse, type GetDropshipperDraftOrderDetailResponse, type GetDropshipperDraftOrdersOptions, type GetDropshipperDraftOrdersResponse, type GetDropshipperOrderDetailResponse, type GetDropshipperOrdersOptions, type GetDropshipperOrdersResponse, type GetDropshipperPayableResponse, type GetDropshipperProductsOptions, type GetDropshipperProductsResponse, type GetDropshipperPromotionsOptions, type GetDropshipperPromotionsResponse, type GetDropshipperReceivableResponse, type GetDropshipperShippingOptionsBody, type GetDropshipperShippingOptionsResponse, type GetFinancialAnalysisResponse, type GetGeoCitiesResponse, type GetGeoCountriesResponse, type GetGeoProvincesResponse, type GetMyProfileResponse, type GetNotificationPreferencesResponse, type GetNotificationsOptions, type GetNotificationsResponse, type GetOrderNotesResponse, type GetOrdersCallback, type GetOrdersOptions, type GetProductAttributesResponse, type GetProductsOptions, type GetProviderCategoriesResponse, type GetSettlementDetailResponse, type GetSettlementsOptions, type GetSettlementsResponse, type GetStorefrontDropshipperCategoriesResponse, type GetUserChannelResponse, type HeaderLinkItem, type HeaderNavigationConfig, type IconConfig, type Image, type InterestCategory, type InventoryLevel, type LinkCustomerToChannelResponse, type LoginCredentials, type ManualAdminNotificationData, type ModulesConfig, type Money, type NavigationCalloutItem, type NavigationItem, type NavigationLinkItem, type NotificationData, type OnboardDropshipperBody, type OnboardDropshipperResponse, type Order, type OrderItem, type OrderNote, type OrderStatus, type OrdersMetrics, PROVIDER_METADATA, type PaginationOptions, type PasswordResetConfirm, type PasswordResetRequest, type PaymentMethod$1 as PaymentMethod, type PaymentMethodFeatures, type PaymentMethodType, type PaymentMethodsOptions, type PaymentStatus, type PreviewDropshipperOrderItem, type PreviewDropshipperOrderTotalsBody, type PreviewDropshipperOrderTotalsResponse, type PriceRange, type PriceUpdatedNotificationData, type Product, type ProductAssignedNotificationData, type ProductCategory, type ProductOption, type ProductPreview, type ProductVariant, type ProductsMetrics, type PromotionRule, type ProviderCategory, type ProviderConfig, type ProviderTypeString, type QueryEntitiesInput, type QueryEntityInput, type QueryErrors, type QueryMeta, type QueryResponse, type QuerySortDirection, type RawNotification, type RecoveryConfirmResult, type Region, type RegisterData, type RegisterPaymentBody, type RegisterPaymentResponse, type RequestedProfile, type ResolveGuaranteeBody, type ResolveGuaranteeResponse, type RestoreSiteConfigResponse, type Review, type SEO, type SalesChannelType, type SalesMetrics, type SearchBarConfig, type SearchResultMeta, type SelectedOption, type SetPaymentCollectorBody, type SetPaymentCollectorResponse, type SetPaymentMethodBody, type SetPaymentMethodResponse, type SettlementRecord, type SettlementStatus, type ShippingGroupInput, type ShippingMethod, type SiteConfig, type SiteConfigLabels, type SiteConfigMetadata, type SocialConfig, type SortOption, type SortOptions, type StockChangeNotificationData, type StockLocation, type StockStatus, type StockValidation, type StorefrontConfig, StorefrontConfigError, type StorefrontContext, type StorefrontPlatformType, type StorefrontSeoDefaults, type SubmitApplicationBody, type SubmitApplicationConflictApplication, type SubmitApplicationCreated, type SubmitApplicationResponse, type SubmitApplicationResult, type SubmitApplicationSalesChannel, SupportedProviderType, type TokenVerifyResult, type TokenVerifyState, type UnassignCategoriesFromChannelsBody, type UnassignCategoriesFromChannelsResponse, type UnassignCollectionsFromChannelsBody, type UnassignCollectionsFromChannelsResponse, type UpdateBusinessPolicyBody, type UpdateBusinessPolicyResponse, type UpdateCustomerData, type UpdateDropshipperCategoryBody, type UpdateDropshipperCustomerBody, type UpdateDropshipperCustomerResponse, type UpdateDropshipperDraftOrderBody, type UpdateDropshipperDraftOrderResponse, type UpdateDropshipperPricesBody, type UpdateDropshipperPricesResponse, type UpdateDropshipperProductStatusBody, type UpdateDropshipperProductStatusResponse, type UpdateDropshipperPromotionBody, type UpdateNotificationPreferencesBody, type UpdateSettlementStatusResponse, type UpdateSiteConfigBody, type UpdateSiteConfigResponse, type UpdateStorefrontConfigBody, type UpdateStorefrontConfigResponse, type ValidateCheckoutItemsRequest, type ValidateCheckoutItemsResponse, type ValidateGiftCardBody, type ValidateGiftCardResponse, type ValidatedCheckoutItem, getProviderMetadata, isSupportedProviderType };
6817
+ 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, 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, HeaderLinkItem, HeaderNavigationConfig, IconConfig, Image, InterestCategory, InventoryLevel, LinkCustomerToChannelResponse, LoginCredentials, ManualAdminNotificationData, ModulesConfig, Money, NavigationCalloutItem, NavigationItem, NavigationLinkItem, NotificationData, OnboardDropshipperBody, OnboardDropshipperResponse, Order, OrderItem, OrderNote, 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, ShippingGroupInput, ShippingMethod, ShopperIdentity, SiteConfig, SiteConfigLabels, SiteConfigMetadata, SocialConfig, SortOption, SortOptions, StockChangeNotificationData, StockLocation, StockStatus, StockValidation, StoreContext, 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 };