@joai/sdk 13.0.1 → 13.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as _$_joai_core0 from "@joai/core";
2
- import { Address, AddressCreatePayload, AddressInput, AddressType, AddressUpdatePayload, Affiliate, AffiliateTier, Agent, AgentActionHistoryEntry, AgentPrivate, AgentSettings, AgentTrustedActionRule, AiCostsResponse, Alert, AnalyticsConfiguration, ApiToken, AppEnv, AppIngestion, AppendKvEntryResult, AppointmentAvailability, AppointmentBooking, AppointmentPolicy, AppointmentPolicyUpsert, AppointmentRequest, Artifact, ArtifactCreatePayload, ArtifactDeliverPayload, ArtifactDelivery, ArtifactDeliveryPreview, ArtifactStatus, ArtifactType, ArtifactUpdatePayload, AuthUser, AuthUser as AuthUser$1, Automation, AutomationActionInput, AutomationAudiencePreview, AutomationCreatePayload, AutomationEnrollment, AutomationStats, AutomationUpdatePayload, Blueprint, BlueprintSettings, BrandBackend, BrandSiteConfig, BrandSourceConfig, CalendarFeed, CalendarFeedInput, CalendarFeedSyncResult, CalendarStatus, Campaign, CampaignAudiencePreview, CampaignAudiencePreviewPayload, CampaignCreatePayload, CampaignRecipient, CampaignRecipientStatus, CampaignSendTestDraftPayload, CampaignStats, CampaignUpdatePayload, Card, Cart, Cart as Cart$1, CartLine, ChangelogEntry, Character, CheckoutSnapshot, CheckoutSnapshot as CheckoutSnapshot$1, CheckoutSnapshotRequest, ClientProposal, CommissionAgreement, Configuration, Contact, ContactActivity, ContactCreatePayload, ContactFormData, ContactRelation, ContactRelationPayload, ContactRelationUpdatePayload, Content, ContentValue, ContentVersion, Contract, ContractCategoryName, ContractVersion, Coupon, CouponCondition, CouponRestrictedItem, CreateContentInput, CreateHookPayload, CreateHookPayload as CreateHookPayload$1, CreateInboundHookPayload, CreateInternalHookPayload, CreateKvFieldPayload, CreateWarpLinkedHookPayload, CreateWebHookPayload, Document, EarnResponse, Element, ElementSpec, ElementType, ElementVariation, EmbedStatus, Entity, Flow, FollowListParams, FollowPayload, Fulfillment, FulfillmentLocation, FulfillmentLocation as FulfillmentLocation$1, FulfillmentMethod, GamificationData, Goal, GoalCreatePayload, GuestBuyer, GuestBuyer as GuestBuyer$1, HashidInput, Hook, Hook as Hook$1, HookSample, HookSample as HookSample$1, HookTrigger, HookTriggerCondition, HookTriggerInput, IAppResponse, IHttpService, IRequestOptions, IdentifiedSiteEvent, Inquiry, InquiryType, Install, InstallClaimPayload, InstallOptOutPayload, InstallRegisterPayload, Integration, IntegrationType, Intent, Item, ItemCreatePayload, ItemUpdatePayload, JsonValue, KvEntryPayload, KvField, KvFieldWithEntries, Link, LinkCreatePayload, LinkStats, LinkUpdatePayload, LinkVariation, LinkVariationBatchCreatePayload, LinkVariationCreatePayload, LoyaltyAccount, LoyaltyCollectPointInput, LoyaltyCollectResponse, LoyaltyJoinResponse, LoyaltyMember, LoyaltyProgram, LoyaltyPromotion, LoyaltyReward, LoyaltyTier, LoyaltyTransaction, LoyaltyWalletAccount, McpToolCall, Media, MediaAspectRatio, Meeting, MeetingJoinInfo, MeetingSpeakerAssignment, MeetingSummary, Memory, Message, MetricSource, MetricsResult, Mission, MissionCreatePayload, Notification, NotificationChannel, NotificationSetting, OfficeSnapshot, Order, Order as Order$1, OrderContext, OrderPriceMode, OrderPriceMode as OrderPriceMode$1, OrderStatus, OrderStatus as OrderStatus$1, OrderType, PaginatedResponse, Pass, PatchContentInput, PaymentAccount, PaymentAccountOnboarding, PaymentProvider, Plan, PlanFeature, Product, Product as Product$1, ProductDetailSection, ProductRelation, ProductVariation, ProgramSettings, Project, ProjectExportResponse, ProjectInputAssistIntent, ProjectInputAssistResponse, ProjectMutation, ProjectOutputPreset, ProjectOutputType, ProjectStudioHistoryEntry, Proposal, ProposalAction, ProposalCreateInput, ProposalPollOption, ProposalPricing, PublicFormResults, PurchaseResult, RampProviderInfo, Reactions, RedeemResponse, Reminder, Return, ReturnStatus, Room, RoomKind, Segment, SegmentCountPayload, SegmentCountResult, SegmentCreatePayload, Service, SetKvEntryResult, SharedArtifact, SharedProposal, SharedSocialPost, ShippingCarrierOption, ShippingRate, ShippingRate as ShippingRate$1, ShippingZone, Shortcut, Site, SiteBrand, SiteType, Skill, SkillScopeValue, SocialAuthProvider, SocialBot, SocialPlatform, SocialPost, SocialPostConnection, SocialPostCreatePayload, SocialPostGenerateCaptionPayload, SocialPostGeneratedCaption, SocialPostPlatform, SocialPostScheduleSlot, SocialPostStatus, SocialPostUpdatePayload, StampResponse, StoreAgent, StoreData, StorePriceTier, StorePurchaseResult, Subscription, Swarm, Tag, TagType, Task, TaxClass, Team, TeamAccessConfig, TeamCategory, TeamEarning, TeamEarningsBalance, TeamFeature, TeamFeatureUsage, TeamMember, TeamMeta, TeamOrderStats, TeamPayout, TeamPayoutAddress, TeamPrivate, TeamUsage, TemplateMode, TemplateOverrides, TemplateSpec, TerminalConnectionToken, TerminalPaymentIntent, ToggleKvFieldResult, TranslatableValue, Update, UpdateCreatePayload, UpdateRelation, UpdateStats, UpdateType, UpdateUpdatePayload, Upgrade, UpgradeStatus, UserPrivate, UserRole, UserSettings, VolumePrice, WarpBackend, WarpBackendStatus, WarpExecutionBackend, WebHookTriggerEvent, WorkspaceCloudFile, WorkspaceInfo, XIntegrationStatus } from "@joai/core";
2
+ import { Address, AddressCreatePayload, AddressInput, AddressInput as AddressInput$1, AddressType, AddressUpdatePayload, Affiliate, AffiliateTier, Agent, AgentActionHistoryEntry, AgentPrivate, AgentSettings, AgentTrustedActionRule, AiCostsResponse, Alert, AnalyticsConfiguration, ApiToken, AppEnv, AppEnv as AppEnv$1, AppIngestion, AppendKvEntryResult, AppointmentAvailability, AppointmentAvailabilitySlot, AppointmentBooking, AppointmentPolicy, AppointmentPolicyUpsert, AppointmentRequest, Artifact, ArtifactCreatePayload, ArtifactDeliverPayload, ArtifactDelivery, ArtifactDeliveryPreview, ArtifactStatus, ArtifactType, ArtifactUpdatePayload, AuthUser, AuthUser as AuthUser$1, Automation, AutomationActionInput, AutomationAudiencePreview, AutomationCreatePayload, AutomationEnrollment, AutomationStats, AutomationUpdatePayload, Blueprint, BlueprintSettings, BrandBackend, BrandSiteConfig, BrandSourceConfig, CalendarFeed, CalendarFeedInput, CalendarFeedSyncResult, CalendarStatus, Campaign, CampaignAudiencePreview, CampaignAudiencePreviewPayload, CampaignCreatePayload, CampaignRecipient, CampaignRecipientStatus, CampaignSendTestDraftPayload, CampaignStats, CampaignUpdatePayload, Card, Cart, Cart as Cart$1, CartItem, CartLine, ChangelogEntry, Character, CheckoutSnapshot, CheckoutSnapshot as CheckoutSnapshot$1, CheckoutSnapshotRequest, CheckoutSnapshotRequest as CheckoutSnapshotRequest$1, ClientProposal, CommissionAgreement, Configuration, Contact, ContactActivity, ContactCreatePayload, ContactFormData, ContactRelation, ContactRelationPayload, ContactRelationUpdatePayload, Content, ContentValue, ContentVersion, Contract, ContractCategoryName, ContractVersion, Coupon, CouponCondition, CouponRestrictedItem, CreateContentInput, CreateHookPayload, CreateHookPayload as CreateHookPayload$1, CreateInboundHookPayload, CreateInternalHookPayload, CreateKvFieldPayload, CreateWarpLinkedHookPayload, CreateWebHookPayload, Document, EarnResponse, Element, ElementSpec, ElementType, ElementVariation, EmbedStatus, Entity, Flow, FollowListParams, FollowPayload, Fulfillment, FulfillmentLocation, FulfillmentLocation as FulfillmentLocation$1, FulfillmentMethod, GamificationData, Goal, GoalCreatePayload, GuestBuyer, GuestBuyer as GuestBuyer$1, HashidInput, HashidInput as HashidInput$1, Hook, Hook as Hook$1, HookSample, HookSample as HookSample$1, HookTrigger, HookTriggerCondition, HookTriggerInput, IAppResponse, IAppResponse as IAppResponse$1, IHttpService, IRequestOptions, IdentifiedSiteEvent, Inquiry, InquiryType, Install, InstallClaimPayload, InstallOptOutPayload, InstallRegisterPayload, Integration, IntegrationType, Intent, Item, ItemCreatePayload, ItemUpdatePayload, JsonValue, KvEntryPayload, KvField, KvFieldWithEntries, Link, LinkCreatePayload, LinkStats, LinkUpdatePayload, LinkVariation, LinkVariationBatchCreatePayload, LinkVariationCreatePayload, LoyaltyAccount, LoyaltyCollectPointInput, LoyaltyCollectResponse, LoyaltyJoinResponse, LoyaltyMember, LoyaltyProgram, LoyaltyPromotion, LoyaltyReward, LoyaltyTier, LoyaltyTransaction, LoyaltyWalletAccount, McpToolCall, Media, MediaAspectRatio, Meeting, MeetingJoinInfo, MeetingSpeakerAssignment, MeetingSummary, Memory, Message, MetricSource, MetricsResult, Mission, MissionCreatePayload, Notification, NotificationChannel, NotificationSetting, OfficeSnapshot, Order, Order as Order$1, OrderContext, OrderPriceMode, OrderPriceMode as OrderPriceMode$1, OrderStatus, OrderStatus as OrderStatus$1, OrderType, PaginatedResponse, Pass, PatchContentInput, PaymentAccount, PaymentAccountOnboarding, PaymentProvider, Plan, PlanFeature, Product, Product as Product$1, ProductDetailSection, ProductDetailSection as ProductDetailSection$1, ProductDetailText, ProductRelation, ProductRelationType, ProductVariation, ProgramSettings, Project, ProjectExportResponse, ProjectInputAssistIntent, ProjectInputAssistResponse, ProjectMutation, ProjectOutputPreset, ProjectOutputType, ProjectStudioHistoryEntry, Proposal, ProposalAction, ProposalCreateInput, ProposalPollOption, ProposalPricing, PublicFormResults, PurchaseResult, RampProviderInfo, Reactions, RedeemResponse, Reminder, Return, ReturnStatus, Room, RoomKind, Segment, SegmentCountPayload, SegmentCountResult, SegmentCreatePayload, Service, SetKvEntryResult, SharedArtifact, SharedProposal, SharedSocialPost, ShippingCarrierOption, ShippingRate, ShippingRate as ShippingRate$1, ShippingZone, Shortcut, Site, SiteBrand, SiteType, Skill, SkillScopeValue, SocialAuthProvider, SocialBot, SocialPlatform, SocialPost, SocialPostConnection, SocialPostCreatePayload, SocialPostGenerateCaptionPayload, SocialPostGeneratedCaption, SocialPostPlatform, SocialPostScheduleSlot, SocialPostStatus, SocialPostUpdatePayload, StampResponse, StoreAgent, StoreData, StorePriceTier, StorePurchaseResult, Subscription, Swarm, Tag, TagType, Task, TaxClass, Team, TeamAccessConfig, TeamCategory, TeamEarning, TeamEarningsBalance, TeamFeature, TeamFeatureUsage, TeamMember, TeamMeta, TeamOrderStats, TeamPayout, TeamPayoutAddress, TeamPrivate, TeamUsage, TemplateMode, TemplateOverrides, TemplateSpec, TerminalConnectionToken, TerminalPaymentIntent, ToggleKvFieldResult, TranslatableValue, TranslatableValue as TranslatableValue$1, Update, UpdateCreatePayload, UpdateRelation, UpdateStats, UpdateType, UpdateUpdatePayload, Upgrade, UpgradeStatus, UserPrivate, UserRole, UserSettings, VolumePrice, WarpBackend, WarpBackendStatus, WarpExecutionBackend, WebHookTriggerEvent, WorkspaceCloudFile, WorkspaceInfo, XIntegrationStatus } from "@joai/core";
3
3
  import { WarpChainName, WarpClient, WarpLocale, WarpText, WarpWalletProvider } from "@joai/warps";
