@cimplify/sdk 0.5.0 → 0.5.1

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.
@@ -3166,7 +3166,7 @@ declare class CimplifyClient {
3166
3166
  */
3167
3167
  elements(businessId: string, options?: ElementsOptions): CimplifyElements;
3168
3168
  }
3169
- declare function createCimplifyClient(config: CimplifyConfig): CimplifyClient;
3169
+ declare function createCimplifyClient(config?: CimplifyConfig): CimplifyClient;
3170
3170
 
3171
3171
  type AdSlot = "banner" | "sidebar" | "in-content" | "native" | "footer";
3172
3172
  type AdPosition = "static" | "sticky" | "fixed";
@@ -3166,7 +3166,7 @@ declare class CimplifyClient {
3166
3166
  */
3167
3167
  elements(businessId: string, options?: ElementsOptions): CimplifyElements;
3168
3168
  }
3169
- declare function createCimplifyClient(config: CimplifyConfig): CimplifyClient;
3169
+ declare function createCimplifyClient(config?: CimplifyConfig): CimplifyClient;
3170
3170
 
3171
3171
  type AdSlot = "banner" | "sidebar" | "in-content" | "native" | "footer";
3172
3172
  type AdPosition = "static" | "sticky" | "fixed";
package/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as PaymentErrorDetails, a as PaymentResponse, b as PaymentStatusResponse, A as ApiError } from './ads-BOUIrN73.mjs';
2
- export { a1 as AUTHORIZATION_TYPE, a6 as AUTH_MUTATION, eq as AdConfig, es as AdContextValue, er as AdCreative, eo as AdPosition, en as AdSlot, ep as AdTheme, aS as AddOn, bB as AddOnDetails, bX as AddOnGroupDetails, aU as AddOnOption, bW as AddOnOptionDetails, aV as AddOnOptionPrice, aT as AddOnWithOptions, b$ as AddToCartInput, dS as AddressData, ef as AddressInfo, bq as AdjustmentType, cd as AmountToPay, bx as AppliedDiscount, e1 as AuthResponse, j as AuthService, k as AuthStatus, eh as AuthenticatedData, cN as AuthorizationType, dG as AvailabilityCheck, dH as AvailabilityResult, dn as AvailableSlot, bw as BenefitType, dr as Booking, dh as BookingRequirementOverride, dq as BookingStatus, ds as BookingWithDetails, cx as BufferTimes, b1 as Bundle, b5 as BundleComponentData, b6 as BundleComponentInfo, b0 as BundlePriceType, b3 as BundleProduct, bG as BundleSelectionData, bE as BundleSelectionInput, bF as BundleStoredSelection, b2 as BundleSummary, b4 as BundleWithDetails, cV as Business, d7 as BusinessHours, cU as BusinessPreferences, B as BusinessService, d6 as BusinessSettings, cT as BusinessType, d4 as BusinessWithLocations, W as CHECKOUT_MODE, a7 as CHECKOUT_MUTATION, Z as CHECKOUT_STEP, a3 as CONTACT_TYPE, dw as CancelBookingInput, cr as CancelOrderInput, cz as CancellationPolicy, bL as Cart, bC as CartAddOn, bo as CartChannel, bM as CartItem, bZ as CartItemDetails, f as CartOperations, bn as CartStatus, c1 as CartSummary, bN as CartTotals, e as CatalogueQueries, aX as Category, d8 as CategoryInfo, aY as CategorySummary, m as ChangePasswordInput, du as CheckSlotAvailabilityInput, e4 as CheckoutAddressInfo, e6 as CheckoutCustomerInfo, J as CheckoutFormData, cp as CheckoutInput, z as CheckoutMode, g as CheckoutOperations, D as CheckoutOrderType, F as CheckoutPaymentMethod, N as CheckoutResult, g as CheckoutService, H as CheckoutStep, bv as ChosenPrice, C as CimplifyClient, d as CimplifyConfig, s as CimplifyElement, r as CimplifyElements, ai as CimplifyError, aZ as Collection, a$ as CollectionProduct, a_ as CollectionSummary, bc as ComponentGroup, bd as ComponentGroupWithComponents, bh as ComponentPriceBreakdown, bf as ComponentSelectionInput, b9 as ComponentSourceType, ba as Composite, be as CompositeComponent, bI as CompositePriceBreakdown, bg as CompositePriceResult, b7 as CompositePricingMode, bJ as CompositeSelectionData, bf as CompositeSelectionInput, bH as CompositeStoredSelection, bb as CompositeWithDetails, V as ContactType, dO as CreateAddressInput, dQ as CreateMobileMoneyInput, ad as Currency, dJ as Customer, dK as CustomerAddress, dM as CustomerLinkPreferences, dL as CustomerMobileMoney, cw as CustomerServicePreferences, ab as DEFAULT_COUNTRY, aa as DEFAULT_CURRENCY, a2 as DEVICE_TYPE, dp as DayAvailability, cG as DepositResult, aG as DepositType, R as DeviceType, aF as DigitalProductType, by as DiscountBreakdown, bz as DiscountDetails, bQ as DisplayAddOn, bR as DisplayAddOnOption, bO as DisplayCart, bP as DisplayCartItem, u as ELEMENT_TYPES, E as EVENT_TYPES, ee as ElementAppearance, em as ElementEventHandler, y as ElementEventType, w as ElementOptions, x as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, v as ElementsOptions, dU as EnrollAndLinkOrderInput, dX as EnrollAndLinkOrderResult, dR as EnrollmentData, an as Err, ag as ErrorCode, ah as ErrorCodeType, cc as FeeBearerType, ca as FulfillmentLink, c9 as FulfillmentStatus, c8 as FulfillmentType, dt as GetAvailableSlotsInput, i as GetOrdersOptions, G as GetProductsOptions, b8 as GroupPricingBehavior, el as IframeToParentMessage, cR as InitializePaymentResult, I as InventoryService, dI as InventorySummary, aD as InventoryType, K as KitchenOrderItem, q as KitchenOrderResult, a5 as LINK_MUTATION, a4 as LINK_QUERY, bK as LineConfiguration, ce as LineItem, c5 as LineType, dN as LinkData, dW as LinkEnrollResult, L as LinkService, dY as LinkSession, dV as LinkStatusResult, p as LiteBootstrap, o as LiteService, cY as Location, cJ as LocationAppointment, bk as LocationProductPrice, dF as LocationStock, cW as LocationTaxBehavior, cX as LocationTaxOverrides, c$ as LocationTimeProfile, d5 as LocationWithDetails, M as MESSAGE_TYPES, a0 as MOBILE_MONEY_PROVIDER, dT as MobileMoneyData, e5 as MobileMoneyDetails, Q as MobileMoneyProvider, ac as Money, a9 as ORDER_MUTATION, X as ORDER_TYPE, ed as ObservabilityHooks, am as Ok, cf as Order, c4 as OrderChannel, co as OrderFilter, cb as OrderFulfillmentSummary, ci as OrderGroup, cm as OrderGroupDetails, cj as OrderGroupPayment, ch as OrderGroupPaymentState, cl as OrderGroupPaymentSummary, cg as OrderHistory, c6 as OrderLineState, c7 as OrderLineStatus, cn as OrderPaymentEvent, O as OrderQueries, ck as OrderSplitDetail, c2 as OrderStatus, l as OtpResult, Y as PAYMENT_METHOD, a8 as PAYMENT_MUTATION, _ as PAYMENT_STATE, $ as PICKUP_TIME_TYPE, af as Pagination, ae as PaginationParams, ek as ParentToIframeMessage, cQ as Payment, cP as PaymentMethod, eg as PaymentMethodInfo, cM as PaymentMethodType, cO as PaymentProcessingState, cL as PaymentProvider, c3 as PaymentState, cK as PaymentStatus, e3 as PickupTime, e2 as PickupTimeType, bj as Price, br as PriceAdjustment, bu as PriceDecisionPath, bi as PriceEntryType, bt as PricePathTaxInfo, bp as PriceSource, cB as PricingOverrides, aI as Product, aW as ProductAddOn, bl as ProductAvailability, dD as ProductStock, bm as ProductTimeProfile, aC as ProductType, aK as ProductVariant, aP as ProductVariantValue, aJ as ProductWithDetails, cs as RefundOrderInput, cv as ReminderMethod, cy as ReminderSettings, e7 as RequestContext, ea as RequestErrorEvent, d$ as RequestOtpInput, e8 as RequestStartEvent, e9 as RequestSuccessEvent, dv as RescheduleBookingInput, cE as ResourceAssignment, de as ResourceAvailabilityException, dd as ResourceAvailabilityRule, di as ResourceType, al as Result, eb as RetryEvent, d_ as RevokeAllSessionsResult, dZ as RevokeSessionResult, d1 as Room, aH as SalesChannel, cC as SchedulingMetadata, cF as SchedulingResult, n as SchedulingService, S as SearchOptions, bA as SelectedAddOnOption, dj as Service, da as ServiceAvailabilityException, dx as ServiceAvailabilityParams, dy as ServiceAvailabilityResult, d9 as ServiceAvailabilityRule, d2 as ServiceCharge, cA as ServiceNotes, cH as ServiceScheduleRequest, dg as ServiceStaffRequirement, ct as ServiceStatus, dk as ServiceWithStaff, ec as SessionChangeEvent, dl as Staff, cD as StaffAssignment, dc as StaffAvailabilityException, db as StaffAvailabilityRule, df as StaffBookingProfile, cu as StaffRole, cI as StaffScheduleItem, dB as Stock, dC as StockLevel, dz as StockOwnershipType, dA as StockStatus, d3 as StorefrontBootstrap, cS as SubmitAuthorizationInput, d0 as Table, T as TableInfo, bs as TaxPathComponent, cZ as TimeRange, c_ as TimeRanges, dm as TimeSlot, b_ as UICart, bS as UICartBusiness, bU as UICartCustomer, bT as UICartLocation, bV as UICartPricing, dP as UpdateAddressInput, c0 as UpdateCartItemInput, cq as UpdateOrderStatusInput, U as UpdateProfileInput, aM as VariantAxis, aR as VariantAxisSelection, aO as VariantAxisValue, aN as VariantAxisWithValues, bD as VariantDetails, bY as VariantDetailsDTO, aL as VariantDisplayAttribute, aQ as VariantLocationAvailability, dE as VariantStock, aE as VariantStrategy, e0 as VerifyOtpInput, aA as combine, aB as combineObject, c as createCimplifyClient, t as createElements, ap as err, au as flatMap, ay as fromPromise, h as generateIdempotencyKey, av as getOrElse, aj as isCimplifyError, ar as isErr, aq as isOk, ak as isRetryableError, at as mapError, as as mapResult, ao as ok, ax as toNullable, az as tryCatch, aw as unwrap } from './ads-BOUIrN73.mjs';
1
+ import { P as PaymentErrorDetails, a as PaymentResponse, b as PaymentStatusResponse, A as ApiError } from './ads-CsufxnHH.mjs';
2
+ export { a1 as AUTHORIZATION_TYPE, a6 as AUTH_MUTATION, eq as AdConfig, es as AdContextValue, er as AdCreative, eo as AdPosition, en as AdSlot, ep as AdTheme, aS as AddOn, bB as AddOnDetails, bX as AddOnGroupDetails, aU as AddOnOption, bW as AddOnOptionDetails, aV as AddOnOptionPrice, aT as AddOnWithOptions, b$ as AddToCartInput, dS as AddressData, ef as AddressInfo, bq as AdjustmentType, cd as AmountToPay, bx as AppliedDiscount, e1 as AuthResponse, j as AuthService, k as AuthStatus, eh as AuthenticatedData, cN as AuthorizationType, dG as AvailabilityCheck, dH as AvailabilityResult, dn as AvailableSlot, bw as BenefitType, dr as Booking, dh as BookingRequirementOverride, dq as BookingStatus, ds as BookingWithDetails, cx as BufferTimes, b1 as Bundle, b5 as BundleComponentData, b6 as BundleComponentInfo, b0 as BundlePriceType, b3 as BundleProduct, bG as BundleSelectionData, bE as BundleSelectionInput, bF as BundleStoredSelection, b2 as BundleSummary, b4 as BundleWithDetails, cV as Business, d7 as BusinessHours, cU as BusinessPreferences, B as BusinessService, d6 as BusinessSettings, cT as BusinessType, d4 as BusinessWithLocations, W as CHECKOUT_MODE, a7 as CHECKOUT_MUTATION, Z as CHECKOUT_STEP, a3 as CONTACT_TYPE, dw as CancelBookingInput, cr as CancelOrderInput, cz as CancellationPolicy, bL as Cart, bC as CartAddOn, bo as CartChannel, bM as CartItem, bZ as CartItemDetails, f as CartOperations, bn as CartStatus, c1 as CartSummary, bN as CartTotals, e as CatalogueQueries, aX as Category, d8 as CategoryInfo, aY as CategorySummary, m as ChangePasswordInput, du as CheckSlotAvailabilityInput, e4 as CheckoutAddressInfo, e6 as CheckoutCustomerInfo, J as CheckoutFormData, cp as CheckoutInput, z as CheckoutMode, g as CheckoutOperations, D as CheckoutOrderType, F as CheckoutPaymentMethod, N as CheckoutResult, g as CheckoutService, H as CheckoutStep, bv as ChosenPrice, C as CimplifyClient, d as CimplifyConfig, s as CimplifyElement, r as CimplifyElements, ai as CimplifyError, aZ as Collection, a$ as CollectionProduct, a_ as CollectionSummary, bc as ComponentGroup, bd as ComponentGroupWithComponents, bh as ComponentPriceBreakdown, bf as ComponentSelectionInput, b9 as ComponentSourceType, ba as Composite, be as CompositeComponent, bI as CompositePriceBreakdown, bg as CompositePriceResult, b7 as CompositePricingMode, bJ as CompositeSelectionData, bf as CompositeSelectionInput, bH as CompositeStoredSelection, bb as CompositeWithDetails, V as ContactType, dO as CreateAddressInput, dQ as CreateMobileMoneyInput, ad as Currency, dJ as Customer, dK as CustomerAddress, dM as CustomerLinkPreferences, dL as CustomerMobileMoney, cw as CustomerServicePreferences, ab as DEFAULT_COUNTRY, aa as DEFAULT_CURRENCY, a2 as DEVICE_TYPE, dp as DayAvailability, cG as DepositResult, aG as DepositType, R as DeviceType, aF as DigitalProductType, by as DiscountBreakdown, bz as DiscountDetails, bQ as DisplayAddOn, bR as DisplayAddOnOption, bO as DisplayCart, bP as DisplayCartItem, u as ELEMENT_TYPES, E as EVENT_TYPES, ee as ElementAppearance, em as ElementEventHandler, y as ElementEventType, w as ElementOptions, x as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, v as ElementsOptions, dU as EnrollAndLinkOrderInput, dX as EnrollAndLinkOrderResult, dR as EnrollmentData, an as Err, ag as ErrorCode, ah as ErrorCodeType, cc as FeeBearerType, ca as FulfillmentLink, c9 as FulfillmentStatus, c8 as FulfillmentType, dt as GetAvailableSlotsInput, i as GetOrdersOptions, G as GetProductsOptions, b8 as GroupPricingBehavior, el as IframeToParentMessage, cR as InitializePaymentResult, I as InventoryService, dI as InventorySummary, aD as InventoryType, K as KitchenOrderItem, q as KitchenOrderResult, a5 as LINK_MUTATION, a4 as LINK_QUERY, bK as LineConfiguration, ce as LineItem, c5 as LineType, dN as LinkData, dW as LinkEnrollResult, L as LinkService, dY as LinkSession, dV as LinkStatusResult, p as LiteBootstrap, o as LiteService, cY as Location, cJ as LocationAppointment, bk as LocationProductPrice, dF as LocationStock, cW as LocationTaxBehavior, cX as LocationTaxOverrides, c$ as LocationTimeProfile, d5 as LocationWithDetails, M as MESSAGE_TYPES, a0 as MOBILE_MONEY_PROVIDER, dT as MobileMoneyData, e5 as MobileMoneyDetails, Q as MobileMoneyProvider, ac as Money, a9 as ORDER_MUTATION, X as ORDER_TYPE, ed as ObservabilityHooks, am as Ok, cf as Order, c4 as OrderChannel, co as OrderFilter, cb as OrderFulfillmentSummary, ci as OrderGroup, cm as OrderGroupDetails, cj as OrderGroupPayment, ch as OrderGroupPaymentState, cl as OrderGroupPaymentSummary, cg as OrderHistory, c6 as OrderLineState, c7 as OrderLineStatus, cn as OrderPaymentEvent, O as OrderQueries, ck as OrderSplitDetail, c2 as OrderStatus, l as OtpResult, Y as PAYMENT_METHOD, a8 as PAYMENT_MUTATION, _ as PAYMENT_STATE, $ as PICKUP_TIME_TYPE, af as Pagination, ae as PaginationParams, ek as ParentToIframeMessage, cQ as Payment, cP as PaymentMethod, eg as PaymentMethodInfo, cM as PaymentMethodType, cO as PaymentProcessingState, cL as PaymentProvider, c3 as PaymentState, cK as PaymentStatus, e3 as PickupTime, e2 as PickupTimeType, bj as Price, br as PriceAdjustment, bu as PriceDecisionPath, bi as PriceEntryType, bt as PricePathTaxInfo, bp as PriceSource, cB as PricingOverrides, aI as Product, aW as ProductAddOn, bl as ProductAvailability, dD as ProductStock, bm as ProductTimeProfile, aC as ProductType, aK as ProductVariant, aP as ProductVariantValue, aJ as ProductWithDetails, cs as RefundOrderInput, cv as ReminderMethod, cy as ReminderSettings, e7 as RequestContext, ea as RequestErrorEvent, d$ as RequestOtpInput, e8 as RequestStartEvent, e9 as RequestSuccessEvent, dv as RescheduleBookingInput, cE as ResourceAssignment, de as ResourceAvailabilityException, dd as ResourceAvailabilityRule, di as ResourceType, al as Result, eb as RetryEvent, d_ as RevokeAllSessionsResult, dZ as RevokeSessionResult, d1 as Room, aH as SalesChannel, cC as SchedulingMetadata, cF as SchedulingResult, n as SchedulingService, S as SearchOptions, bA as SelectedAddOnOption, dj as Service, da as ServiceAvailabilityException, dx as ServiceAvailabilityParams, dy as ServiceAvailabilityResult, d9 as ServiceAvailabilityRule, d2 as ServiceCharge, cA as ServiceNotes, cH as ServiceScheduleRequest, dg as ServiceStaffRequirement, ct as ServiceStatus, dk as ServiceWithStaff, ec as SessionChangeEvent, dl as Staff, cD as StaffAssignment, dc as StaffAvailabilityException, db as StaffAvailabilityRule, df as StaffBookingProfile, cu as StaffRole, cI as StaffScheduleItem, dB as Stock, dC as StockLevel, dz as StockOwnershipType, dA as StockStatus, d3 as StorefrontBootstrap, cS as SubmitAuthorizationInput, d0 as Table, T as TableInfo, bs as TaxPathComponent, cZ as TimeRange, c_ as TimeRanges, dm as TimeSlot, b_ as UICart, bS as UICartBusiness, bU as UICartCustomer, bT as UICartLocation, bV as UICartPricing, dP as UpdateAddressInput, c0 as UpdateCartItemInput, cq as UpdateOrderStatusInput, U as UpdateProfileInput, aM as VariantAxis, aR as VariantAxisSelection, aO as VariantAxisValue, aN as VariantAxisWithValues, bD as VariantDetails, bY as VariantDetailsDTO, aL as VariantDisplayAttribute, aQ as VariantLocationAvailability, dE as VariantStock, aE as VariantStrategy, e0 as VerifyOtpInput, aA as combine, aB as combineObject, c as createCimplifyClient, t as createElements, ap as err, au as flatMap, ay as fromPromise, h as generateIdempotencyKey, av as getOrElse, aj as isCimplifyError, ar as isErr, aq as isOk, ak as isRetryableError, at as mapError, as as mapResult, ao as ok, ax as toNullable, az as tryCatch, aw as unwrap } from './ads-CsufxnHH.mjs';
3
3
 
