@cimplify/sdk 0.6.6 → 0.6.7

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.
@@ -1,5 +1,5 @@
1
- export { A as AuthService, B as BusinessService, i as CartOperations, b as CatalogueQueries, j as CheckoutOperations, j as CheckoutService, v as CimplifyElement, u as CimplifyElements, x as ELEMENT_TYPES, E as EVENT_TYPES, H as ElementEventType, z as ElementOptions, D as ElementType, y as ElementsOptions, F as FetchQuoteInput, r as FxService, G as GetProductsOptions, I as InventoryService, L as LinkService, q as LiteService, M as MESSAGE_TYPES, O as OrderQueries, P as PriceQuote, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, p as SchedulingService, S as SearchOptions, w as createElements, k as generateIdempotencyKey } from './client-CUFdFugo.mjs';
2
- import './payment-D-u3asA8.mjs';
1
+ export { A as AuthService, B as BusinessService, i as CartOperations, b as CatalogueQueries, j as CheckoutOperations, j as CheckoutService, v as CimplifyElement, u as CimplifyElements, x as ELEMENT_TYPES, E as EVENT_TYPES, H as ElementEventType, z as ElementOptions, D as ElementType, y as ElementsOptions, F as FetchQuoteInput, r as FxService, G as GetProductsOptions, I as InventoryService, L as LinkService, q as LiteService, M as MESSAGE_TYPES, O as OrderQueries, P as PriceQuote, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, p as SchedulingService, S as SearchOptions, w as createElements, k as generateIdempotencyKey } from './client-B4etj3AD.mjs';
2
+ import './payment-pjpfIKX8.mjs';
3
3
 
4
4
  type Operator = "==" | "!=" | ">" | "<" | ">=" | "<=" | "contains" | "startsWith";
5
5
  type SortOrder = "asc" | "desc";
@@ -1,5 +1,5 @@
1
- export { A as AuthService, B as BusinessService, i as CartOperations, b as CatalogueQueries, j as CheckoutOperations, j as CheckoutService, v as CimplifyElement, u as CimplifyElements, x as ELEMENT_TYPES, E as EVENT_TYPES, H as ElementEventType, z as ElementOptions, D as ElementType, y as ElementsOptions, F as FetchQuoteInput, r as FxService, G as GetProductsOptions, I as InventoryService, L as LinkService, q as LiteService, M as MESSAGE_TYPES, O as OrderQueries, P as PriceQuote, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, p as SchedulingService, S as SearchOptions, w as createElements, k as generateIdempotencyKey } from './client-CjqNbEM6.js';
2
- import './payment-D-u3asA8.js';
1
+ export { A as AuthService, B as BusinessService, i as CartOperations, b as CatalogueQueries, j as CheckoutOperations, j as CheckoutService, v as CimplifyElement, u as CimplifyElements, x as ELEMENT_TYPES, E as EVENT_TYPES, H as ElementEventType, z as ElementOptions, D as ElementType, y as ElementsOptions, F as FetchQuoteInput, r as FxService, G as GetProductsOptions, I as InventoryService, L as LinkService, q as LiteService, M as MESSAGE_TYPES, O as OrderQueries, P as PriceQuote, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, p as SchedulingService, S as SearchOptions, w as createElements, k as generateIdempotencyKey } from './client-CYVVuP5J.js';
2
+ import './payment-pjpfIKX8.js';
3
3
 
4
4
  type Operator = "==" | "!=" | ">" | "<" | ">=" | "<=" | "contains" | "startsWith";
5
5
  type SortOrder = "asc" | "desc";
package/dist/advanced.js CHANGED
@@ -9,11 +9,75 @@ function err(error) {
9
9
  }
10
10
 
11
11
  // src/types/common.ts