4
4
 
5
5
  //#region src/resources/agents.d.ts
@@ -60,15 +60,15 @@ type AddressQuery = {
60
60
  declare class AddressesResource {
61
61
  private readonly http;
62
62
  constructor(http: IHttpService);
63
- list(params?: AddressQuery): Promise<IAppResponse<Address[]>>;
64
- get(params?: Omit<AddressQuery, 'type'>): Promise<IAppResponse<Address | null>>;
65
- create(data: AddressCreatePayload): Promise<IAppResponse<Address>>;
66
- update(id: string, data: AddressUpdatePayload): Promise<IAppResponse<Address>>;
67
- delete(id: string): Promise<IAppResponse<void>>;
63
+ list(params?: AddressQuery): Promise<IAppResponse$1<Address[]>>;
64
+ get(params?: Omit<AddressQuery, 'type'>): Promise<IAppResponse$1<Address | null>>;
65
+ create(data: AddressCreatePayload): Promise<IAppResponse$1<Address>>;
66
+ update(id: string, data: AddressUpdatePayload): Promise<IAppResponse$1<Address>>;
67
+ delete(id: string): Promise<IAppResponse$1<void>>;
68
68
  }
69
69
  //#endregion
70
70
  //#region src/commerce/checkout.d.ts
71
- type PlaceCheckoutOrderRequest = CheckoutSnapshotRequest & {
71
+ type PlaceCheckoutOrderRequest = CheckoutSnapshotRequest$1 & {
72
72
  guest?: GuestBuyer;
73
73
  notes?: string;
74
74
  scheduledAt?: string;
@@ -92,7 +92,7 @@ declare class CheckoutResource {
92
92
  discount: number;
93
93
  eligibleSubtotal: number;
94
94
  }>>;
95
- snapshot(team: string, data: CheckoutSnapshotRequest): Promise<_$_joai_core0.IAppResponse<_$_joai_core0.CheckoutSnapshot>>;
95
+ snapshot(team: string, data: CheckoutSnapshotRequest$1): Promise<_$_joai_core0.IAppResponse<_$_joai_core0.CheckoutSnapshot>>;
96
96
  placeOrder(team: string, data: PlaceCheckoutOrderRequest): Promise<_$_joai_core0.IAppResponse<Order$1>>;
97
97
  locations(team: string): Promise<_$_joai_core0.IAppResponse<FulfillmentLocation$1[]>>;
98
98
  shippingRates(team: string, data: {
@@ -187,11 +187,11 @@ declare class ShippingResource {
187
187
  constructor(http: IHttpService);
188
188
  zones(team: string): Promise<_$_joai_core0.IAppResponse<ShippingZone[]>>;
189
189
  createZone(team: string, data: ShippingZoneInput): Promise<_$_joai_core0.IAppResponse<ShippingZone>>;
190
- updateZone(team: string, zoneId: HashidInput, data: ShippingZoneInput): Promise<_$_joai_core0.IAppResponse<ShippingZone>>;
191
- deleteZone(team: string, zoneId: HashidInput): Promise<_$_joai_core0.IAppResponse<void>>;
192
- createRate(team: string, zoneId: HashidInput, data: ShippingRateInput): Promise<_$_joai_core0.IAppResponse<ShippingRate$1>>;
193
- updateRate(team: string, zoneId: HashidInput, rateId: HashidInput, data: ShippingRateInput): Promise<_$_joai_core0.IAppResponse<ShippingRate$1>>;
194
- deleteRate(team: string, zoneId: HashidInput, rateId: HashidInput): Promise<_$_joai_core0.IAppResponse<void>>;
190
+ updateZone(team: string, zoneId: HashidInput$1, data: ShippingZoneInput): Promise<_$_joai_core0.IAppResponse<ShippingZone>>;
191
+ deleteZone(team: string, zoneId: HashidInput$1): Promise<_$_joai_core0.IAppResponse<void>>;
192
+ createRate(team: string, zoneId: HashidInput$1, data: ShippingRateInput): Promise<_$_joai_core0.IAppResponse<ShippingRate$1>>;
193
+ updateRate(team: string, zoneId: HashidInput$1, rateId: HashidInput$1, data: ShippingRateInput): Promise<_$_joai_core0.IAppResponse<ShippingRate$1>>;
194
+ deleteRate(team: string, zoneId: HashidInput$1, rateId: HashidInput$1): Promise<_$_joai_core0.IAppResponse<void>>;
195
195
  locations(team: string): Promise<_$_joai_core0.IAppResponse<FulfillmentLocation$1[]>>;
196
196
  createLocation(team: string, data: FulfillmentLocationInput): Promise<_$_joai_core0.IAppResponse<FulfillmentLocation$1>>;
197
197
  updateLocation(team: string, locationId: string, data: FulfillmentLocationInput): Promise<_$_joai_core0.IAppResponse<FulfillmentLocation$1>>;
@@ -222,7 +222,7 @@ type GuestOrderAccess = {
222
222
  type GuestCheckoutDraft<TCart = unknown> = {
223
223
  cart: TCart;
224
224
  fulfillmentMethod: FulfillmentMethod;
225
- shippingRateId: HashidInput | null;
225
+ shippingRateId: HashidInput$1 | null;
226
226
  fulfillmentLocationId: string | null;
227
227
  couponCode?: string | null; /** Pickup appointment start (ISO-8601), required for pickup confirm. */
228
228
  scheduledAt?: string | null; /** Bookable service slug when the shop has more than one. */
@@ -276,7 +276,7 @@ type GuestCheckoutCartItem = {
276
276
  };
277
277
  type GuestCheckoutState<TCart = GuestCheckoutCartItem[]> = GuestCheckoutDraft<TCart> & {
278
278
  identity: GuestBuyer$1;
279
- address: AddressInput;
279
+ address: AddressInput$1;
280
280
  };
281
281
  type GuestCheckoutErrorCode = 'empty_cart' | 'missing_identity' | 'missing_pickup_phone' | 'missing_scheduled_at' | 'incomplete_shipping_address' | 'pickup_unavailable' | 'missing_shipping_rate' | 'rates_failed' | 'snapshot_failed' | 'review_required' | 'terms_required' | 'review_expired' | 'order_failed' | 'payment_failed';
282
282
  declare class GuestCheckoutError extends Error {
@@ -292,8 +292,8 @@ type GuestCheckoutClient = {
292
292
  zipCode?: string;
293
293
  };
294
294
  items: GuestCheckoutCartItem[];
295
- }): Promise<IAppResponse<ShippingRate$1[]>>;
296
- snapshot(team: string, data: CheckoutSnapshotRequest): Promise<IAppResponse<CheckoutSnapshot$1>>;
295
+ }): Promise<IAppResponse$1<ShippingRate$1[]>>;
296
+ snapshot(team: string, data: CheckoutSnapshotRequest$1): Promise<IAppResponse$1<CheckoutSnapshot$1>>;
297
297
  };
298
298
  };
299
299
  orders: {
@@ -307,8 +307,8 @@ type GuestCheckoutClient = {
307
307
  scheduledAt?: string;
308
308
  serviceSlug?: string;
309
309
  sendConfirmation?: boolean;
310
- }): Promise<IAppResponse<Order$1>>;
311
- pay(id: string, provider?: PaymentProvider, accessToken?: string): Promise<IAppResponse<{
310
+ }): Promise<IAppResponse$1<Order$1>>;
311
+ pay(id: string, provider?: PaymentProvider, accessToken?: string): Promise<IAppResponse$1<{
312
312
  url: string;
313
313
  }>>;
314
314
  };
@@ -324,7 +324,7 @@ declare const assertGuestPickupSlotReady: (state: GuestCheckoutState) => void;
324
324
  declare const buildGuestCheckoutSnapshotRequest: (state: GuestCheckoutState, options?: {
325
325
  shippingRates?: ShippingRate$1[];
326
326
  pickupLocationIds?: string[];
327
- }) => CheckoutSnapshotRequest;
327
+ }) => CheckoutSnapshotRequest$1;
328
328
  type GuestCheckoutSnapshotResult = {
329
329
  snapshot: CheckoutSnapshot$1 & {
330
330
  accessToken: string;
@@ -392,7 +392,7 @@ type GuestCouponClient = {
392
392
  validateCoupon(team: string, data: {
393
393
  couponCode: string;
394
394
  items: GuestCheckoutCartItem[];
395
- }): Promise<IAppResponse<GuestCouponPreview>>;
395
+ }): Promise<IAppResponse$1<GuestCouponPreview>>;
396
396
  };