4
4
  type Operator = "==" | "!=" | ">" | "<" | ">=" | "<=" | "contains" | "startsWith";
5
5
  type SortOrder = "asc" | "desc";
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { P as PaymentErrorDetails, a as PaymentResponse, b as PaymentStatusResponse, A as ApiError } from './ads-BOUIrN73.js';
2
- export { a1 as AUTHORIZATION_TYPE, a6 as AUTH_MUTATION, eq as AdConfig, es as AdContextValue, er as AdCreative, eo as AdPosition, en as AdSlot, ep as AdTheme, aS as AddOn, bB as AddOnDetails, bX as AddOnGroupDetails, aU as AddOnOption, bW as AddOnOptionDetails, aV as AddOnOptionPrice, aT as AddOnWithOptions, b$ as AddToCartInput, dS as AddressData, ef as AddressInfo, bq as AdjustmentType, cd as AmountToPay, bx as AppliedDiscount, e1 as AuthResponse, j as AuthService, k as AuthStatus, eh as AuthenticatedData, cN as AuthorizationType, dG as AvailabilityCheck, dH as AvailabilityResult, dn as AvailableSlot, bw as BenefitType, dr as Booking, dh as BookingRequirementOverride, dq as BookingStatus, ds as BookingWithDetails, cx as BufferTimes, b1 as Bundle, b5 as BundleComponentData, b6 as BundleComponentInfo, b0 as BundlePriceType, b3 as BundleProduct, bG as BundleSelectionData, bE as BundleSelectionInput, bF as BundleStoredSelection, b2 as BundleSummary, b4 as BundleWithDetails, cV as Business, d7 as BusinessHours, cU as BusinessPreferences, B as BusinessService, d6 as BusinessSettings, cT as BusinessType, d4 as BusinessWithLocations, W as CHECKOUT_MODE, a7 as CHECKOUT_MUTATION, Z as CHECKOUT_STEP, a3 as CONTACT_TYPE, dw as CancelBookingInput, cr as CancelOrderInput, cz as CancellationPolicy, bL as Cart, bC as CartAddOn, bo as CartChannel, bM as CartItem, bZ as CartItemDetails, f as CartOperations, bn as CartStatus, c1 as CartSummary, bN as CartTotals, e as CatalogueQueries, aX as Category, d8 as CategoryInfo, aY as CategorySummary, m as ChangePasswordInput, du as CheckSlotAvailabilityInput, e4 as CheckoutAddressInfo, e6 as CheckoutCustomerInfo, J as CheckoutFormData, cp as CheckoutInput, z as CheckoutMode, g as CheckoutOperations, D as CheckoutOrderType, F as CheckoutPaymentMethod, N as CheckoutResult, g as CheckoutService, H as CheckoutStep, bv as ChosenPrice, C as CimplifyClient, d as CimplifyConfig, s as CimplifyElement, r as CimplifyElements, ai as CimplifyError, aZ as Collection, a$ as CollectionProduct, a_ as CollectionSummary, bc as ComponentGroup, bd as ComponentGroupWithComponents, bh as ComponentPriceBreakdown, bf as ComponentSelectionInput, b9 as ComponentSourceType, ba as Composite, be as CompositeComponent, bI as CompositePriceBreakdown, bg as CompositePriceResult, b7 as CompositePricingMode, bJ as CompositeSelectionData, bf as CompositeSelectionInput, bH as CompositeStoredSelection, bb as CompositeWithDetails, V as ContactType, dO as CreateAddressInput, dQ as CreateMobileMoneyInput, ad as Currency, dJ as Customer, dK as CustomerAddress, dM as CustomerLinkPreferences, dL as CustomerMobileMoney, cw as CustomerServicePreferences, ab as DEFAULT_COUNTRY, aa as DEFAULT_CURRENCY, a2 as DEVICE_TYPE, dp as DayAvailability, cG as DepositResult, aG as DepositType, R as DeviceType, aF as DigitalProductType, by as DiscountBreakdown, bz as DiscountDetails, bQ as DisplayAddOn, bR as DisplayAddOnOption, bO as DisplayCart, bP as DisplayCartItem, u as ELEMENT_TYPES, E as EVENT_TYPES, ee as ElementAppearance, em as ElementEventHandler, y as ElementEventType, w as ElementOptions, x as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, v as ElementsOptions, dU as EnrollAndLinkOrderInput, dX as EnrollAndLinkOrderResult, dR as EnrollmentData, an as Err, ag as ErrorCode, ah as ErrorCodeType, cc as FeeBearerType, ca as FulfillmentLink, c9 as FulfillmentStatus, c8 as FulfillmentType, dt as GetAvailableSlotsInput, i as GetOrdersOptions, G as GetProductsOptions, b8 as GroupPricingBehavior, el as IframeToParentMessage, cR as InitializePaymentResult, I as InventoryService, dI as InventorySummary, aD as InventoryType, K as KitchenOrderItem, q as KitchenOrderResult, a5 as LINK_MUTATION, a4 as LINK_QUERY, bK as LineConfiguration, ce as LineItem, c5 as LineType, dN as LinkData, dW as LinkEnrollResult, L as LinkService, dY as LinkSession, dV as LinkStatusResult, p as LiteBootstrap, o as LiteService, cY as Location, cJ as LocationAppointment, bk as LocationProductPrice, dF as LocationStock, cW as LocationTaxBehavior, cX as LocationTaxOverrides, c$ as LocationTimeProfile, d5 as LocationWithDetails, M as MESSAGE_TYPES, a0 as MOBILE_MONEY_PROVIDER, dT as MobileMoneyData, e5 as MobileMoneyDetails, Q as MobileMoneyProvider, ac as Money, a9 as ORDER_MUTATION, X as ORDER_TYPE, ed as ObservabilityHooks, am as Ok, cf as Order, c4 as OrderChannel, co as OrderFilter, cb as OrderFulfillmentSummary, ci as OrderGroup, cm as OrderGroupDetails, cj as OrderGroupPayment, ch as OrderGroupPaymentState, cl as OrderGroupPaymentSummary, cg as OrderHistory, c6 as OrderLineState, c7 as OrderLineStatus, cn as OrderPaymentEvent, O as OrderQueries, ck as OrderSplitDetail, c2 as OrderStatus, l as OtpResult, Y as PAYMENT_METHOD, a8 as PAYMENT_MUTATION, _ as PAYMENT_STATE, $ as PICKUP_TIME_TYPE, af as Pagination, ae as PaginationParams, ek as ParentToIframeMessage, cQ as Payment, cP as PaymentMethod, eg as PaymentMethodInfo, cM as PaymentMethodType, cO as PaymentProcessingState, cL as PaymentProvider, c3 as PaymentState, cK as PaymentStatus, e3 as PickupTime, e2 as PickupTimeType, bj as Price, br as PriceAdjustment, bu as PriceDecisionPath, bi as PriceEntryType, bt as PricePathTaxInfo, bp as PriceSource, cB as PricingOverrides, aI as Product, aW as ProductAddOn, bl as ProductAvailability, dD as ProductStock, bm as ProductTimeProfile, aC as ProductType, aK as ProductVariant, aP as ProductVariantValue, aJ as ProductWithDetails, cs as RefundOrderInput, cv as ReminderMethod, cy as ReminderSettings, e7 as RequestContext, ea as RequestErrorEvent, d$ as RequestOtpInput, e8 as RequestStartEvent, e9 as RequestSuccessEvent, dv as RescheduleBookingInput, cE as ResourceAssignment, de as ResourceAvailabilityException, dd as ResourceAvailabilityRule, di as ResourceType, al as Result, eb as RetryEvent, d_ as RevokeAllSessionsResult, dZ as RevokeSessionResult, d1 as Room, aH as SalesChannel, cC as SchedulingMetadata, cF as SchedulingResult, n as SchedulingService, S as SearchOptions, bA as SelectedAddOnOption, dj as Service, da as ServiceAvailabilityException, dx as ServiceAvailabilityParams, dy as ServiceAvailabilityResult, d9 as ServiceAvailabilityRule, d2 as ServiceCharge, cA as ServiceNotes, cH as ServiceScheduleRequest, dg as ServiceStaffRequirement, ct as ServiceStatus, dk as ServiceWithStaff, ec as SessionChangeEvent, dl as Staff, cD as StaffAssignment, dc as StaffAvailabilityException, db as StaffAvailabilityRule, df as StaffBookingProfile, cu as StaffRole, cI as StaffScheduleItem, dB as Stock, dC as StockLevel, dz as StockOwnershipType, dA as StockStatus, d3 as StorefrontBootstrap, cS as SubmitAuthorizationInput, d0 as Table, T as TableInfo, bs as TaxPathComponent, cZ as TimeRange, c_ as TimeRanges, dm as TimeSlot, b_ as UICart, bS as UICartBusiness, bU as UICartCustomer, bT as UICartLocation, bV as UICartPricing, dP as UpdateAddressInput, c0 as UpdateCartItemInput, cq as UpdateOrderStatusInput, U as UpdateProfileInput, aM as VariantAxis, aR as VariantAxisSelection, aO as VariantAxisValue, aN as VariantAxisWithValues, bD as VariantDetails, bY as VariantDetailsDTO, aL as VariantDisplayAttribute, aQ as VariantLocationAvailability, dE as VariantStock, aE as VariantStrategy, e0 as VerifyOtpInput, aA as combine, aB as combineObject, c as createCimplifyClient, t as createElements, ap as err, au as flatMap, ay as fromPromise, h as generateIdempotencyKey, av as getOrElse, aj as isCimplifyError, ar as isErr, aq as isOk, ak as isRetryableError, at as mapError, as as mapResult, ao as ok, ax as toNullable, az as tryCatch, aw as unwrap } from './ads-BOUIrN73.js';
1
+ import { P as PaymentErrorDetails, a as PaymentResponse, b as PaymentStatusResponse, A as ApiError } from './ads-CsufxnHH.js';
2
+ export { a1 as AUTHORIZATION_TYPE, a6 as AUTH_MUTATION, eq as AdConfig, es as AdContextValue, er as AdCreative, eo as AdPosition, en as AdSlot, ep as AdTheme, aS as AddOn, bB as AddOnDetails, bX as AddOnGroupDetails, aU as AddOnOption, bW as AddOnOptionDetails, aV as AddOnOptionPrice, aT as AddOnWithOptions, b$ as AddToCartInput, dS as AddressData, ef as AddressInfo, bq as AdjustmentType, cd as AmountToPay, bx as AppliedDiscount, e1 as AuthResponse, j as AuthService, k as AuthStatus, eh as AuthenticatedData, cN as AuthorizationType, dG as AvailabilityCheck, dH as AvailabilityResult, dn as AvailableSlot, bw as BenefitType, dr as Booking, dh as BookingRequirementOverride, dq as BookingStatus, ds as BookingWithDetails, cx as BufferTimes, b1 as Bundle, b5 as BundleComponentData, b6 as BundleComponentInfo, b0 as BundlePriceType, b3 as BundleProduct, bG as BundleSelectionData, bE as BundleSelectionInput, bF as BundleStoredSelection, b2 as BundleSummary, b4 as BundleWithDetails, cV as Business, d7 as BusinessHours, cU as BusinessPreferences, B as BusinessService, d6 as BusinessSettings, cT as BusinessType, d4 as BusinessWithLocations, W as CHECKOUT_MODE, a7 as CHECKOUT_MUTATION, Z as CHECKOUT_STEP, a3 as CONTACT_TYPE, dw as CancelBookingInput, cr as CancelOrderInput, cz as CancellationPolicy, bL as Cart, bC as CartAddOn, bo as CartChannel, bM as CartItem, bZ as CartItemDetails, f as CartOperations, bn as CartStatus, c1 as CartSummary, bN as CartTotals, e as CatalogueQueries, aX as Category, d8 as CategoryInfo, aY as CategorySummary, m as ChangePasswordInput, du as CheckSlotAvailabilityInput, e4 as CheckoutAddressInfo, e6 as CheckoutCustomerInfo, J as CheckoutFormData, cp as CheckoutInput, z as CheckoutMode, g as CheckoutOperations, D as CheckoutOrderType, F as CheckoutPaymentMethod, N as CheckoutResult, g as CheckoutService, H as CheckoutStep, bv as ChosenPrice, C as CimplifyClient, d as CimplifyConfig, s as CimplifyElement, r as CimplifyElements, ai as CimplifyError, aZ as Collection, a$ as CollectionProduct, a_ as CollectionSummary, bc as ComponentGroup, bd as ComponentGroupWithComponents, bh as ComponentPriceBreakdown, bf as ComponentSelectionInput, b9 as ComponentSourceType, ba as Composite, be as CompositeComponent, bI as CompositePriceBreakdown, bg as CompositePriceResult, b7 as CompositePricingMode, bJ as CompositeSelectionData, bf as CompositeSelectionInput, bH as CompositeStoredSelection, bb as CompositeWithDetails, V as ContactType, dO as CreateAddressInput, dQ as CreateMobileMoneyInput, ad as Currency, dJ as Customer, dK as CustomerAddress, dM as CustomerLinkPreferences, dL as CustomerMobileMoney, cw as CustomerServicePreferences, ab as DEFAULT_COUNTRY, aa as DEFAULT_CURRENCY, a2 as DEVICE_TYPE, dp as DayAvailability, cG as DepositResult, aG as DepositType, R as DeviceType, aF as DigitalProductType, by as DiscountBreakdown, bz as DiscountDetails, bQ as DisplayAddOn, bR as DisplayAddOnOption, bO as DisplayCart, bP as DisplayCartItem, u as ELEMENT_TYPES, E as EVENT_TYPES, ee as ElementAppearance, em as ElementEventHandler, y as ElementEventType, w as ElementOptions, x as ElementType, ei as ElementsCheckoutData, ej as ElementsCheckoutResult, v as ElementsOptions, dU as EnrollAndLinkOrderInput, dX as EnrollAndLinkOrderResult, dR as EnrollmentData, an as Err, ag as ErrorCode, ah as ErrorCodeType, cc as FeeBearerType, ca as FulfillmentLink, c9 as FulfillmentStatus, c8 as FulfillmentType, dt as GetAvailableSlotsInput, i as GetOrdersOptions, G as GetProductsOptions, b8 as GroupPricingBehavior, el as IframeToParentMessage, cR as InitializePaymentResult, I as InventoryService, dI as InventorySummary, aD as InventoryType, K as KitchenOrderItem, q as KitchenOrderResult, a5 as LINK_MUTATION, a4 as LINK_QUERY, bK as LineConfiguration, ce as LineItem, c5 as LineType, dN as LinkData, dW as LinkEnrollResult, L as LinkService, dY as LinkSession, dV as LinkStatusResult, p as LiteBootstrap, o as LiteService, cY as Location, cJ as LocationAppointment, bk as LocationProductPrice, dF as LocationStock, cW as LocationTaxBehavior, cX as LocationTaxOverrides, c$ as LocationTimeProfile, d5 as LocationWithDetails, M as MESSAGE_TYPES, a0 as MOBILE_MONEY_PROVIDER, dT as MobileMoneyData, e5 as MobileMoneyDetails, Q as MobileMoneyProvider, ac as Money, a9 as ORDER_MUTATION, X as ORDER_TYPE, ed as ObservabilityHooks, am as Ok, cf as Order, c4 as OrderChannel, co as OrderFilter, cb as OrderFulfillmentSummary, ci as OrderGroup, cm as OrderGroupDetails, cj as OrderGroupPayment, ch as OrderGroupPaymentState, cl as OrderGroupPaymentSummary, cg as OrderHistory, c6 as OrderLineState, c7 as OrderLineStatus, cn as OrderPaymentEvent, O as OrderQueries, ck as OrderSplitDetail, c2 as OrderStatus, l as OtpResult, Y as PAYMENT_METHOD, a8 as PAYMENT_MUTATION, _ as PAYMENT_STATE, $ as PICKUP_TIME_TYPE, af as Pagination, ae as PaginationParams, ek as ParentToIframeMessage, cQ as Payment, cP as PaymentMethod, eg as PaymentMethodInfo, cM as PaymentMethodType, cO as PaymentProcessingState, cL as PaymentProvider, c3 as PaymentState, cK as PaymentStatus, e3 as PickupTime, e2 as PickupTimeType, bj as Price, br as PriceAdjustment, bu as PriceDecisionPath, bi as PriceEntryType, bt as PricePathTaxInfo, bp as PriceSource, cB as PricingOverrides, aI as Product, aW as ProductAddOn, bl as ProductAvailability, dD as ProductStock, bm as ProductTimeProfile, aC as ProductType, aK as ProductVariant, aP as ProductVariantValue, aJ as ProductWithDetails, cs as RefundOrderInput, cv as ReminderMethod, cy as ReminderSettings, e7 as RequestContext, ea as RequestErrorEvent, d$ as RequestOtpInput, e8 as RequestStartEvent, e9 as RequestSuccessEvent, dv as RescheduleBookingInput, cE as ResourceAssignment, de as ResourceAvailabilityException, dd as ResourceAvailabilityRule, di as ResourceType, al as Result, eb as RetryEvent, d_ as RevokeAllSessionsResult, dZ as RevokeSessionResult, d1 as Room, aH as SalesChannel, cC as SchedulingMetadata, cF as SchedulingResult, n as SchedulingService, S as SearchOptions, bA as SelectedAddOnOption, dj as Service, da as ServiceAvailabilityException, dx as ServiceAvailabilityParams, dy as ServiceAvailabilityResult, d9 as ServiceAvailabilityRule, d2 as ServiceCharge, cA as ServiceNotes, cH as ServiceScheduleRequest, dg as ServiceStaffRequirement, ct as ServiceStatus, dk as ServiceWithStaff, ec as SessionChangeEvent, dl as Staff, cD as StaffAssignment, dc as StaffAvailabilityException, db as StaffAvailabilityRule, df as StaffBookingProfile, cu as StaffRole, cI as StaffScheduleItem, dB as Stock, dC as StockLevel, dz as StockOwnershipType, dA as StockStatus, d3 as StorefrontBootstrap, cS as SubmitAuthorizationInput, d0 as Table, T as TableInfo, bs as TaxPathComponent, cZ as TimeRange, c_ as TimeRanges, dm as TimeSlot, b_ as UICart, bS as UICartBusiness, bU as UICartCustomer, bT as UICartLocation, bV as UICartPricing, dP as UpdateAddressInput, c0 as UpdateCartItemInput, cq as UpdateOrderStatusInput, U as UpdateProfileInput, aM as VariantAxis, aR as VariantAxisSelection, aO as VariantAxisValue, aN as VariantAxisWithValues, bD as VariantDetails, bY as VariantDetailsDTO, aL as VariantDisplayAttribute, aQ as VariantLocationAvailability, dE as VariantStock, aE as VariantStrategy, e0 as VerifyOtpInput, aA as combine, aB as combineObject, c as createCimplifyClient, t as createElements, ap as err, au as flatMap, ay as fromPromise, h as generateIdempotencyKey, av as getOrElse, aj as isCimplifyError, ar as isErr, aq as isOk, ak as isRetryableError, at as mapError, as as mapResult, ao as ok, ax as toNullable, az as tryCatch, aw as unwrap } from './ads-CsufxnHH.js';
3
3
 