12
+ var ErrorCode = {
13
+ // General
14
+ UNKNOWN_ERROR: "UNKNOWN_ERROR"};
15
+ var DOCS_ERROR_BASE_URL = "https://docs.cimplify.io/reference/error-codes";
16
+ function docsUrlForCode(code) {
17
+ return `${DOCS_ERROR_BASE_URL}#${code.toLowerCase().replace(/_/g, "-")}`;
18
+ }
19
+ var ERROR_SUGGESTIONS = {
20
+ UNKNOWN_ERROR: "An unexpected error occurred. Capture the request/response payload and retry with exponential backoff.",
21
+ NETWORK_ERROR: "Check the shopper's connection and retry. If this persists, inspect CORS, DNS, and API reachability.",
22
+ TIMEOUT: "The request exceeded the timeout. Retry once, then poll order status before charging again.",
23
+ UNAUTHORIZED: "Authentication is missing or expired. Ensure a valid access token is set and refresh the session if needed.",
24
+ FORBIDDEN: "The key/session lacks permission for this resource. Verify business ownership and API key scope.",
25
+ NOT_FOUND: "The requested resource does not exist or is not visible in this environment.",
26
+ VALIDATION_ERROR: "One or more fields are invalid. Validate required fields and enum values before retrying.",
27
+ CART_EMPTY: "The cart has no items. Redirect back to menu/catalogue and require at least one line item.",
28
+ CART_EXPIRED: "This cart is no longer active. Recreate a new cart and re-add shopper selections.",
29
+ CART_NOT_FOUND: "Cart could not be located. It may have expired or belongs to a different key/location.",
30
+ ITEM_UNAVAILABLE: "The selected item is unavailable at this location/time. Prompt the shopper to pick an alternative.",
31
+ VARIANT_NOT_FOUND: "The requested variant no longer exists. Refresh product data and require re-selection.",
32
+ VARIANT_OUT_OF_STOCK: "The selected variant is out of stock. Show in-stock variants and block checkout for this line.",
33
+ ADDON_REQUIRED: "A required add-on is missing. Ensure required modifier groups are completed before add-to-cart.",
34
+ ADDON_MAX_EXCEEDED: "Too many add-ons were selected. Enforce max selections client-side before submission.",
35
+ CHECKOUT_VALIDATION_FAILED: "Checkout payload failed validation. Verify customer, order type, and address fields are complete.",
36
+ DELIVERY_ADDRESS_REQUIRED: "Delivery orders require an address. Collect and pass address info before processing checkout.",
37
+ CUSTOMER_INFO_REQUIRED: "Customer details are required. Ensure name/email/phone are available before checkout.",
38
+ PAYMENT_FAILED: "Payment provider rejected or failed processing. Show retry/change-method options to the shopper.",
39
+ PAYMENT_CANCELLED: "Payment was cancelled by the shopper or provider flow. Allow a safe retry path.",
40
+ INSUFFICIENT_FUNDS: "Payment method has insufficient funds. Prompt shopper to use another method.",
41
+ CARD_DECLINED: "Card was declined. Ask shopper to retry or switch payment method.",
42
+ INVALID_OTP: "Authorization code is invalid. Let shopper re-enter OTP/PIN and retry.",
43
+ OTP_EXPIRED: "Authorization code expired. Request a new OTP and re-submit authorization.",
44
+ AUTHORIZATION_FAILED: "Additional payment authorization failed. Retry authorization or change payment method.",
45
+ PAYMENT_ACTION_NOT_COMPLETED: "Required payment action was not completed. Resume provider flow and poll for status.",
46
+ SLOT_UNAVAILABLE: "Selected schedule slot is unavailable. Refresh available slots and ask shopper to reselect.",
47
+ BOOKING_CONFLICT: "The requested booking conflicts with an existing reservation. Pick another slot/resource.",
48
+ SERVICE_NOT_FOUND: "Requested service no longer exists. Refresh service catalogue and retry selection.",
49
+ OUT_OF_STOCK: "Inventory is depleted for this item. Remove it or reduce quantity before checkout.",
50
+ INSUFFICIENT_QUANTITY: "Requested quantity exceeds available inventory. Reduce quantity and retry.",
51
+ BUSINESS_ID_REQUIRED: "Business context could not be resolved. Verify the public key and business bootstrap call.",
52
+ INVALID_CART: "Cart is invalid for checkout. Sync cart state, ensure items exist, then retry.",
53
+ ORDER_TYPE_REQUIRED: "Order type is required. Provide one of delivery, pickup, or dine_in before checkout.",
54
+ NO_PAYMENT_ELEMENT: "PaymentElement is required for processCheckout(). Mount it before triggering checkout.",
55
+ PAYMENT_NOT_MOUNTED: "PaymentElement iframe is not mounted. Mount it in the DOM before processCheckout().",
56
+ AUTH_INCOMPLETE: "AuthElement has not completed authentication. Wait for AUTHENTICATED before checkout.",
57
+ AUTH_LOST: "Session was cleared during checkout. Re-authenticate and restart checkout safely.",
58
+ ALREADY_PROCESSING: "Checkout is already in progress. Disable duplicate submits until completion.",
59
+ CHECKOUT_NOT_READY: "Checkout elements are still initializing. Wait for readiness before submit.",
60
+ CANCELLED: "Checkout was cancelled. Preserve cart state and allow shopper to retry.",
61
+ REQUEST_TIMEOUT: "Provider call timed out. Poll payment/order status before issuing another charge attempt.",
62
+ POPUP_BLOCKED: "Browser blocked provider popup. Ask shopper to enable popups and retry.",
63
+ FX_QUOTE_FAILED: "Failed to lock FX quote. Retry currency quote or fallback to base currency."
64
+ };
65
+ var ERROR_HINTS = Object.fromEntries(
66
+ Object.entries(ERROR_SUGGESTIONS).map(([code, suggestion]) => [
67
+ code,
68
+ {
69
+ docs_url: docsUrlForCode(code),
70
+ suggestion
71
+ }
72
+ ])
73
+ );
12
74
  var CimplifyError = class extends Error {
13
- constructor(code, message, retryable = false) {
75
+ constructor(code, message, retryable = false, docs_url, suggestion) {
14
76
  super(message);
15
77
  this.code = code;
16
78
  this.retryable = retryable;
79
+ this.docs_url = docs_url;
80
+ this.suggestion = suggestion;
17
81
  this.name = "CimplifyError";
18
82
  }
19
83
  /** User-friendly message safe to display */
@@ -21,14 +85,36 @@ var CimplifyError = class extends Error {
21
85
  return this.message;
22
86
  }
23
87
  };
88
+ function getErrorHint(code) {
89
+ return ERROR_HINTS[code];
90
+ }
91
+ function enrichError(error, options = {}) {
92
+ const hint = getErrorHint(error.code);
93
+ if (hint) {
94
+ if (!error.docs_url) {
95
+ error.docs_url = hint.docs_url;
96
+ }
97
+ if (!error.suggestion) {
98
+ error.suggestion = hint.suggestion;
99
+ }
100
+ } else if (!error.docs_url) {
101
+ error.docs_url = docsUrlForCode(error.code || ErrorCode.UNKNOWN_ERROR);
102
+ }
103
+ if (options.isTestMode && !error.message.includes("pk_test_")) {
104
+ error.message = `${error.message}
105
+
106
+ \u2139 Your API key is a test-mode key (pk_test_...). Verify test data/session before retrying.`;
107
+ }
108
+ return error;
109
+ }
24
110
 
25
111
  // src/catalogue.ts
26
112
  function toCimplifyError(error) {
27
- if (error instanceof CimplifyError) return error;
113
+ if (error instanceof CimplifyError) return enrichError(error);
28
114
  if (error instanceof Error) {
29
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
115
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
30
116
  }
31
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
117
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
32
118
  }
33
119
  async function safe(promise) {
34
120
  try {
@@ -323,11 +409,11 @@ var CatalogueQueries = class {
323
409
 
324
410
  // src/cart.ts
325
411
  function toCimplifyError2(error) {
326
- if (error instanceof CimplifyError) return error;
412
+ if (error instanceof CimplifyError) return enrichError(error);
327
413
  if (error instanceof Error) {
328
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
414
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
329
415
  }
330
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
416
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
331
417
  }
332
418
  async function safe2(promise) {
333
419
  try {
@@ -1166,11 +1252,11 @@ var CheckoutResolver = class {
1166
1252
 
1167
1253
  // src/checkout.ts
1168
1254
  function toCimplifyError3(error) {
1169
- if (error instanceof CimplifyError) return error;
1255
+ if (error instanceof CimplifyError) return enrichError(error);
1170
1256
  if (error instanceof Error) {
1171
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
1257
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
1172
1258
  }
1173
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
1259
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
1174
1260
  }
1175
1261
  async function safe3(promise) {
1176
1262
  try {
@@ -1346,11 +1432,11 @@ var CheckoutService = class {
1346
1432
 
1347
1433
  // src/orders.ts
1348
1434
  function toCimplifyError4(error) {
1349
- if (error instanceof CimplifyError) return error;
1435
+ if (error instanceof CimplifyError) return enrichError(error);
1350
1436
  if (error instanceof Error) {
1351
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
1437
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
1352
1438
  }
1353
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
1439
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
1354
1440
  }
1355
1441
  async function safe4(promise) {
1356
1442
  try {
@@ -1607,11 +1693,11 @@ var AuthService = class {
1607
1693
 
1608
1694
  // src/business.ts
1609
1695
  function toCimplifyError7(error) {
1610
- if (error instanceof CimplifyError) return error;
1696
+ if (error instanceof CimplifyError) return enrichError(error);
1611
1697
  if (error instanceof Error) {
1612
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
1698
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
1613
1699
  }
1614
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
1700
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
1615
1701
  }
1616
1702
  async function safe7(promise) {
1617
1703
  try {
@@ -1997,12 +2083,15 @@ var EVENT_TYPES = {
1997
2083
 
1998
2084
  // src/elements.ts
1999
2085
  function toCheckoutError(code, message, recoverable) {
2086
+ const hint = getErrorHint(code);
2000
2087
  return {
2001
2088
  success: false,
2002
2089
  error: {
2003
2090
  code,
2004
2091
  message,
2005
- recoverable
2092
+ recoverable,
2093
+ docs_url: hint?.docs_url,
2094
+ suggestion: hint?.suggestion
2006
2095
  }
2007
2096
  };
2008
2097
  }
@@ -2043,6 +2132,7 @@ var CimplifyElements = class {
2043
2132
  this.paymentData = null;
2044
2133
  this.checkoutInProgress = false;
2045
2134
  this.activeCheckoutAbort = null;
2135
+ this.hasWarnedMissingAuthElement = false;
2046
2136
  this.businessIdResolvePromise = null;
2047
2137
  this.client = client;
2048
2138
  this.businessId = businessId ?? null;
@@ -2138,6 +2228,12 @@ var CimplifyElements = class {
2138
2228
  );
2139
2229
  }
2140
2230
  const authElement = this.elements.get(ELEMENT_TYPES.AUTH);
2231
+ if (!authElement && !this.hasWarnedMissingAuthElement) {
2232
+ this.hasWarnedMissingAuthElement = true;
2233
+ console.warn(
2234
+ "[Cimplify] processCheckout() called without AuthElement mounted. For best conversion and Link enrollment, mount <AuthElement> before checkout."
2235
+ );
2236
+ }
2141
2237
  if (authElement && !this.accessToken) {
2142
2238
  return toCheckoutError(
2143
2239
  "AUTH_INCOMPLETE",
package/dist/advanced.mjs CHANGED
@@ -7,11 +7,75 @@ function err(error) {
7
7
  }
8
8
 
9
9
  // src/types/common.ts
10
+ var ErrorCode = {
11
+ // General
12
+ UNKNOWN_ERROR: "UNKNOWN_ERROR"};
13
+ var DOCS_ERROR_BASE_URL = "https://docs.cimplify.io/reference/error-codes";
14
+ function docsUrlForCode(code) {
15
+ return `${DOCS_ERROR_BASE_URL}#${code.toLowerCase().replace(/_/g, "-")}`;
16
+ }
17
+ var ERROR_SUGGESTIONS = {
18
+ UNKNOWN_ERROR: "An unexpected error occurred. Capture the request/response payload and retry with exponential backoff.",
19
+ NETWORK_ERROR: "Check the shopper's connection and retry. If this persists, inspect CORS, DNS, and API reachability.",
20
+ TIMEOUT: "The request exceeded the timeout. Retry once, then poll order status before charging again.",
21
+ UNAUTHORIZED: "Authentication is missing or expired. Ensure a valid access token is set and refresh the session if needed.",
22
+ FORBIDDEN: "The key/session lacks permission for this resource. Verify business ownership and API key scope.",
23
+ NOT_FOUND: "The requested resource does not exist or is not visible in this environment.",
24
+ VALIDATION_ERROR: "One or more fields are invalid. Validate required fields and enum values before retrying.",
25
+ CART_EMPTY: "The cart has no items. Redirect back to menu/catalogue and require at least one line item.",
26
+ CART_EXPIRED: "This cart is no longer active. Recreate a new cart and re-add shopper selections.",
27
+ CART_NOT_FOUND: "Cart could not be located. It may have expired or belongs to a different key/location.",
28
+ ITEM_UNAVAILABLE: "The selected item is unavailable at this location/time. Prompt the shopper to pick an alternative.",
29
+ VARIANT_NOT_FOUND: "The requested variant no longer exists. Refresh product data and require re-selection.",
30
+ VARIANT_OUT_OF_STOCK: "The selected variant is out of stock. Show in-stock variants and block checkout for this line.",
31
+ ADDON_REQUIRED: "A required add-on is missing. Ensure required modifier groups are completed before add-to-cart.",
32
+ ADDON_MAX_EXCEEDED: "Too many add-ons were selected. Enforce max selections client-side before submission.",
33
+ CHECKOUT_VALIDATION_FAILED: "Checkout payload failed validation. Verify customer, order type, and address fields are complete.",
34
+ DELIVERY_ADDRESS_REQUIRED: "Delivery orders require an address. Collect and pass address info before processing checkout.",
35
+ CUSTOMER_INFO_REQUIRED: "Customer details are required. Ensure name/email/phone are available before checkout.",
36
+ PAYMENT_FAILED: "Payment provider rejected or failed processing. Show retry/change-method options to the shopper.",
37
+ PAYMENT_CANCELLED: "Payment was cancelled by the shopper or provider flow. Allow a safe retry path.",
38
+ INSUFFICIENT_FUNDS: "Payment method has insufficient funds. Prompt shopper to use another method.",
39
+ CARD_DECLINED: "Card was declined. Ask shopper to retry or switch payment method.",
40
+ INVALID_OTP: "Authorization code is invalid. Let shopper re-enter OTP/PIN and retry.",
41
+ OTP_EXPIRED: "Authorization code expired. Request a new OTP and re-submit authorization.",
42
+ AUTHORIZATION_FAILED: "Additional payment authorization failed. Retry authorization or change payment method.",
43
+ PAYMENT_ACTION_NOT_COMPLETED: "Required payment action was not completed. Resume provider flow and poll for status.",
44
+ SLOT_UNAVAILABLE: "Selected schedule slot is unavailable. Refresh available slots and ask shopper to reselect.",
45
+ BOOKING_CONFLICT: "The requested booking conflicts with an existing reservation. Pick another slot/resource.",
46
+ SERVICE_NOT_FOUND: "Requested service no longer exists. Refresh service catalogue and retry selection.",
47
+ OUT_OF_STOCK: "Inventory is depleted for this item. Remove it or reduce quantity before checkout.",
48
+ INSUFFICIENT_QUANTITY: "Requested quantity exceeds available inventory. Reduce quantity and retry.",
49
+ BUSINESS_ID_REQUIRED: "Business context could not be resolved. Verify the public key and business bootstrap call.",
50
+ INVALID_CART: "Cart is invalid for checkout. Sync cart state, ensure items exist, then retry.",
51
+ ORDER_TYPE_REQUIRED: "Order type is required. Provide one of delivery, pickup, or dine_in before checkout.",
52
+ NO_PAYMENT_ELEMENT: "PaymentElement is required for processCheckout(). Mount it before triggering checkout.",
53
+ PAYMENT_NOT_MOUNTED: "PaymentElement iframe is not mounted. Mount it in the DOM before processCheckout().",
54
+ AUTH_INCOMPLETE: "AuthElement has not completed authentication. Wait for AUTHENTICATED before checkout.",
55
+ AUTH_LOST: "Session was cleared during checkout. Re-authenticate and restart checkout safely.",
56
+ ALREADY_PROCESSING: "Checkout is already in progress. Disable duplicate submits until completion.",
57
+ CHECKOUT_NOT_READY: "Checkout elements are still initializing. Wait for readiness before submit.",
58
+ CANCELLED: "Checkout was cancelled. Preserve cart state and allow shopper to retry.",
59
+ REQUEST_TIMEOUT: "Provider call timed out. Poll payment/order status before issuing another charge attempt.",
60
+ POPUP_BLOCKED: "Browser blocked provider popup. Ask shopper to enable popups and retry.",
61
+ FX_QUOTE_FAILED: "Failed to lock FX quote. Retry currency quote or fallback to base currency."
62
+ };
63
+ var ERROR_HINTS = Object.fromEntries(
64
+ Object.entries(ERROR_SUGGESTIONS).map(([code, suggestion]) => [
65
+ code,
66
+ {
67
+ docs_url: docsUrlForCode(code),
68
+ suggestion
69
+ }
70
+ ])
71
+ );
10
72
  var CimplifyError = class extends Error {
11
- constructor(code, message, retryable = false) {
73
+ constructor(code, message, retryable = false, docs_url, suggestion) {
12
74
  super(message);
13
75
  this.code = code;
14
76
  this.retryable = retryable;
77
+ this.docs_url = docs_url;
78
+ this.suggestion = suggestion;
15
79
  this.name = "CimplifyError";
16
80
  }
17
81
  /** User-friendly message safe to display */
@@ -19,14 +83,36 @@ var CimplifyError = class extends Error {
19
83
  return this.message;
20
84
  }
21
85
  };
86
+ function getErrorHint(code) {
87
+ return ERROR_HINTS[code];
88
+ }
89
+ function enrichError(error, options = {}) {
90
+ const hint = getErrorHint(error.code);
91
+ if (hint) {
92
+ if (!error.docs_url) {
93
+ error.docs_url = hint.docs_url;
94
+ }
95
+ if (!error.suggestion) {
96
+ error.suggestion = hint.suggestion;
97
+ }
98
+ } else if (!error.docs_url) {
99
+ error.docs_url = docsUrlForCode(error.code || ErrorCode.UNKNOWN_ERROR);
100
+ }
101
+ if (options.isTestMode && !error.message.includes("pk_test_")) {
102
+ error.message = `${error.message}
103
+
104
+ \u2139 Your API key is a test-mode key (pk_test_...). Verify test data/session before retrying.`;
105
+ }
106
+ return error;
107
+ }
22
108
 
23
109
  // src/catalogue.ts
24
110
  function toCimplifyError(error) {
25
- if (error instanceof CimplifyError) return error;
111
+ if (error instanceof CimplifyError) return enrichError(error);
26
112
  if (error instanceof Error) {
27
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
113
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
28
114
  }
29
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
115
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
30
116
  }
31
117
  async function safe(promise) {
32
118
  try {
@@ -321,11 +407,11 @@ var CatalogueQueries = class {
321
407
 
322
408
  // src/cart.ts
323
409
  function toCimplifyError2(error) {
324
- if (error instanceof CimplifyError) return error;
410
+ if (error instanceof CimplifyError) return enrichError(error);
325
411
  if (error instanceof Error) {
326
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
412
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
327
413
  }
328
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
414
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
329
415
  }
330
416
  async function safe2(promise) {
331
417
  try {
@@ -1164,11 +1250,11 @@ var CheckoutResolver = class {
1164
1250
 
1165
1251
  // src/checkout.ts
1166
1252
  function toCimplifyError3(error) {
1167
- if (error instanceof CimplifyError) return error;
1253
+ if (error instanceof CimplifyError) return enrichError(error);
1168
1254
  if (error instanceof Error) {
1169
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
1255
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
1170
1256
  }
1171
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
1257
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
1172
1258
  }
1173
1259
  async function safe3(promise) {
1174
1260
  try {
@@ -1344,11 +1430,11 @@ var CheckoutService = class {
1344
1430
 
1345
1431
  // src/orders.ts
1346
1432
  function toCimplifyError4(error) {
1347
- if (error instanceof CimplifyError) return error;
1433
+ if (error instanceof CimplifyError) return enrichError(error);
1348
1434
  if (error instanceof Error) {
1349
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
1435
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
1350
1436
  }
1351
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
1437
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
1352
1438
  }
1353
1439
  async function safe4(promise) {
1354
1440
  try {
@@ -1605,11 +1691,11 @@ var AuthService = class {
1605
1691
 
1606
1692
  // src/business.ts
1607
1693
  function toCimplifyError7(error) {
1608
- if (error instanceof CimplifyError) return error;
1694
+ if (error instanceof CimplifyError) return enrichError(error);
1609
1695
  if (error instanceof Error) {
1610
- return new CimplifyError("UNKNOWN_ERROR", error.message, false);
1696
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, error.message, false));
1611
1697
  }
1612
- return new CimplifyError("UNKNOWN_ERROR", String(error), false);
1698
+ return enrichError(new CimplifyError(ErrorCode.UNKNOWN_ERROR, String(error), false));
1613
1699
  }
1614
1700
  async function safe7(promise) {
1615
1701
  try {
@@ -1995,12 +2081,15 @@ var EVENT_TYPES = {
1995
2081
 
1996
2082
  // src/elements.ts
1997
2083
  function toCheckoutError(code, message, recoverable) {
2084
+ const hint = getErrorHint(code);
1998
2085
  return {
1999
2086
  success: false,
2000
2087
  error: {
2001
2088
  code,
2002
2089
  message,
2003
- recoverable
2090
+ recoverable,
2091
+ docs_url: hint?.docs_url,
2092
+ suggestion: hint?.suggestion
2004
2093
  }
2005
2094
  };
2006
2095
  }
@@ -2041,6 +2130,7 @@ var CimplifyElements = class {
2041
2130
  this.paymentData = null;
2042
2131
  this.checkoutInProgress = false;
2043
2132
  this.activeCheckoutAbort = null;
2133
+ this.hasWarnedMissingAuthElement = false;
2044
2134
  this.businessIdResolvePromise = null;
2045
2135
  this.client = client;
2046
2136
  this.businessId = businessId ?? null;
@@ -2136,6 +2226,12 @@ var CimplifyElements = class {
2136
2226
  );
2137
2227
  }
2138
2228
  const authElement = this.elements.get(ELEMENT_TYPES.AUTH);
2229
+ if (!authElement && !this.hasWarnedMissingAuthElement) {
2230
+ this.hasWarnedMissingAuthElement = true;
2231
+ console.warn(
2232
+ "[Cimplify] processCheckout() called without AuthElement mounted. For best conversion and Link enrollment, mount <AuthElement> before checkout."
2233
+ );
2234
+ }
2139
2235
  if (authElement && !this.accessToken) {
2140
2236
  return toCheckoutError(
2141
2237
  "AUTH_INCOMPLETE",
@@ -1,4 +1,4 @@
1
- import { M as Money, c as CimplifyError, h as AuthorizationType, k as PaymentMethod, I as InitializePaymentResult, S as SubmitAuthorizationInput, n as PaymentStatusResponse } from './payment-D-u3asA8.mjs';
1
+ import { M as Money, e as CimplifyError, m as AuthorizationType, o as PaymentMethod, I as InitializePaymentResult, S as SubmitAuthorizationInput, r as PaymentStatusResponse } from './payment-pjpfIKX8.mjs';
2
2
 
3
3
  /**
4
4
  * Observability hooks for monitoring SDK behavior.
@@ -2063,6 +2063,8 @@ interface ProcessCheckoutResult {
2063
2063
  code: string;
2064
2064
  message: string;
2065
2065
  recoverable: boolean;
2066
+ docs_url?: string;
2067
+ suggestion?: string;
2066
2068
  };
2067
2069
  enrolled_in_link?: boolean;
2068
2070
  }
@@ -3117,6 +3119,7 @@ declare class CimplifyElements {
3117
3119
  private paymentData;
3118
3120
  private checkoutInProgress;
3119
3121
  private activeCheckoutAbort;
3122
+ private hasWarnedMissingAuthElement;
3120
3123
  private boundHandleMessage;
3121
3124
  private businessIdResolvePromise;
3122
3125
  constructor(client: CimplifyClient, businessId?: string, options?: ElementsOptions);
@@ -3208,6 +3211,7 @@ declare class CimplifyClient {
3208
3211
  setSessionToken(token: string | null): void;
3209
3212
  getAccessToken(): string | null;
3210
3213
  getPublicKey(): string;
3214
+ isTestMode(): boolean;
3211
3215
  setAccessToken(token: string | null): void;
3212
3216
  clearSession(): void;
3213
3217
  /** Set the active location/branch for all subsequent requests */
@@ -1,4 +1,4 @@
1
- import { M as Money, c as CimplifyError, h as AuthorizationType, k as PaymentMethod, I as InitializePaymentResult, S as SubmitAuthorizationInput, n as PaymentStatusResponse } from './payment-D-u3asA8.js';
1
+ import { M as Money, e as CimplifyError, m as AuthorizationType, o as PaymentMethod, I as InitializePaymentResult, S as SubmitAuthorizationInput, r as PaymentStatusResponse } from './payment-pjpfIKX8.js';
2
2
 
3
3
  /**
4
4
  * Observability hooks for monitoring SDK behavior.
@@ -2063,6 +2063,8 @@ interface ProcessCheckoutResult {
2063
2063
  code: string;
2064
2064
  message: string;
2065
2065
  recoverable: boolean;
2066
+ docs_url?: string;
2067
+ suggestion?: string;
2066
2068
  };
2067
2069
  enrolled_in_link?: boolean;
2068
2070
  }
@@ -3117,6 +3119,7 @@ declare class CimplifyElements {
3117
3119
  private paymentData;
3118
3120
  private checkoutInProgress;
3119
3121
  private activeCheckoutAbort;
3122
+ private hasWarnedMissingAuthElement;
3120
3123
  private boundHandleMessage;
3121
3124
  private businessIdResolvePromise;
3122
3125
  constructor(client: CimplifyClient, businessId?: string, options?: ElementsOptions);
@@ -3208,6 +3211,7 @@ declare class CimplifyClient {
3208
3211
  setSessionToken(token: string | null): void;
3209
3212
  getAccessToken(): string | null;
3210
3213
  getPublicKey(): string;
3214
+ isTestMode(): boolean;
3211
3215
  setAccessToken(token: string | null): void;
3212
3216
  clearSession(): void;
3213
3217
  /** Set the active location/branch for all subsequent requests */
@@ -1,4 +1,4 @@
1
- import { o as PaymentErrorDetails, m as PaymentResponse, n as PaymentStatusResponse } from './payment-D-u3asA8.js';
1
+ import { s as PaymentErrorDetails, q as PaymentResponse, r as PaymentStatusResponse } from './payment-pjpfIKX8.js';
2
2
 
3
3
  /**
4
4
  * Price Types
@@ -1,4 +1,4 @@
1
- import { o as PaymentErrorDetails, m as PaymentResponse, n as PaymentStatusResponse } from './payment-D-u3asA8.mjs';
1
+ import { s as PaymentErrorDetails, q as PaymentResponse, r as PaymentStatusResponse } from './payment-pjpfIKX8.mjs';
2
2
 
3
3
  /**
4
4
  * Price Types
package/dist/index.d.mts CHANGED
@@ -1,8 +1,8 @@
1
- export { ad as AUTHORIZATION_TYPE, ai as AUTH_MUTATION, a2 as AbortablePromise, aV as AddOn, bE as AddOnDetails, b_ as AddOnGroupDetails, aX as AddOnOption, bZ as AddOnOptionDetails, aY as AddOnOptionPrice, aW as AddOnWithOptions, c3 as AddToCartInput, dN as AddressData, ed as AddressInfo, bt as AdjustmentType, ch as AmountToPay, bA as AppliedDiscount, dY as AuthResponse, A as AuthService, m as AuthStatus, ef as AuthenticatedCustomer, eh as AuthenticatedData, dB as AvailabilityCheck, dC as AvailabilityResult, di as AvailableSlot, bz as BenefitType, dl as Booking, dc as BookingRequirementOverride, dk as BookingStatus, dm as BookingWithDetails, cB as BufferTimes, b4 as Bundle, b8 as BundleComponentData, b9 as BundleComponentInfo, b3 as BundlePriceType, b6 as BundleProduct, bJ as BundleSelectionData, bH as BundleSelectionInput, bI as BundleStoredSelection, b5 as BundleSummary, b7 as BundleWithDetails, cQ as Business, d2 as BusinessHours, cP as BusinessPreferences, B as BusinessService, d1 as BusinessSettings, cO as BusinessType, c$ as BusinessWithLocations, a6 as CHECKOUT_MODE, aj as CHECKOUT_MUTATION, a9 as CHECKOUT_STEP, af as CONTACT_TYPE, dr as CancelBookingInput, cv as CancelOrderInput, cD as CancellationPolicy, bO as Cart, bF as CartAddOn, br as CartChannel, bP as CartItem, c0 as CartItemDetails, i as CartOperations, bq as CartStatus, c5 as CartSummary, bQ as CartTotals, b as CatalogueQueries, a_ as Category, d3 as CategoryInfo, a$ as CategorySummary, o as ChangePasswordInput, dp as CheckSlotAvailabilityInput, d$ as CheckoutAddressInfo, e1 as CheckoutCustomerInfo, X as CheckoutFormData, ct as CheckoutInput, J as CheckoutMode, j as CheckoutOperations, N as CheckoutOrderType, V as CheckoutPaymentMethod, Y as CheckoutResult, j as CheckoutService, a0 as CheckoutStatus, a1 as CheckoutStatusContext, W as CheckoutStep, by as ChosenPrice, C as CimplifyClient, a as CimplifyConfig, v as CimplifyElement, u as CimplifyElements, b0 as Collection, b2 as CollectionProduct, b1 as CollectionSummary, bf as ComponentGroup, bg as ComponentGroupWithComponents, bk as ComponentPriceBreakdown, bi as ComponentSelectionInput, bc as ComponentSourceType, bd as Composite, bh as CompositeComponent, bL as CompositePriceBreakdown, bj as CompositePriceResult, ba as CompositePricingMode, bM as CompositeSelectionData, bi as CompositeSelectionInput, bK as CompositeStoredSelection, be as CompositeWithDetails, a5 as ContactType, dJ as CreateAddressInput, dL as CreateMobileMoneyInput, dE as Customer, dF as CustomerAddress, dH as CustomerLinkPreferences, dG as CustomerMobileMoney, cA as CustomerServicePreferences, an as DEFAULT_COUNTRY, am as DEFAULT_CURRENCY, ae as DEVICE_TYPE, dj as DayAvailability, cK as DepositResult, aJ as DepositType, a4 as DeviceType, aI as DigitalProductType, bB as DiscountBreakdown, bC as DiscountDetails, bT as DisplayAddOn, bU as DisplayAddOnOption, bR as DisplayCart, bS as DisplayCartItem, x as ELEMENT_TYPES, E as EVENT_TYPES, ec as ElementAppearance, em as ElementEventHandler, H as ElementEventType, z as ElementOptions, D as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, eg as ElementsCustomerInfo, y as ElementsOptions, dP as EnrollAndLinkOrderInput, dS as EnrollAndLinkOrderResult, dM as EnrollmentData, aq as Err, cg as FeeBearerType, F as FetchQuoteInput, ce as FulfillmentLink, cd as FulfillmentStatus, cc as FulfillmentType, e3 as FxQuote, e2 as FxQuoteRequest, e4 as FxRateResponse, r as FxService, dn as GetAvailableSlotsInput, l as GetOrdersOptions, G as GetProductsOptions, bb as GroupPricingBehavior, el as IframeToParentMessage, I as InventoryService, dD as InventorySummary, aG as InventoryType, K as KitchenOrderItem, t as KitchenOrderResult, ah as LINK_MUTATION, ag as LINK_QUERY, bN as LineConfiguration, ci as LineItem, c9 as LineType, dI as LinkData, dR as LinkEnrollResult, L as LinkService, dT as LinkSession, dQ as LinkStatusResult, s as LiteBootstrap, q as LiteService, cT as Location, cN as LocationAppointment, bn as LocationProductPrice, dA as LocationStock, cR as LocationTaxBehavior, cS as LocationTaxOverrides, cW as LocationTimeProfile, d0 as LocationWithDetails, M as MESSAGE_TYPES, ac as MOBILE_MONEY_PROVIDER, dO as MobileMoneyData, e0 as MobileMoneyDetails, a3 as MobileMoneyProvider, al as ORDER_MUTATION, a7 as ORDER_TYPE, eb as ObservabilityHooks, ap as Ok, cj as Order, c8 as OrderChannel, cs as OrderFilter, cf as OrderFulfillmentSummary, cm as OrderGroup, cq as OrderGroupDetails, cn as OrderGroupPayment, cl as OrderGroupPaymentState, cp as OrderGroupPaymentSummary, ck as OrderHistory, ca as OrderLineState, cb as OrderLineStatus, cr as OrderPaymentEvent, O as OrderQueries, co as OrderSplitDetail, c6 as OrderStatus, n as OtpResult, a8 as PAYMENT_METHOD, ak as PAYMENT_MUTATION, aa as PAYMENT_STATE, ab as PICKUP_TIME_TYPE, ek as ParentToIframeMessage, ee as PaymentMethodInfo, c7 as PaymentState, d_ as PickupTime, dZ as PickupTimeType, bm as Price, bu as PriceAdjustment, bx as PriceDecisionPath, bl as PriceEntryType, bw as PricePathTaxInfo, P as PriceQuote, bs as PriceSource, cF as PricingOverrides, $ as ProcessAndResolveOptions, Z as ProcessCheckoutOptions, _ as ProcessCheckoutResult, aL as Product, aZ as ProductAddOn, bo as ProductAvailability, dy as ProductStock, bp as ProductTimeProfile, aF as ProductType, aN as ProductVariant, aS as ProductVariantValue, aM as ProductWithDetails, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, cw as RefundOrderInput, cz as ReminderMethod, cC as ReminderSettings, e5 as RequestContext, e8 as RequestErrorEvent, dW as RequestOtpInput, e6 as RequestStartEvent, e7 as RequestSuccessEvent, dq as RescheduleBookingInput, cI as ResourceAssignment, d9 as ResourceAvailabilityException, d8 as ResourceAvailabilityRule, dd as ResourceType, ao as Result, e9 as RetryEvent, dV as RevokeAllSessionsResult, dU as RevokeSessionResult, cY as Room, aK as SalesChannel, cG as SchedulingMetadata, cJ as SchedulingResult, p as SchedulingService, S as SearchOptions, bD as SelectedAddOnOption, de as Service, d5 as ServiceAvailabilityException, ds as ServiceAvailabilityParams, dt as ServiceAvailabilityResult, d4 as ServiceAvailabilityRule, cZ as ServiceCharge, cE as ServiceNotes, cL as ServiceScheduleRequest, db as ServiceStaffRequirement, cx as ServiceStatus, df as ServiceWithStaff, ea as SessionChangeEvent, dg as Staff, cH as StaffAssignment, d7 as StaffAvailabilityException, d6 as StaffAvailabilityRule, da as StaffBookingProfile, cy as StaffRole, cM as StaffScheduleItem, dw as Stock, dx as StockLevel, du as StockOwnershipType, dv as StockStatus, c_ as StorefrontBootstrap, cX as Table, T as TableInfo, bv as TaxPathComponent, cU as TimeRange, cV as TimeRanges, dh as TimeSlot, c1 as UICart, bV as UICartBusiness, bX as UICartCustomer, bW as UICartLocation, bY as UICartPricing, c2 as UICartResponse, dK as UpdateAddressInput, c4 as UpdateCartItemInput, cu as UpdateOrderStatusInput, U as UpdateProfileInput, aP as VariantAxis, aU as VariantAxisSelection, aR as VariantAxisValue, aQ as VariantAxisWithValues, bG as VariantDetails, b$ as VariantDetailsDTO, aO as VariantDisplayAttribute, aT as VariantLocationAvailability, dz as VariantStock, aH as VariantStrategy, dX as VerifyOtpInput, aD as combine, aE as combineObject, c as createCimplifyClient, w as createElements, as as err, ax as flatMap, aB as fromPromise, k as generateIdempotencyKey, ay as getOrElse, au as isErr, at as isOk, aw as mapError, av as mapResult, ar as ok, aA as toNullable, aC as tryCatch, az as unwrap } from './client-CUFdFugo.mjs';
1
+ export { ad as AUTHORIZATION_TYPE, ai as AUTH_MUTATION, a2 as AbortablePromise, aV as AddOn, bE as AddOnDetails, b_ as AddOnGroupDetails, aX as AddOnOption, bZ as AddOnOptionDetails, aY as AddOnOptionPrice, aW as AddOnWithOptions, c3 as AddToCartInput, dN as AddressData, ed as AddressInfo, bt as AdjustmentType, ch as AmountToPay, bA as AppliedDiscount, dY as AuthResponse, A as AuthService, m as AuthStatus, ef as AuthenticatedCustomer, eh as AuthenticatedData, dB as AvailabilityCheck, dC as AvailabilityResult, di as AvailableSlot, bz as BenefitType, dl as Booking, dc as BookingRequirementOverride, dk as BookingStatus, dm as BookingWithDetails, cB as BufferTimes, b4 as Bundle, b8 as BundleComponentData, b9 as BundleComponentInfo, b3 as BundlePriceType, b6 as BundleProduct, bJ as BundleSelectionData, bH as BundleSelectionInput, bI as BundleStoredSelection, b5 as BundleSummary, b7 as BundleWithDetails, cQ as Business, d2 as BusinessHours, cP as BusinessPreferences, B as BusinessService, d1 as BusinessSettings, cO as BusinessType, c$ as BusinessWithLocations, a6 as CHECKOUT_MODE, aj as CHECKOUT_MUTATION, a9 as CHECKOUT_STEP, af as CONTACT_TYPE, dr as CancelBookingInput, cv as CancelOrderInput, cD as CancellationPolicy, bO as Cart, bF as CartAddOn, br as CartChannel, bP as CartItem, c0 as CartItemDetails, i as CartOperations, bq as CartStatus, c5 as CartSummary, bQ as CartTotals, b as CatalogueQueries, a_ as Category, d3 as CategoryInfo, a$ as CategorySummary, o as ChangePasswordInput, dp as CheckSlotAvailabilityInput, d$ as CheckoutAddressInfo, e1 as CheckoutCustomerInfo, X as CheckoutFormData, ct as CheckoutInput, J as CheckoutMode, j as CheckoutOperations, N as CheckoutOrderType, V as CheckoutPaymentMethod, Y as CheckoutResult, j as CheckoutService, a0 as CheckoutStatus, a1 as CheckoutStatusContext, W as CheckoutStep, by as ChosenPrice, C as CimplifyClient, a as CimplifyConfig, v as CimplifyElement, u as CimplifyElements, b0 as Collection, b2 as CollectionProduct, b1 as CollectionSummary, bf as ComponentGroup, bg as ComponentGroupWithComponents, bk as ComponentPriceBreakdown, bi as ComponentSelectionInput, bc as ComponentSourceType, bd as Composite, bh as CompositeComponent, bL as CompositePriceBreakdown, bj as CompositePriceResult, ba as CompositePricingMode, bM as CompositeSelectionData, bi as CompositeSelectionInput, bK as CompositeStoredSelection, be as CompositeWithDetails, a5 as ContactType, dJ as CreateAddressInput, dL as CreateMobileMoneyInput, dE as Customer, dF as CustomerAddress, dH as CustomerLinkPreferences, dG as CustomerMobileMoney, cA as CustomerServicePreferences, an as DEFAULT_COUNTRY, am as DEFAULT_CURRENCY, ae as DEVICE_TYPE, dj as DayAvailability, cK as DepositResult, aJ as DepositType, a4 as DeviceType, aI as DigitalProductType, bB as DiscountBreakdown, bC as DiscountDetails, bT as DisplayAddOn, bU as DisplayAddOnOption, bR as DisplayCart, bS as DisplayCartItem, x as ELEMENT_TYPES, E as EVENT_TYPES, ec as ElementAppearance, em as ElementEventHandler, H as ElementEventType, z as ElementOptions, D as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, eg as ElementsCustomerInfo, y as ElementsOptions, dP as EnrollAndLinkOrderInput, dS as EnrollAndLinkOrderResult, dM as EnrollmentData, aq as Err, cg as FeeBearerType, F as FetchQuoteInput, ce as FulfillmentLink, cd as FulfillmentStatus, cc as FulfillmentType, e3 as FxQuote, e2 as FxQuoteRequest, e4 as FxRateResponse, r as FxService, dn as GetAvailableSlotsInput, l as GetOrdersOptions, G as GetProductsOptions, bb as GroupPricingBehavior, el as IframeToParentMessage, I as InventoryService, dD as InventorySummary, aG as InventoryType, K as KitchenOrderItem, t as KitchenOrderResult, ah as LINK_MUTATION, ag as LINK_QUERY, bN as LineConfiguration, ci as LineItem, c9 as LineType, dI as LinkData, dR as LinkEnrollResult, L as LinkService, dT as LinkSession, dQ as LinkStatusResult, s as LiteBootstrap, q as LiteService, cT as Location, cN as LocationAppointment, bn as LocationProductPrice, dA as LocationStock, cR as LocationTaxBehavior, cS as LocationTaxOverrides, cW as LocationTimeProfile, d0 as LocationWithDetails, M as MESSAGE_TYPES, ac as MOBILE_MONEY_PROVIDER, dO as MobileMoneyData, e0 as MobileMoneyDetails, a3 as MobileMoneyProvider, al as ORDER_MUTATION, a7 as ORDER_TYPE, eb as ObservabilityHooks, ap as Ok, cj as Order, c8 as OrderChannel, cs as OrderFilter, cf as OrderFulfillmentSummary, cm as OrderGroup, cq as OrderGroupDetails, cn as OrderGroupPayment, cl as OrderGroupPaymentState, cp as OrderGroupPaymentSummary, ck as OrderHistory, ca as OrderLineState, cb as OrderLineStatus, cr as OrderPaymentEvent, O as OrderQueries, co as OrderSplitDetail, c6 as OrderStatus, n as OtpResult, a8 as PAYMENT_METHOD, ak as PAYMENT_MUTATION, aa as PAYMENT_STATE, ab as PICKUP_TIME_TYPE, ek as ParentToIframeMessage, ee as PaymentMethodInfo, c7 as PaymentState, d_ as PickupTime, dZ as PickupTimeType, bm as Price, bu as PriceAdjustment, bx as PriceDecisionPath, bl as PriceEntryType, bw as PricePathTaxInfo, P as PriceQuote, bs as PriceSource, cF as PricingOverrides, $ as ProcessAndResolveOptions, Z as ProcessCheckoutOptions, _ as ProcessCheckoutResult, aL as Product, aZ as ProductAddOn, bo as ProductAvailability, dy as ProductStock, bp as ProductTimeProfile, aF as ProductType, aN as ProductVariant, aS as ProductVariantValue, aM as ProductWithDetails, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, cw as RefundOrderInput, cz as ReminderMethod, cC as ReminderSettings, e5 as RequestContext, e8 as RequestErrorEvent, dW as RequestOtpInput, e6 as RequestStartEvent, e7 as RequestSuccessEvent, dq as RescheduleBookingInput, cI as ResourceAssignment, d9 as ResourceAvailabilityException, d8 as ResourceAvailabilityRule, dd as ResourceType, ao as Result, e9 as RetryEvent, dV as RevokeAllSessionsResult, dU as RevokeSessionResult, cY as Room, aK as SalesChannel, cG as SchedulingMetadata, cJ as SchedulingResult, p as SchedulingService, S as SearchOptions, bD as SelectedAddOnOption, de as Service, d5 as ServiceAvailabilityException, ds as ServiceAvailabilityParams, dt as ServiceAvailabilityResult, d4 as ServiceAvailabilityRule, cZ as ServiceCharge, cE as ServiceNotes, cL as ServiceScheduleRequest, db as ServiceStaffRequirement, cx as ServiceStatus, df as ServiceWithStaff, ea as SessionChangeEvent, dg as Staff, cH as StaffAssignment, d7 as StaffAvailabilityException, d6 as StaffAvailabilityRule, da as StaffBookingProfile, cy as StaffRole, cM as StaffScheduleItem, dw as Stock, dx as StockLevel, du as StockOwnershipType, dv as StockStatus, c_ as StorefrontBootstrap, cX as Table, T as TableInfo, bv as TaxPathComponent, cU as TimeRange, cV as TimeRanges, dh as TimeSlot, c1 as UICart, bV as UICartBusiness, bX as UICartCustomer, bW as UICartLocation, bY as UICartPricing, c2 as UICartResponse, dK as UpdateAddressInput, c4 as UpdateCartItemInput, cu as UpdateOrderStatusInput, U as UpdateProfileInput, aP as VariantAxis, aU as VariantAxisSelection, aR as VariantAxisValue, aQ as VariantAxisWithValues, bG as VariantDetails, b$ as VariantDetailsDTO, aO as VariantDisplayAttribute, aT as VariantLocationAvailability, dz as VariantStock, aH as VariantStrategy, dX as VerifyOtpInput, aD as combine, aE as combineObject, c as createCimplifyClient, w as createElements, as as err, ax as flatMap, aB as fromPromise, k as generateIdempotencyKey, ay as getOrElse, au as isErr, at as isOk, aw as mapError, av as mapResult, ar as ok, aA as toNullable, aC as tryCatch, az as unwrap } from './client-B4etj3AD.mjs';
2
2
  export { QueryBuilder, query } from './advanced.mjs';
3
- export { C as CURRENCY_SYMBOLS, x as FormatCompactOptions, F as FormatPriceOptions, M as MOBILE_MONEY_PROVIDERS, P as PriceInfo, w as ProductWithPrice, T as TaxComponent, v as TaxInfo, n as categorizePaymentError, u as detectMobileMoneyProvider, c as formatMoney, d as formatNumberCompact, f as formatPrice, a as formatPriceAdjustment, b as formatPriceCompact, e as formatProductPrice, i as getBasePrice, g as getCurrencySymbol, k as getDiscountPercentage, h as getDisplayPrice, l as getMarkupPercentage, m as getProductCurrency, j as isOnSale, r as isPaymentStatusFailure, s as isPaymentStatusRequiresAction, t as isPaymentStatusSuccess, o as normalizePaymentResponse, q as normalizeStatusResponse, p as parsePrice } from './index-CJ9GkIXf.mjs';
4
- import { A as ApiError } from './payment-D-u3asA8.mjs';
5
- export { h as AuthorizationType, c as CimplifyError, C as Currency, E as ErrorCode, b as ErrorCodeType, I as InitializePaymentResult, M as Money, a as Pagination, P as PaginationParams, l as Payment, o as PaymentErrorDetails, k as PaymentMethod, g as PaymentMethodType, j as PaymentProcessingState, f as PaymentProvider, m as PaymentResponse, e as PaymentStatus, n as PaymentStatusResponse, S as SubmitAuthorizationInput, i as isCimplifyError, d as isRetryableError } from './payment-D-u3asA8.mjs';
3
+ export { C as CURRENCY_SYMBOLS, x as FormatCompactOptions, F as FormatPriceOptions, M as MOBILE_MONEY_PROVIDERS, P as PriceInfo, w as ProductWithPrice, T as TaxComponent, v as TaxInfo, n as categorizePaymentError, u as detectMobileMoneyProvider, c as formatMoney, d as formatNumberCompact, f as formatPrice, a as formatPriceAdjustment, b as formatPriceCompact, e as formatProductPrice, i as getBasePrice, g as getCurrencySymbol, k as getDiscountPercentage, h as getDisplayPrice, l as getMarkupPercentage, m as getProductCurrency, j as isOnSale, r as isPaymentStatusFailure, s as isPaymentStatusRequiresAction, t as isPaymentStatusSuccess, o as normalizePaymentResponse, q as normalizeStatusResponse, p as parsePrice } from './index-DzNb32O3.mjs';
4
+ import { A as ApiError } from './payment-pjpfIKX8.mjs';
5
+ export { m as AuthorizationType, e as CimplifyError, C as Currency, d as ERROR_HINTS, E as ErrorCode, b as ErrorCodeType, c as ErrorHint, I as InitializePaymentResult, M as Money, a as Pagination, P as PaginationParams, p as Payment, s as PaymentErrorDetails, o as PaymentMethod, l as PaymentMethodType, n as PaymentProcessingState, k as PaymentProvider, q as PaymentResponse, j as PaymentStatus, r as PaymentStatusResponse, S as SubmitAuthorizationInput, f as enrichError, g as getErrorHint, i as isCimplifyError, h as isRetryableError } from './payment-pjpfIKX8.mjs';
6
6
  export { c as AdConfig, e as AdContextValue, d as AdCreative, a as AdPosition, A as AdSlot, b as AdTheme } from './ads-t3FBTU8p.mjs';
7
7
 
8
8
  /** Context sent with every request to scope operations to a specific location/branch */
package/dist/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
- export { ad as AUTHORIZATION_TYPE, ai as AUTH_MUTATION, a2 as AbortablePromise, aV as AddOn, bE as AddOnDetails, b_ as AddOnGroupDetails, aX as AddOnOption, bZ as AddOnOptionDetails, aY as AddOnOptionPrice, aW as AddOnWithOptions, c3 as AddToCartInput, dN as AddressData, ed as AddressInfo, bt as AdjustmentType, ch as AmountToPay, bA as AppliedDiscount, dY as AuthResponse, A as AuthService, m as AuthStatus, ef as AuthenticatedCustomer, eh as AuthenticatedData, dB as AvailabilityCheck, dC as AvailabilityResult, di as AvailableSlot, bz as BenefitType, dl as Booking, dc as BookingRequirementOverride, dk as BookingStatus, dm as BookingWithDetails, cB as BufferTimes, b4 as Bundle, b8 as BundleComponentData, b9 as BundleComponentInfo, b3 as BundlePriceType, b6 as BundleProduct, bJ as BundleSelectionData, bH as BundleSelectionInput, bI as BundleStoredSelection, b5 as BundleSummary, b7 as BundleWithDetails, cQ as Business, d2 as BusinessHours, cP as BusinessPreferences, B as BusinessService, d1 as BusinessSettings, cO as BusinessType, c$ as BusinessWithLocations, a6 as CHECKOUT_MODE, aj as CHECKOUT_MUTATION, a9 as CHECKOUT_STEP, af as CONTACT_TYPE, dr as CancelBookingInput, cv as CancelOrderInput, cD as CancellationPolicy, bO as Cart, bF as CartAddOn, br as CartChannel, bP as CartItem, c0 as CartItemDetails, i as CartOperations, bq as CartStatus, c5 as CartSummary, bQ as CartTotals, b as CatalogueQueries, a_ as Category, d3 as CategoryInfo, a$ as CategorySummary, o as ChangePasswordInput, dp as CheckSlotAvailabilityInput, d$ as CheckoutAddressInfo, e1 as CheckoutCustomerInfo, X as CheckoutFormData, ct as CheckoutInput, J as CheckoutMode, j as CheckoutOperations, N as CheckoutOrderType, V as CheckoutPaymentMethod, Y as CheckoutResult, j as CheckoutService, a0 as CheckoutStatus, a1 as CheckoutStatusContext, W as CheckoutStep, by as ChosenPrice, C as CimplifyClient, a as CimplifyConfig, v as CimplifyElement, u as CimplifyElements, b0 as Collection, b2 as CollectionProduct, b1 as CollectionSummary, bf as ComponentGroup, bg as ComponentGroupWithComponents, bk as ComponentPriceBreakdown, bi as ComponentSelectionInput, bc as ComponentSourceType, bd as Composite, bh as CompositeComponent, bL as CompositePriceBreakdown, bj as CompositePriceResult, ba as CompositePricingMode, bM as CompositeSelectionData, bi as CompositeSelectionInput, bK as CompositeStoredSelection, be as CompositeWithDetails, a5 as ContactType, dJ as CreateAddressInput, dL as CreateMobileMoneyInput, dE as Customer, dF as CustomerAddress, dH as CustomerLinkPreferences, dG as CustomerMobileMoney, cA as CustomerServicePreferences, an as DEFAULT_COUNTRY, am as DEFAULT_CURRENCY, ae as DEVICE_TYPE, dj as DayAvailability, cK as DepositResult, aJ as DepositType, a4 as DeviceType, aI as DigitalProductType, bB as DiscountBreakdown, bC as DiscountDetails, bT as DisplayAddOn, bU as DisplayAddOnOption, bR as DisplayCart, bS as DisplayCartItem, x as ELEMENT_TYPES, E as EVENT_TYPES, ec as ElementAppearance, em as ElementEventHandler, H as ElementEventType, z as ElementOptions, D as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, eg as ElementsCustomerInfo, y as ElementsOptions, dP as EnrollAndLinkOrderInput, dS as EnrollAndLinkOrderResult, dM as EnrollmentData, aq as Err, cg as FeeBearerType, F as FetchQuoteInput, ce as FulfillmentLink, cd as FulfillmentStatus, cc as FulfillmentType, e3 as FxQuote, e2 as FxQuoteRequest, e4 as FxRateResponse, r as FxService, dn as GetAvailableSlotsInput, l as GetOrdersOptions, G as GetProductsOptions, bb as GroupPricingBehavior, el as IframeToParentMessage, I as InventoryService, dD as InventorySummary, aG as InventoryType, K as KitchenOrderItem, t as KitchenOrderResult, ah as LINK_MUTATION, ag as LINK_QUERY, bN as LineConfiguration, ci as LineItem, c9 as LineType, dI as LinkData, dR as LinkEnrollResult, L as LinkService, dT as LinkSession, dQ as LinkStatusResult, s as LiteBootstrap, q as LiteService, cT as Location, cN as LocationAppointment, bn as LocationProductPrice, dA as LocationStock, cR as LocationTaxBehavior, cS as LocationTaxOverrides, cW as LocationTimeProfile, d0 as LocationWithDetails, M as MESSAGE_TYPES, ac as MOBILE_MONEY_PROVIDER, dO as MobileMoneyData, e0 as MobileMoneyDetails, a3 as MobileMoneyProvider, al as ORDER_MUTATION, a7 as ORDER_TYPE, eb as ObservabilityHooks, ap as Ok, cj as Order, c8 as OrderChannel, cs as OrderFilter, cf as OrderFulfillmentSummary, cm as OrderGroup, cq as OrderGroupDetails, cn as OrderGroupPayment, cl as OrderGroupPaymentState, cp as OrderGroupPaymentSummary, ck as OrderHistory, ca as OrderLineState, cb as OrderLineStatus, cr as OrderPaymentEvent, O as OrderQueries, co as OrderSplitDetail, c6 as OrderStatus, n as OtpResult, a8 as PAYMENT_METHOD, ak as PAYMENT_MUTATION, aa as PAYMENT_STATE, ab as PICKUP_TIME_TYPE, ek as ParentToIframeMessage, ee as PaymentMethodInfo, c7 as PaymentState, d_ as PickupTime, dZ as PickupTimeType, bm as Price, bu as PriceAdjustment, bx as PriceDecisionPath, bl as PriceEntryType, bw as PricePathTaxInfo, P as PriceQuote, bs as PriceSource, cF as PricingOverrides, $ as ProcessAndResolveOptions, Z as ProcessCheckoutOptions, _ as ProcessCheckoutResult, aL as Product, aZ as ProductAddOn, bo as ProductAvailability, dy as ProductStock, bp as ProductTimeProfile, aF as ProductType, aN as ProductVariant, aS as ProductVariantValue, aM as ProductWithDetails, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, cw as RefundOrderInput, cz as ReminderMethod, cC as ReminderSettings, e5 as RequestContext, e8 as RequestErrorEvent, dW as RequestOtpInput, e6 as RequestStartEvent, e7 as RequestSuccessEvent, dq as RescheduleBookingInput, cI as ResourceAssignment, d9 as ResourceAvailabilityException, d8 as ResourceAvailabilityRule, dd as ResourceType, ao as Result, e9 as RetryEvent, dV as RevokeAllSessionsResult, dU as RevokeSessionResult, cY as Room, aK as SalesChannel, cG as SchedulingMetadata, cJ as SchedulingResult, p as SchedulingService, S as SearchOptions, bD as SelectedAddOnOption, de as Service, d5 as ServiceAvailabilityException, ds as ServiceAvailabilityParams, dt as ServiceAvailabilityResult, d4 as ServiceAvailabilityRule, cZ as ServiceCharge, cE as ServiceNotes, cL as ServiceScheduleRequest, db as ServiceStaffRequirement, cx as ServiceStatus, df as ServiceWithStaff, ea as SessionChangeEvent, dg as Staff, cH as StaffAssignment, d7 as StaffAvailabilityException, d6 as StaffAvailabilityRule, da as StaffBookingProfile, cy as StaffRole, cM as StaffScheduleItem, dw as Stock, dx as StockLevel, du as StockOwnershipType, dv as StockStatus, c_ as StorefrontBootstrap, cX as Table, T as TableInfo, bv as TaxPathComponent, cU as TimeRange, cV as TimeRanges, dh as TimeSlot, c1 as UICart, bV as UICartBusiness, bX as UICartCustomer, bW as UICartLocation, bY as UICartPricing, c2 as UICartResponse, dK as UpdateAddressInput, c4 as UpdateCartItemInput, cu as UpdateOrderStatusInput, U as UpdateProfileInput, aP as VariantAxis, aU as VariantAxisSelection, aR as VariantAxisValue, aQ as VariantAxisWithValues, bG as VariantDetails, b$ as VariantDetailsDTO, aO as VariantDisplayAttribute, aT as VariantLocationAvailability, dz as VariantStock, aH as VariantStrategy, dX as VerifyOtpInput, aD as combine, aE as combineObject, c as createCimplifyClient, w as createElements, as as err, ax as flatMap, aB as fromPromise, k as generateIdempotencyKey, ay as getOrElse, au as isErr, at as isOk, aw as mapError, av as mapResult, ar as ok, aA as toNullable, aC as tryCatch, az as unwrap } from './client-CjqNbEM6.js';
1
+ export { ad as AUTHORIZATION_TYPE, ai as AUTH_MUTATION, a2 as AbortablePromise, aV as AddOn, bE as AddOnDetails, b_ as AddOnGroupDetails, aX as AddOnOption, bZ as AddOnOptionDetails, aY as AddOnOptionPrice, aW as AddOnWithOptions, c3 as AddToCartInput, dN as AddressData, ed as AddressInfo, bt as AdjustmentType, ch as AmountToPay, bA as AppliedDiscount, dY as AuthResponse, A as AuthService, m as AuthStatus, ef as AuthenticatedCustomer, eh as AuthenticatedData, dB as AvailabilityCheck, dC as AvailabilityResult, di as AvailableSlot, bz as BenefitType, dl as Booking, dc as BookingRequirementOverride, dk as BookingStatus, dm as BookingWithDetails, cB as BufferTimes, b4 as Bundle, b8 as BundleComponentData, b9 as BundleComponentInfo, b3 as BundlePriceType, b6 as BundleProduct, bJ as BundleSelectionData, bH as BundleSelectionInput, bI as BundleStoredSelection, b5 as BundleSummary, b7 as BundleWithDetails, cQ as Business, d2 as BusinessHours, cP as BusinessPreferences, B as BusinessService, d1 as BusinessSettings, cO as BusinessType, c$ as BusinessWithLocations, a6 as CHECKOUT_MODE, aj as CHECKOUT_MUTATION, a9 as CHECKOUT_STEP, af as CONTACT_TYPE, dr as CancelBookingInput, cv as CancelOrderInput, cD as CancellationPolicy, bO as Cart, bF as CartAddOn, br as CartChannel, bP as CartItem, c0 as CartItemDetails, i as CartOperations, bq as CartStatus, c5 as CartSummary, bQ as CartTotals, b as CatalogueQueries, a_ as Category, d3 as CategoryInfo, a$ as CategorySummary, o as ChangePasswordInput, dp as CheckSlotAvailabilityInput, d$ as CheckoutAddressInfo, e1 as CheckoutCustomerInfo, X as CheckoutFormData, ct as CheckoutInput, J as CheckoutMode, j as CheckoutOperations, N as CheckoutOrderType, V as CheckoutPaymentMethod, Y as CheckoutResult, j as CheckoutService, a0 as CheckoutStatus, a1 as CheckoutStatusContext, W as CheckoutStep, by as ChosenPrice, C as CimplifyClient, a as CimplifyConfig, v as CimplifyElement, u as CimplifyElements, b0 as Collection, b2 as CollectionProduct, b1 as CollectionSummary, bf as ComponentGroup, bg as ComponentGroupWithComponents, bk as ComponentPriceBreakdown, bi as ComponentSelectionInput, bc as ComponentSourceType, bd as Composite, bh as CompositeComponent, bL as CompositePriceBreakdown, bj as CompositePriceResult, ba as CompositePricingMode, bM as CompositeSelectionData, bi as CompositeSelectionInput, bK as CompositeStoredSelection, be as CompositeWithDetails, a5 as ContactType, dJ as CreateAddressInput, dL as CreateMobileMoneyInput, dE as Customer, dF as CustomerAddress, dH as CustomerLinkPreferences, dG as CustomerMobileMoney, cA as CustomerServicePreferences, an as DEFAULT_COUNTRY, am as DEFAULT_CURRENCY, ae as DEVICE_TYPE, dj as DayAvailability, cK as DepositResult, aJ as DepositType, a4 as DeviceType, aI as DigitalProductType, bB as DiscountBreakdown, bC as DiscountDetails, bT as DisplayAddOn, bU as DisplayAddOnOption, bR as DisplayCart, bS as DisplayCartItem, x as ELEMENT_TYPES, E as EVENT_TYPES, ec as ElementAppearance, em as ElementEventHandler, H as ElementEventType, z as ElementOptions, D as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, eg as ElementsCustomerInfo, y as ElementsOptions, dP as EnrollAndLinkOrderInput, dS as EnrollAndLinkOrderResult, dM as EnrollmentData, aq as Err, cg as FeeBearerType, F as FetchQuoteInput, ce as FulfillmentLink, cd as FulfillmentStatus, cc as FulfillmentType, e3 as FxQuote, e2 as FxQuoteRequest, e4 as FxRateResponse, r as FxService, dn as GetAvailableSlotsInput, l as GetOrdersOptions, G as GetProductsOptions, bb as GroupPricingBehavior, el as IframeToParentMessage, I as InventoryService, dD as InventorySummary, aG as InventoryType, K as KitchenOrderItem, t as KitchenOrderResult, ah as LINK_MUTATION, ag as LINK_QUERY, bN as LineConfiguration, ci as LineItem, c9 as LineType, dI as LinkData, dR as LinkEnrollResult, L as LinkService, dT as LinkSession, dQ as LinkStatusResult, s as LiteBootstrap, q as LiteService, cT as Location, cN as LocationAppointment, bn as LocationProductPrice, dA as LocationStock, cR as LocationTaxBehavior, cS as LocationTaxOverrides, cW as LocationTimeProfile, d0 as LocationWithDetails, M as MESSAGE_TYPES, ac as MOBILE_MONEY_PROVIDER, dO as MobileMoneyData, e0 as MobileMoneyDetails, a3 as MobileMoneyProvider, al as ORDER_MUTATION, a7 as ORDER_TYPE, eb as ObservabilityHooks, ap as Ok, cj as Order, c8 as OrderChannel, cs as OrderFilter, cf as OrderFulfillmentSummary, cm as OrderGroup, cq as OrderGroupDetails, cn as OrderGroupPayment, cl as OrderGroupPaymentState, cp as OrderGroupPaymentSummary, ck as OrderHistory, ca as OrderLineState, cb as OrderLineStatus, cr as OrderPaymentEvent, O as OrderQueries, co as OrderSplitDetail, c6 as OrderStatus, n as OtpResult, a8 as PAYMENT_METHOD, ak as PAYMENT_MUTATION, aa as PAYMENT_STATE, ab as PICKUP_TIME_TYPE, ek as ParentToIframeMessage, ee as PaymentMethodInfo, c7 as PaymentState, d_ as PickupTime, dZ as PickupTimeType, bm as Price, bu as PriceAdjustment, bx as PriceDecisionPath, bl as PriceEntryType, bw as PricePathTaxInfo, P as PriceQuote, bs as PriceSource, cF as PricingOverrides, $ as ProcessAndResolveOptions, Z as ProcessCheckoutOptions, _ as ProcessCheckoutResult, aL as Product, aZ as ProductAddOn, bo as ProductAvailability, dy as ProductStock, bp as ProductTimeProfile, aF as ProductType, aN as ProductVariant, aS as ProductVariantValue, aM as ProductWithDetails, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, f as QuoteDynamicBuckets, e as QuoteStatus, g as QuoteUiMessage, R as RefreshQuoteInput, h as RefreshQuoteResult, cw as RefundOrderInput, cz as ReminderMethod, cC as ReminderSettings, e5 as RequestContext, e8 as RequestErrorEvent, dW as RequestOtpInput, e6 as RequestStartEvent, e7 as RequestSuccessEvent, dq as RescheduleBookingInput, cI as ResourceAssignment, d9 as ResourceAvailabilityException, d8 as ResourceAvailabilityRule, dd as ResourceType, ao as Result, e9 as RetryEvent, dV as RevokeAllSessionsResult, dU as RevokeSessionResult, cY as Room, aK as SalesChannel, cG as SchedulingMetadata, cJ as SchedulingResult, p as SchedulingService, S as SearchOptions, bD as SelectedAddOnOption, de as Service, d5 as ServiceAvailabilityException, ds as ServiceAvailabilityParams, dt as ServiceAvailabilityResult, d4 as ServiceAvailabilityRule, cZ as ServiceCharge, cE as ServiceNotes, cL as ServiceScheduleRequest, db as ServiceStaffRequirement, cx as ServiceStatus, df as ServiceWithStaff, ea as SessionChangeEvent, dg as Staff, cH as StaffAssignment, d7 as StaffAvailabilityException, d6 as StaffAvailabilityRule, da as StaffBookingProfile, cy as StaffRole, cM as StaffScheduleItem, dw as Stock, dx as StockLevel, du as StockOwnershipType, dv as StockStatus, c_ as StorefrontBootstrap, cX as Table, T as TableInfo, bv as TaxPathComponent, cU as TimeRange, cV as TimeRanges, dh as TimeSlot, c1 as UICart, bV as UICartBusiness, bX as UICartCustomer, bW as UICartLocation, bY as UICartPricing, c2 as UICartResponse, dK as UpdateAddressInput, c4 as UpdateCartItemInput, cu as UpdateOrderStatusInput, U as UpdateProfileInput, aP as VariantAxis, aU as VariantAxisSelection, aR as VariantAxisValue, aQ as VariantAxisWithValues, bG as VariantDetails, b$ as VariantDetailsDTO, aO as VariantDisplayAttribute, aT as VariantLocationAvailability, dz as VariantStock, aH as VariantStrategy, dX as VerifyOtpInput, aD as combine, aE as combineObject, c as createCimplifyClient, w as createElements, as as err, ax as flatMap, aB as fromPromise, k as generateIdempotencyKey, ay as getOrElse, au as isErr, at as isOk, aw as mapError, av as mapResult, ar as ok, aA as toNullable, aC as tryCatch, az as unwrap } from './client-CYVVuP5J.js';
2
2
  export { QueryBuilder, query } from './advanced.js';
3
- export { C as CURRENCY_SYMBOLS, x as FormatCompactOptions, F as FormatPriceOptions, M as MOBILE_MONEY_PROVIDERS, P as PriceInfo, w as ProductWithPrice, T as TaxComponent, v as TaxInfo, n as categorizePaymentError, u as detectMobileMoneyProvider, c as formatMoney, d as formatNumberCompact, f as formatPrice, a as formatPriceAdjustment, b as formatPriceCompact, e as formatProductPrice, i as getBasePrice, g as getCurrencySymbol, k as getDiscountPercentage, h as getDisplayPrice, l as getMarkupPercentage, m as getProductCurrency, j as isOnSale, r as isPaymentStatusFailure, s as isPaymentStatusRequiresAction, t as isPaymentStatusSuccess, o as normalizePaymentResponse, q as normalizeStatusResponse, p as parsePrice } from './index-B5Bj-Ikg.js';
4
- import { A as ApiError } from './payment-D-u3asA8.js';
5
- export { h as AuthorizationType, c as CimplifyError, C as Currency, E as ErrorCode, b as ErrorCodeType, I as InitializePaymentResult, M as Money, a as Pagination, P as PaginationParams, l as Payment, o as PaymentErrorDetails, k as PaymentMethod, g as PaymentMethodType, j as PaymentProcessingState, f as PaymentProvider, m as PaymentResponse, e as PaymentStatus, n as PaymentStatusResponse, S as SubmitAuthorizationInput, i as isCimplifyError, d as isRetryableError } from './payment-D-u3asA8.js';
3
+ export { C as CURRENCY_SYMBOLS, x as FormatCompactOptions, F as FormatPriceOptions, M as MOBILE_MONEY_PROVIDERS, P as PriceInfo, w as ProductWithPrice, T as TaxComponent, v as TaxInfo, n as categorizePaymentError, u as detectMobileMoneyProvider, c as formatMoney, d as formatNumberCompact, f as formatPrice, a as formatPriceAdjustment, b as formatPriceCompact, e as formatProductPrice, i as getBasePrice, g as getCurrencySymbol, k as getDiscountPercentage, h as getDisplayPrice, l as getMarkupPercentage, m as getProductCurrency, j as isOnSale, r as isPaymentStatusFailure, s as isPaymentStatusRequiresAction, t as isPaymentStatusSuccess, o as normalizePaymentResponse, q as normalizeStatusResponse, p as parsePrice } from './index-BOYF-efj.js';
4
+ import { A as ApiError } from './payment-pjpfIKX8.js';
5
+ export { m as AuthorizationType, e as CimplifyError, C as Currency, d as ERROR_HINTS, E as ErrorCode, b as ErrorCodeType, c as ErrorHint, I as InitializePaymentResult, M as Money, a as Pagination, P as PaginationParams, p as Payment, s as PaymentErrorDetails, o as PaymentMethod, l as PaymentMethodType, n as PaymentProcessingState, k as PaymentProvider, q as PaymentResponse, j as PaymentStatus, r as PaymentStatusResponse, S as SubmitAuthorizationInput, f as enrichError, g as getErrorHint, i as isCimplifyError, h as isRetryableError } from './payment-pjpfIKX8.js';
6
6
  export { c as AdConfig, e as AdContextValue, d as AdCreative, a as AdPosition, A as AdSlot, b as AdTheme } from './ads-t3FBTU8p.js';
7
7
 
8
8
  /** Context sent with every request to scope operations to a specific location/branch */