397
397
  };
398
398
  };
@@ -737,19 +737,19 @@ type AuthPortalSessionResponse = {
737
737
  declare class AuthResource {
738
738
  private http;
739
739
  constructor(http: IHttpService);
740
- sendCode(data: AuthSendCodeRequest): Promise<IAppResponse<void>>;
741
- confirmCode(data: AuthConfirmCodeRequest): Promise<IAppResponse<AuthConfirmCodeResponse>>;
740
+ sendCode(data: AuthSendCodeRequest): Promise<IAppResponse$1<void>>;
741
+ confirmCode(data: AuthConfirmCodeRequest): Promise<IAppResponse$1<AuthConfirmCodeResponse>>;
742
742
  /** Requests a magic link. `options.team` is the team slug used to brand the email. */
743
743
  requestEmail(email: string, redirect?: string, options?: {
744
744
  team?: string;
745
- }): Promise<IAppResponse<AuthLoginResponse>>;
746
- loginWithSocialAccessToken(provider: NativeSocialAuthProvider, accessToken: string): Promise<IAppResponse<AuthLoginResponse>>;
747
- exchangeNativeSession(token: string): Promise<IAppResponse<AuthNativeSessionResponse>>;
748
- me(): Promise<IAppResponse<AuthUser$1>>;
749
- logout(): Promise<IAppResponse<void>>;
750
- createApiToken(): Promise<IAppResponse<AuthApiTokenResponse>>;
751
- createPortalSession(redirect: string): Promise<IAppResponse<AuthPortalSessionResponse>>;
752
- verifyWallet(accessToken: string, withMobileApiToken?: boolean): Promise<IAppResponse<UserPrivate>>;
745
+ }): Promise<IAppResponse$1<AuthLoginResponse>>;
746
+ loginWithSocialAccessToken(provider: NativeSocialAuthProvider, accessToken: string): Promise<IAppResponse$1<AuthLoginResponse>>;
747
+ exchangeNativeSession(token: string): Promise<IAppResponse$1<AuthNativeSessionResponse>>;
748
+ me(): Promise<IAppResponse$1<AuthUser$1>>;
749
+ logout(): Promise<IAppResponse$1<void>>;
750
+ createApiToken(): Promise<IAppResponse$1<AuthApiTokenResponse>>;
751
+ createPortalSession(redirect: string): Promise<IAppResponse$1<AuthPortalSessionResponse>>;
752
+ verifyWallet(accessToken: string, withMobileApiToken?: boolean): Promise<IAppResponse$1<UserPrivate>>;
753
753
  }