4
4
  type Operator = "==" | "!=" | ">" | "<" | ">=" | "<=" | "contains" | "startsWith";
5
5
  type SortOrder = "asc" | "desc";
package/dist/index.js CHANGED
@@ -1642,11 +1642,19 @@ function deriveUrls() {
1642
1642
  linkApiUrl: "https://api.cimplify.io"
1643
1643
  };
1644
1644
  }
1645
+ function getEnvPublicKey() {
1646
+ try {
1647
+ const env = globalThis.process;
1648
+ return env?.env.NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY || void 0;
1649
+ } catch {
1650
+ return void 0;
1651
+ }
1652
+ }
1645
1653
  var CimplifyClient = class {
1646
1654
  constructor(config = {}) {
1647
1655
  this.accessToken = null;
1648
1656
  this.inflightRequests = /* @__PURE__ */ new Map();
1649
- this.publicKey = config.publicKey || "";
1657
+ this.publicKey = config.publicKey || getEnvPublicKey() || "";
1650
1658
  const urls = deriveUrls();
1651
1659
  this.baseUrl = urls.baseUrl;
1652
1660
  this.linkApiUrl = urls.linkApiUrl;
@@ -1656,6 +1664,11 @@ var CimplifyClient = class {
1656
1664
  this.retryDelay = config.retryDelay ?? DEFAULT_RETRY_DELAY_MS;
1657
1665
  this.hooks = config.hooks ?? {};
1658
1666
  this.accessToken = this.loadAccessToken();
1667
+ if (!this.publicKey) {
1668
+ console.warn(
1669
+ '[Cimplify] No public key found. Set NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY in your environment, or pass { publicKey: "pk_..." } to createCimplifyClient().'
1670
+ );
1671
+ }
1659
1672
  }
1660
1673
  /** @deprecated Use getAccessToken() instead */
1661
1674
  getSessionToken() {
@@ -1996,7 +2009,7 @@ var CimplifyClient = class {
1996
2009
  return createElements(this, businessId, options);
1997
2010
  }
1998
2011
  };
1999
- function createCimplifyClient(config) {
2012
+ function createCimplifyClient(config = {}) {
2000
2013
  return new CimplifyClient(config);
2001
2014
  }
2002
2015
 
package/dist/index.mjs CHANGED
@@ -1640,11 +1640,19 @@ function deriveUrls() {
1640
1640
  linkApiUrl: "https://api.cimplify.io"
1641
1641
  };
1642
1642
  }
1643
+ function getEnvPublicKey() {
1644
+ try {
1645
+ const env = globalThis.process;
1646
+ return env?.env.NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY || void 0;
1647
+ } catch {
1648
+ return void 0;
1649
+ }
1650
+ }
1643
1651
  var CimplifyClient = class {
1644
1652
  constructor(config = {}) {
1645
1653
  this.accessToken = null;
1646
1654
  this.inflightRequests = /* @__PURE__ */ new Map();
1647
- this.publicKey = config.publicKey || "";
1655
+ this.publicKey = config.publicKey || getEnvPublicKey() || "";
1648
1656
  const urls = deriveUrls();
1649
1657
  this.baseUrl = urls.baseUrl;
1650
1658
  this.linkApiUrl = urls.linkApiUrl;
@@ -1654,6 +1662,11 @@ var CimplifyClient = class {
1654
1662
  this.retryDelay = config.retryDelay ?? DEFAULT_RETRY_DELAY_MS;
1655
1663
  this.hooks = config.hooks ?? {};
1656
1664
  this.accessToken = this.loadAccessToken();
1665
+ if (!this.publicKey) {
1666
+ console.warn(
1667
+ '[Cimplify] No public key found. Set NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY in your environment, or pass { publicKey: "pk_..." } to createCimplifyClient().'
1668
+ );
1669
+ }
1657
1670
  }
1658
1671
  /** @deprecated Use getAccessToken() instead */
1659
1672
  getSessionToken() {
@@ -1994,7 +2007,7 @@ var CimplifyClient = class {
1994
2007
  return createElements(this, businessId, options);
1995
2008
  }
1996
2009
  };
1997
- function createCimplifyClient(config) {
2010
+ function createCimplifyClient(config = {}) {
1998
2011
  return new CimplifyClient(config);
1999
2012
  }
2000
2013
 
package/dist/react.d.mts CHANGED
@@ -1,5 +1,5 @@
1
- import { en as AdSlot, eo as AdPosition, es as AdContextValue, r as CimplifyElements, C as CimplifyClient, v as ElementsOptions, eh as AuthenticatedData, ef as AddressInfo, eg as PaymentMethodInfo, ej as ElementsCheckoutResult } from './ads-BOUIrN73.mjs';
2
- export { eq as AdConfig } from './ads-BOUIrN73.mjs';
1
+ import { en as AdSlot, eo as AdPosition, es as AdContextValue, r as CimplifyElements, C as CimplifyClient, v as ElementsOptions, eh as AuthenticatedData, ef as AddressInfo, eg as PaymentMethodInfo, ej as ElementsCheckoutResult } from './ads-CsufxnHH.mjs';
2
+ export { eq as AdConfig } from './ads-CsufxnHH.mjs';
3
3
  import React, { ReactNode } from 'react';
4
4
 
5
5
  interface UserIdentity {
package/dist/react.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { en as AdSlot, eo as AdPosition, es as AdContextValue, r as CimplifyElements, C as CimplifyClient, v as ElementsOptions, eh as AuthenticatedData, ef as AddressInfo, eg as PaymentMethodInfo, ej as ElementsCheckoutResult } from './ads-BOUIrN73.js';
2
- export { eq as AdConfig } from './ads-BOUIrN73.js';
1
+ import { en as AdSlot, eo as AdPosition, es as AdContextValue, r as CimplifyElements, C as CimplifyClient, v as ElementsOptions, eh as AuthenticatedData, ef as AddressInfo, eg as PaymentMethodInfo, ej as ElementsCheckoutResult } from './ads-CsufxnHH.js';
2
+ export { eq as AdConfig } from './ads-CsufxnHH.js';
3
3
  import React, { ReactNode } from 'react';
4
4
 
5
5
  interface UserIdentity {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cimplify/sdk",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "Cimplify Commerce SDK for storefronts",
5
5
  "keywords": [
6
6
  "cimplify",