754
754
  //#endregion
755
755
  //#region src/resources/billing.d.ts
@@ -854,7 +854,7 @@ declare class CartsResource {
854
854
  //#region src/resources/coupons.d.ts
855
855
  type CouponPayload = {
856
856
  code: string;
857
- name?: TranslatableValue;
857
+ name?: TranslatableValue$1;
858
858
  percent?: number | null;
859
859
  amount?: number | null;
860
860
  price?: number | null;
@@ -1406,7 +1406,7 @@ declare class MetricsResource {
1406
1406
  declare class AnalyticsResource {
1407
1407
  private readonly http;
1408
1408
  private readonly env;
1409
- constructor(http: IHttpService, env: AppEnv);
1409
+ constructor(http: IHttpService, env: AppEnv$1);
1410
1410
  getConfiguration(siteKey: string): Promise<_$_joai_core0.IAppResponse<AnalyticsConfiguration>>;
1411
1411
  getScriptSnippet(siteKey: string): string;
1412
1412
  /** Records a CRM conversion for the caller's authenticated contact only. */
@@ -1555,9 +1555,9 @@ declare class OrdersResource {
1555
1555
  snapshotAccessToken?: string;
1556
1556
  billingAddressId?: string;
1557
1557
  shippingAddressId?: string;
1558
- billingAddress?: AddressInput;
1559
- shippingAddress?: AddressInput;
1560
- shippingRateId?: HashidInput;
1558
+ billingAddress?: AddressInput$1;
1559
+ shippingAddress?: AddressInput$1;
1560
+ shippingRateId?: HashidInput$1;
1561
1561
  fulfillmentLocationId?: string;
1562
1562
  idempotencyKey?: string;
1563
1563
  guest?: {
@@ -1607,6 +1607,7 @@ declare class PersonaResource {
1607
1607
  }
1608
1608
  //#endregion
1609
1609
  //#region src/resources/products.d.ts
1610
+ type ProductsSort = 'featured' | 'price_asc' | 'price_desc' | 'name';
1610
1611
  type ProductsListParams = {
1611
1612
  includePrivate?: boolean;
1612
1613
  team?: string;
@@ -1614,43 +1615,60 @@ type ProductsListParams = {
1614
1615
  perPage?: number;
1615
1616
  search?: string;
1616
1617
  category?: string;
1618
+ labels?: string[];
1619
+ minPrice?: number;
1620
+ maxPrice?: number;
1621
+ available?: boolean;
1622
+ sort?: ProductsSort;
1623
+ locale?: string;
1617
1624
  all?: boolean;
1618
1625
  };
1619
1626
  type ProductCategories = {
1620
1627
  categories: string[];
1621
1628
  hasUntagged: boolean;
1622
1629
  };
1630
+ type ProductFacets = {
1631
+ categories: string[];
1632
+ tags: string[];
1633
+ priceMin: number | null;
1634
+ priceMax: number | null;
1635
+ total: number;
1636
+ };
1623
1637
  declare class ProductsResource {
1624
1638
  private readonly http;
1625
1639
  constructor(http: IHttpService);
1626
1640
  list(params?: ProductsListParams): Promise<_$_joai_core0.IAppResponse<Product[]>>;
1627
1641
  listAll(params?: Omit<ProductsListParams, 'page' | 'perPage' | 'all'>): Promise<_$_joai_core0.IAppResponse<Product[]>>;
1642
+ facets(params?: {
1643
+ team?: string;
1644
+ }): Promise<_$_joai_core0.IAppResponse<ProductFacets>>;
1645
+ private query;
1628
1646
  categories(params?: {
1629
1647
  team?: string;
1630
1648
  }): Promise<_$_joai_core0.IAppResponse<ProductCategories>>;
1631
1649
  get(id: string): Promise<_$_joai_core0.IAppResponse<Product>>;
1632
1650
  getVariation(id: string): Promise<_$_joai_core0.IAppResponse<ProductVariation>>;
1633
1651
  create(data: {
1634
- name: TranslatableValue;
1652
+ name: TranslatableValue$1;
1635
1653
  price?: number;
1636
- unit?: TranslatableValue;
1654
+ unit?: TranslatableValue$1;
1637
1655
  tags?: string[];
1638
- description?: TranslatableValue | null;
1656
+ description?: TranslatableValue$1 | null;
1639
1657
  virtual?: boolean;
1640
1658
  public?: boolean;
1641
1659
  taxClassId?: string | null;
1642
1660
  meta?: {
1643
- details?: ProductDetailSection[];
1661
+ details?: ProductDetailSection$1[];
1644
1662
  };
1645
1663
  }, teamSlug?: string): Promise<_$_joai_core0.IAppResponse<Product>>;
1646
1664
  update(id: string, data: {
1647
- name?: TranslatableValue;
1648
- unit?: TranslatableValue | null;
1665
+ name?: TranslatableValue$1;
1666
+ unit?: TranslatableValue$1 | null;
1649
1667
  tags?: string[] | null;
1650
- description?: TranslatableValue | null;
1668
+ description?: TranslatableValue$1 | null;
1651
1669
  settings?: Record<string, unknown> | null;
1652
1670
  meta?: {
1653
- details?: ProductDetailSection[];
1671
+ details?: ProductDetailSection$1[];
1654
1672
  };
1655
1673
  active?: boolean;
1656
1674
  public?: boolean;
@@ -1660,13 +1678,13 @@ declare class ProductsResource {
1660
1678
  }): Promise<_$_joai_core0.IAppResponse<Product>>;
1661
1679
  delete(id: string): Promise<_$_joai_core0.IAppResponse<void>>;
1662
1680
  createVariation(productSlug: string, data: {
1663
- name: TranslatableValue;
1681
+ name: TranslatableValue$1;
1664
1682
  sku: string;
1665
1683
  price: number;
1666
1684
  type?: string;
1667
1685
  }): Promise<_$_joai_core0.IAppResponse<ProductVariation>>;
1668
1686
  updateVariation(variationId: string, data: {
1669
- name?: TranslatableValue;
1687
+ name?: TranslatableValue$1;
1670
1688
  price?: number;
1671
1689
  active?: boolean;
1672
1690
  hidden?: boolean;
@@ -1792,10 +1810,10 @@ declare class ServicesResource {
1792
1810
  listAll(params?: Omit<ServicesListParams, 'page' | 'perPage' | 'all'>): Promise<_$_joai_core0.IAppResponse<Service[]>>;
1793
1811
  get(slug: string): Promise<_$_joai_core0.IAppResponse<Service>>;
1794
1812
  store(team: string, data: {
1795
- name: TranslatableValue;
1813
+ name: TranslatableValue$1;
1796
1814
  price: number;
1797
1815
  durationMinutes: number | null;
1798
- description?: TranslatableValue | null;
1816
+ description?: TranslatableValue$1 | null;
1799
1817
  digital?: boolean;
1800
1818
  public?: boolean;
1801
1819
  bookable?: boolean;
@@ -1850,7 +1868,7 @@ declare class SitesResource {
1850
1868
  }): Promise<_$_joai_core0.IAppResponse<Site>>;
1851
1869
  resolve(teamSlug: string, brandSlug?: string): Promise<_$_joai_core0.IAppResponse<Site>>;
1852
1870
  resolveByDomain(domain: string): Promise<_$_joai_core0.IAppResponse<Site>>;
1853
- update(siteId: HashidInput, data: {
1871
+ update(siteId: HashidInput$1, data: {
1854
1872
  customDomain?: string | null;
1855
1873
  enabled?: boolean;
1856
1874
  modules?: string[];
@@ -1944,7 +1962,7 @@ declare class SubscriptionsResource {
1944
1962
  updateDelivery(id: string, data: {
1945
1963
  fulfillmentMethod: 'shipping' | 'pickup';
1946
1964
  shippingAddressId?: string | null;
1947
- shippingRateId?: HashidInput | null;
1965
+ shippingRateId?: HashidInput$1 | null;
1948
1966
  fulfillmentLocationId?: string | null;
1949
1967
  }): Promise<_$_joai_core0.IAppResponse<Subscription>>;
1950
1968
  skip(id: string): Promise<_$_joai_core0.IAppResponse<Subscription>>;
@@ -1998,8 +2016,8 @@ type TeamInviteInfo = {
1998
2016
  type TeamMutationPayload = {
1999
2017
  name?: string;
2000
2018
  slug?: string;
2001
- description?: TranslatableValue | null;
2002
- tagline?: TranslatableValue | null;
2019
+ description?: TranslatableValue$1 | null;
2020
+ tagline?: TranslatableValue$1 | null;
2003
2021
  category?: TeamCategory;
2004
2022
  public?: boolean;
2005
2023
  tags?: string[];
@@ -2030,8 +2048,8 @@ declare class TeamsResource {
2030
2048
  }): Promise<_$_joai_core0.IAppResponse<TeamPrivate>>;
2031
2049
  delete(teamSlug: string): Promise<_$_joai_core0.IAppResponse<void>>;
2032
2050
  update(teamSlug: string, data: TeamMutationPayload): Promise<_$_joai_core0.IAppResponse<TeamPrivate>>;
2033
- updateDescription(teamSlug: string, description: TranslatableValue | null): Promise<_$_joai_core0.IAppResponse<TeamPrivate>>;
2034
- updateTagline(teamSlug: string, tagline: TranslatableValue | null): Promise<_$_joai_core0.IAppResponse<TeamPrivate>>;
2051
+ updateDescription(teamSlug: string, description: TranslatableValue$1 | null): Promise<_$_joai_core0.IAppResponse<TeamPrivate>>;
2052
+ updateTagline(teamSlug: string, tagline: TranslatableValue$1 | null): Promise<_$_joai_core0.IAppResponse<TeamPrivate>>;
2035
2053
  invite(teamSlug: string, payload: {
2036
2054
  email: string;
2037
2055
  role: UserRole;
@@ -2263,7 +2281,7 @@ type TranscriptionResponse = {
2263
2281
  declare class VoiceResource {
2264
2282
  private readonly http;
2265
2283
  constructor(http: IHttpService);
2266
- transcribe(teamSlug: string, audio: File, language?: string | null, prompt?: string | null): Promise<IAppResponse<TranscriptionResponse>>;
2284
+ transcribe(teamSlug: string, audio: File, language?: string | null, prompt?: string | null): Promise<IAppResponse$1<TranscriptionResponse>>;
2267
2285
  }
2268
2286
  //#endregion
2269
2287
  //#region src/resources/wallets.d.ts
@@ -2339,8 +2357,8 @@ declare class WarpsResource {
2339
2357
  create(data: {
2340
2358
  brand?: string | null;
2341
2359
  definition: WarpDefinition;
2342
- title?: TranslatableValue;
2343
- description?: TranslatableValue | null;
2360
+ title?: TranslatableValue$1;
2361
+ description?: TranslatableValue$1 | null;
2344
2362
  extras?: Record<string, any> | null;
2345
2363
  public?: boolean;
2346
2364
  form?: boolean;
@@ -2350,8 +2368,8 @@ declare class WarpsResource {
2350
2368
  }): Promise<_$_joai_core0.IAppResponse<BackendWarpCreateResponse>>;
2351
2369
  update(identifier: string, data: {
2352
2370
  name?: string;
2353
- title?: TranslatableValue;
2354
- description?: TranslatableValue | null;
2371
+ title?: TranslatableValue$1;
2372
+ description?: TranslatableValue$1 | null;
2355
2373
  definition?: WarpDefinition;
2356
2374
  extras?: Record<string, any> | null;
2357
2375
  form?: boolean;
@@ -2448,7 +2466,7 @@ interface CacheConfig {
2448
2466
  interface JoAiClientConfig {
2449
2467
  apiToken?: string;
2450
2468
  team?: string;
2451
- env?: AppEnv;
2469
+ env?: AppEnv$1;
2452
2470
  locale?: string;
2453
2471
  agentAuthKey?: string;
2454
2472
  cache?: CacheConfig;
@@ -2555,40 +2573,40 @@ declare class CachedHttpService implements IHttpService {
2555
2573
  constructor(inner: IHttpService, overrides?: TtlMap, defaultTtl?: number);
2556
2574
  get onNetworkError(): (error: Error) => void;
2557
2575
  set onNetworkError(fn: (error: Error) => void);
2558
- get onUnauthorized(): (response: IAppResponse<JsonValue>) => void;
2559
- set onUnauthorized(fn: (response: IAppResponse<JsonValue>) => void);
2560
- get onSuccessfulResponse(): (response: IAppResponse<JsonValue>) => void;
2561
- set onSuccessfulResponse(fn: (response: IAppResponse<JsonValue>) => void);
2562
- get onMaintenanceMode(): (response: IAppResponse<JsonValue>) => void;
2563
- set onMaintenanceMode(fn: (response: IAppResponse<JsonValue>) => void);
2564
- get onTooManyRequests(): (response: IAppResponse<JsonValue>) => void;
2565
- set onTooManyRequests(fn: (response: IAppResponse<JsonValue>) => void);
2576
+ get onUnauthorized(): (response: IAppResponse$1<JsonValue>) => void;
2577
+ set onUnauthorized(fn: (response: IAppResponse$1<JsonValue>) => void);
2578
+ get onSuccessfulResponse(): (response: IAppResponse$1<JsonValue>) => void;
2579
+ set onSuccessfulResponse(fn: (response: IAppResponse$1<JsonValue>) => void);
2580
+ get onMaintenanceMode(): (response: IAppResponse$1<JsonValue>) => void;
2581
+ set onMaintenanceMode(fn: (response: IAppResponse$1<JsonValue>) => void);
2582
+ get onTooManyRequests(): (response: IAppResponse$1<JsonValue>) => void;
2583
+ set onTooManyRequests(fn: (response: IAppResponse$1<JsonValue>) => void);
2566
2584
  clearCache(): void;
2567
- get<T>(url: string, options?: IRequestOptions): Promise<IAppResponse<T>>;
2568
- post<T>(url: string, data?: JsonValue | FormData, options?: IRequestOptions): Promise<IAppResponse<T>>;
2569
- put<T>(url: string, data?: JsonValue | FormData, options?: IRequestOptions): Promise<IAppResponse<T>>;
2570
- patch<T>(url: string, data?: JsonValue | FormData, options?: IRequestOptions): Promise<IAppResponse<T>>;
2571
- delete<T>(url: string, options?: IRequestOptions): Promise<IAppResponse<T>>;
2585
+ get<T>(url: string, options?: IRequestOptions): Promise<IAppResponse$1<T>>;
2586
+ post<T>(url: string, data?: JsonValue | FormData, options?: IRequestOptions): Promise<IAppResponse$1<T>>;
2587
+ put<T>(url: string, data?: JsonValue | FormData, options?: IRequestOptions): Promise<IAppResponse$1<T>>;
2588
+ patch<T>(url: string, data?: JsonValue | FormData, options?: IRequestOptions): Promise<IAppResponse$1<T>>;
2589
+ delete<T>(url: string, options?: IRequestOptions): Promise<IAppResponse$1<T>>;
2572
2590
  private mutate;
2573
2591
  private bust;
2574
2592
  }
2575
2593
  //#endregion
2576
2594
  //#region src/auth/portal.d.ts
2577
2595
  declare const getAuthFragmentToken: (url: string) => string | null;
2578
- declare const isPortalCallbackUrl: (url: string, env?: AppEnv) => boolean;
2579
- declare const sanitizePortalCallbackUrl: (url: string | null | undefined, env?: AppEnv) => string | null;
2596
+ declare const isPortalCallbackUrl: (url: string, env?: AppEnv$1) => boolean;
2597
+ declare const sanitizePortalCallbackUrl: (url: string | null | undefined, env?: AppEnv$1) => string | null;
2580
2598
  declare const isAllowedRedirectUrl: (redirect: string, allowedOrigins: string[]) => boolean;
2581
2599
  declare const completePortalSession: (callbackUrl: string, fetcher?: typeof fetch) => Promise<boolean>;
2582
2600
  type PortalClient = {
2583
2601
  auth: {
2584
- createPortalSession: (redirect: string) => Promise<IAppResponse<AuthPortalSessionResponse>>;
2602
+ createPortalSession: (redirect: string) => Promise<IAppResponse$1<AuthPortalSessionResponse>>;
2585
2603
  };
2586
2604
  };
2587
2605
  type OpenPortalSessionOptions = {
2588
2606
  client: PortalClient;
2589
2607
  redirect: string;
2590
2608
  allowedOrigins: string[];
2591
- env?: AppEnv; /** @deprecated Unused — exchange happens via same-origin blade form after navigation. */
2609
+ env?: AppEnv$1; /** @deprecated Unused — exchange happens via same-origin blade form after navigation. */
2592
2610
  fetcher?: typeof fetch; /** Receives the API callback URL (with fragment token), not the final portal redirect. */
2593
2611
  onNavigate?: (callbackUrl: string) => void;
2594
2612
  };
@@ -2602,8 +2620,8 @@ declare const openPortalSession: ({
2602
2620
  //#endregion
2603
2621
  //#region src/resources/distribution.d.ts
2604
2622
  declare class DistributionResource {
2605
- getBrandSiteConfig(env: AppEnv, brandSlug: string): Promise<BrandSiteConfig | null>;
2623
+ getBrandSiteConfig(env: AppEnv$1, brandSlug: string): Promise<BrandSiteConfig | null>;
2606
2624
  private fetchDistribution;
2607
2625
  }
2608
2626
  //#endregion
2609
- export { AddressesResource, AgentsResource, AlertsResource, AnalyticsResource, ApiTokensResource, AppointmentsResource, type AttachedMedia, type AuthConfirmCodeRequest, type AuthConfirmCodeResponse, type AuthNativeSessionResponse, type AuthPortalSessionResponse, AuthResource, type AuthSendCodeRequest, type AuthUser, AutomationsResource, type BackendWarp, type BackendWarpBrand, BillingResource, BlueprintsResource, type CacheConfig, CachedHttpService, CampaignsResource, CardsResource, type Cart, CartsResource, ChangelogResource, CharactersResource, CheckoutResource, type CheckoutSnapshot, CommerceResource, ContactsResource, ContentResource, ContractsResource, type CreateEmptyGuestCheckoutOptions, type CreateHookPayload, type CreateInboundHookPayload, type CreateInternalHookPayload, type CreateWarpLinkedHookPayload, type CreateWebHookPayload, type DeleteUserParams, DeskResource, DistributionResource, DocumentsResource, ElementsResource, EntitiesResource, FlowsResource, FollowsResource, type FulfillmentLocation, type FulfillmentLocationInput, FulfillmentsResource, GoalsResource, type GuestBuyer, type GuestCartAmounts, type GuestCheckoutCartItem, type GuestCheckoutClient, type GuestCheckoutDraft, GuestCheckoutError, type GuestCheckoutErrorCode, type GuestCheckoutSnapshotResult, type GuestCheckoutState, type GuestCommerceStorage, type GuestCommerceStorageOptions, type GuestCouponClient, GuestCouponError, type GuestCouponErrorCode, type GuestCouponPreview, type GuestOrderAccess, type Hook, type HookSample, type HookTrigger, type HookTriggerCondition, type HookTriggerInput, HooksResource, IngestionsResource, InquiriesResource, InstallsResource, IntegrationsResource, IntentsResource, type ItemListParams, ItemsResource, JoAiClient, type JoAiClientConfig, KvResource, LinksResource, LoyaltyResource, McpResource, type MediaUploadType, MeetingsResource, MemoriesResource, MessagesResource, MetricsResource, MissionsResource, NotificationsResource, OfficeResource, type OpenPortalSessionOptions, type OpeningHoursEntry, type OpeningHoursFormatOptions, type Order, type OrderPriceMode, type OrderStatus, OrdersResource, PersonaResource, type PlaceCheckoutOrderRequest, type PlaceGuestCheckoutOrderResult, type Product, type ProductCategories, type ProductVariation, type ProductsListParams, ProductsResource, ProjectsResource, ProposalsResource, type RecentlyViewedStorage, type RecentlyViewedStorageOptions, RemindersResource, ReturnsResource, type RevalidateGuestCouponResult, SegmentsResource, type ServicesListParams, ServicesResource, type ShippingRate, type ShippingRateInput, ShippingResource, type ShippingZoneInput, ShortcutsResource, SitesResource, SkillsResource, SocialPostsResource, StatsResource, StoreResource, SubscriptionsResource, SwarmsResource, TagsResource, TasksResource, type TaxClassInput, TaxClassesResource, type TeamInviteInfo, TeamsResource, UpdatesResource, UpgradesResource, UsersResource, VoiceResource, WalletsResource, WarpsResource, type WebHookTriggerEvent, WorkspaceResource, assertGuestCheckoutReady, assertGuestPickupSlotReady, buildGuestCheckoutSnapshotRequest, buildGuestOrderReturnUrl, completePortalSession, createClient, createEmptyGuestCheckoutState, createGuestCheckoutSnapshot, createGuestCommerceStorage, createRecentlyViewedStorage, formatOpeningHours, formatPickupSlotLabel, getAuthFragmentToken, getRecentlyViewedSlugs, guestCartAmounts, guestCouponMessageFromErrors, isAllowedRedirectUrl, isGuestCheckoutError, isGuestCouponError, isPortalCallbackUrl, openPortalSession, placeGuestCheckoutOrder, readGuestOrderReturnAccess, revalidateGuestCoupon, sanitizePortalCallbackUrl, stripGuestOrderReturnToken, toGuestCheckoutDraft, trackRecentlyViewed, validateGuestCoupon };
2627
+ export { type AddressInput, AddressesResource, AgentsResource, AlertsResource, AnalyticsResource, ApiTokensResource, type AppEnv, type AppointmentAvailabilitySlot, AppointmentsResource, type AttachedMedia, type AuthConfirmCodeRequest, type AuthConfirmCodeResponse, type AuthNativeSessionResponse, type AuthPortalSessionResponse, AuthResource, type AuthSendCodeRequest, type AuthUser, AutomationsResource, type BackendWarp, type BackendWarpBrand, BillingResource, BlueprintsResource, type CacheConfig, CachedHttpService, CampaignsResource, CardsResource, type Cart, type CartItem, CartsResource, ChangelogResource, CharactersResource, CheckoutResource, type CheckoutSnapshot, type CheckoutSnapshotRequest, CommerceResource, ContactsResource, ContentResource, ContractsResource, type CreateEmptyGuestCheckoutOptions, type CreateHookPayload, type CreateInboundHookPayload, type CreateInternalHookPayload, type CreateWarpLinkedHookPayload, type CreateWebHookPayload, type DeleteUserParams, DeskResource, DistributionResource, DocumentsResource, ElementsResource, EntitiesResource, FlowsResource, FollowsResource, type FulfillmentLocation, type FulfillmentLocationInput, FulfillmentsResource, GoalsResource, type GuestBuyer, type GuestCartAmounts, type GuestCheckoutCartItem, type GuestCheckoutClient, type GuestCheckoutDraft, GuestCheckoutError, type GuestCheckoutErrorCode, type GuestCheckoutSnapshotResult, type GuestCheckoutState, type GuestCommerceStorage, type GuestCommerceStorageOptions, type GuestCouponClient, GuestCouponError, type GuestCouponErrorCode, type GuestCouponPreview, type GuestOrderAccess, type HashidInput, type Hook, type HookSample, type HookTrigger, type HookTriggerCondition, type HookTriggerInput, HooksResource, type IAppResponse, IngestionsResource, InquiriesResource, InstallsResource, IntegrationsResource, IntentsResource, type ItemListParams, ItemsResource, JoAiClient, type JoAiClientConfig, KvResource, LinksResource, LoyaltyResource, McpResource, type MediaUploadType, MeetingsResource, MemoriesResource, MessagesResource, MetricsResource, MissionsResource, NotificationsResource, OfficeResource, type OpenPortalSessionOptions, type OpeningHoursEntry, type OpeningHoursFormatOptions, type Order, type OrderPriceMode, type OrderStatus, OrdersResource, PersonaResource, type PlaceCheckoutOrderRequest, type PlaceGuestCheckoutOrderResult, type Product, type ProductCategories, type ProductDetailSection, type ProductDetailText, type ProductFacets, type ProductRelationType, type ProductVariation, type ProductsListParams, ProductsResource, type ProductsSort, ProjectsResource, ProposalsResource, type RecentlyViewedStorage, type RecentlyViewedStorageOptions, RemindersResource, ReturnsResource, type RevalidateGuestCouponResult, SegmentsResource, type ServicesListParams, ServicesResource, type ShippingRate, type ShippingRateInput, ShippingResource, type ShippingZoneInput, ShortcutsResource, SitesResource, SkillsResource, SocialPostsResource, StatsResource, StoreResource, SubscriptionsResource, SwarmsResource, TagsResource, TasksResource, type TaxClassInput, TaxClassesResource, type TeamInviteInfo, TeamsResource, type TranslatableValue, UpdatesResource, UpgradesResource, UsersResource, VoiceResource, WalletsResource, WarpsResource, type WebHookTriggerEvent, WorkspaceResource, assertGuestCheckoutReady, assertGuestPickupSlotReady, buildGuestCheckoutSnapshotRequest, buildGuestOrderReturnUrl, completePortalSession, createClient, createEmptyGuestCheckoutState, createGuestCheckoutSnapshot, createGuestCommerceStorage, createRecentlyViewedStorage, formatOpeningHours, formatPickupSlotLabel, getAuthFragmentToken, getRecentlyViewedSlugs, guestCartAmounts, guestCouponMessageFromErrors, isAllowedRedirectUrl, isGuestCheckoutError, isGuestCouponError, isPortalCallbackUrl, openPortalSession, placeGuestCheckoutOrder, readGuestOrderReturnAccess, revalidateGuestCoupon, sanitizePortalCallbackUrl, stripGuestOrderReturnToken, toGuestCheckoutDraft, trackRecentlyViewed, validateGuestCoupon };
package/dist/index.mjs CHANGED
@@ -2369,6 +2369,22 @@ var ProductsResource = class {
2369
2369
  }
2370
2370
  list(params) {
2371
2371
  let url = "products";
2372
+ const search = this.query(params);
2373
+ if (search.size) url += `?${search.toString()}`;
2374
+ return this.http.get(url);
2375
+ }
2376
+ listAll(params) {
2377
+ return this.list({
2378
+ ...params,
2379
+ all: true
2380
+ });
2381
+ }
2382
+ facets(params) {
2383
+ let url = "products/facets";
2384
+ if (params?.team) url += `?team=${encodeURIComponent(params.team)}`;
2385
+ return this.http.get(url);
2386
+ }
2387
+ query(params) {
2372
2388
  const search = new URLSearchParams();
2373
2389
  if (params?.includePrivate) search.set("includePrivate", "1");
2374
2390
  if (params?.team) search.set("team", params.team);
@@ -2379,14 +2395,13 @@ var ProductsResource = class {
2379
2395
  }
2380
2396
  if (params?.search) search.set("search", params.search);
2381
2397
  if (params?.category) search.set("category", params.category);
2382
- if (search.size) url += `?${search.toString()}`;
2383
- return this.http.get(url);
2384
- }
2385
- listAll(params) {
2386
- return this.list({
2387
- ...params,
2388
- all: true
2389
- });
2398
+ if (params?.labels?.length) search.set("label", params.labels.join(","));
2399
+ if (params?.minPrice !== void 0) search.set("minPrice", String(params.minPrice));
2400
+ if (params?.maxPrice !== void 0) search.set("maxPrice", String(params.maxPrice));
2401
+ if (params?.available !== void 0) search.set("available", params.available ? "1" : "0");
2402
+ if (params?.sort) search.set("sort", params.sort);
2403
+ if (params?.locale) search.set("locale", params.locale);
2404
+ return search;
2390
2405
  }
2391
2406
  categories(params) {
2392
2407
  let url = "products/categories";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@joai/sdk",
3
- "version": "13.0.1",
3
+ "version": "13.1.0",
4
4
  "description": "JoAi public API SDK — build with your AI agents",
5
5
  "license": "MIT",
6
6
  "type": "module",