arky-sdk 0.8.0 → 0.9.6
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/README.md +2 -2
- package/dist/{admin-CEVBErl_.d.ts → admin-DjYydKeB.d.ts} +510 -176
- package/dist/{admin-DCe3PEOB.d.cts → admin-DlL8mCxL.d.cts} +510 -176
- package/dist/admin.cjs +596 -216
- package/dist/admin.cjs.map +1 -1
- package/dist/admin.d.cts +3 -3
- package/dist/admin.d.ts +3 -3
- package/dist/admin.js +596 -216
- package/dist/admin.js.map +1 -1
- package/dist/api-BbBHcd4p.d.cts +3289 -0
- package/dist/api-BbBHcd4p.d.ts +3289 -0
- package/dist/{index-C5gikdBg.d.cts → index-CZxubTDA.d.ts} +1 -1
- package/dist/{index-MFMjlIfS.d.ts → index-nCF3Z6Af.d.cts} +1 -1
- package/dist/index.cjs +678 -335
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +678 -335
- package/dist/index.js.map +1 -1
- package/dist/storefront-store.cjs +158 -139
- package/dist/storefront-store.cjs.map +1 -1
- package/dist/storefront-store.d.cts +3 -3
- package/dist/storefront-store.d.ts +3 -3
- package/dist/storefront-store.js +158 -139
- package/dist/storefront-store.js.map +1 -1
- package/dist/storefront.cjs +158 -139
- package/dist/storefront.cjs.map +1 -1
- package/dist/storefront.d.cts +45 -102
- package/dist/storefront.d.ts +45 -102
- package/dist/storefront.js +158 -139
- package/dist/storefront.js.map +1 -1
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.cts +1 -2655
- package/dist/types.d.ts +1 -2655
- package/dist/types.js.map +1 -1
- package/dist/utils.d.cts +2 -2
- package/dist/utils.d.ts +2 -2
- package/package.json +3 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Cart, OrderQuote, OrderCheckoutResult, GetCurrentCartParams, GetCartParams,
|
|
2
|
-
import { f as formatPayment, a as formatMinor, g as getCurrencySymbol, b as getCurrencyName, i as isValidKey, v as validateKey, t as toKey, n as nameToKey, c as getAvailableStock, d as getReservedStock, h as hasStock, e as getInventoryAt, j as getFirstAvailableFCId } from './index-
|
|
1
|
+
import { C as Cart, O as OrderQuote, a as OrderCheckoutResult, G as GetCurrentCartParams, b as GetCartParams, R as RequestOptions$1, A as AddCartItemParams, U as UpdateCartParams, c as RemoveCartItemParams, d as ClearCartParams, Q as QuoteCartParams, e as CheckoutCartParams, P as Profile, S as Store, M as Market, f as MagicLinkVerifyParams, g as AuthToken, h as MagicLinkRequestParams, i as UpdateAccountProfileParams, j as AccountUpdateResponse, D as DeleteAccountParams, k as GetMeParams, l as Account, m as SearchAccountsParams, L as Location, n as CreateLocationParams, o as UpdateLocationParams, p as DeleteLocationParams, q as CreateMarketParams, r as UpdateMarketParams, s as DeleteMarketParams, t as CreateStoreParams, u as UpdateStoreParams, v as DeleteStoreParams, w as GetStoreParams, x as GetStoresParams, y as PaginatedResponse, z as GetSubscriptionPlansParams, B as SubscriptionPlan, E as SubscribeParams, F as CreatePortalSessionParams, H as AddMemberParams, I as InviteUserParams, J as RemoveMemberParams, T as TestWebhookParams, K as GetStoreMediaParams2, N as Media, V as OAuthConnectParams, W as Integration, X as OAuthDisconnectParams, Y as ListIntegrationsParams, Z as CreateIntegrationParams, _ as UpdateIntegrationParams, $ as DeleteIntegrationParams, a0 as ListWebhooksParams, a1 as Webhook, a2 as CreateWebhookParams, a3 as UpdateWebhookParams, a4 as DeleteWebhookParams, a5 as GetMediaParams, a6 as UploadStoreMediaParams, a7 as DeleteStoreMediaParams, a8 as GetStoreMediaParams, a9 as UpdateMediaParams, aa as TrackEmailOpenParams, ab as TriggerNotificationParams, ac as CreatePromoCodeParams, ad as PromoCode, ae as UpdatePromoCodeParams, af as DeletePromoCodeParams, ag as GetPromoCodeParams, ah as GetPromoCodesParams, ai as GetShippingRatesParams, aj as ShippingRate, ak as ShipParams, al as ShipResult, am as CreateNodeParams, an as Node, ao as UpdateNodeParams, ap as DeleteNodeParams, aq as GetNodeParams, ar as Block, as as TaxonomyEntry, at as NodeStatus, au as GetNodesParams, av as GetNodeChildrenParams, aw as CreateFormParams, ax as Form, ay as UpdateFormParams, az as DeleteFormParams, aA as GetFormParams, aB as GetFormsParams, aC as SubmitFormParams, aD as FormSubmission, aE as GetFormSubmissionsParams, aF as GetFormSubmissionParams, aG as UpdateFormSubmissionParams, aH as CreateTaxonomyParams, aI as Taxonomy, aJ as UpdateTaxonomyParams, aK as DeleteTaxonomyParams, aL as GetTaxonomyParams, aM as GetTaxonomiesParams, aN as GetTaxonomyChildrenParams, aO as CreateEmailTemplateParams, aP as EmailTemplate, aQ as UpdateEmailTemplateParams, aR as DeleteEmailTemplateParams, aS as GetEmailTemplateParams, aT as GetEmailTemplatesParams, aU as PreviewEmailTemplateParams, aV as PreviewEmailTemplateResponse, aW as CreateProductParams, aX as Product, aY as UpdateProductParams, aZ as DeleteProductParams, a_ as GetProductParams, a$ as GetProductsParams, b0 as UpdateOrderParams, b1 as Order, b2 as GetOrderParams, b3 as GetOrdersParams, b4 as GetQuoteParams, b5 as ProcessOrderRefundParams, b6 as CreateCartParams, b7 as FindCartsParams, b8 as CreateServiceParams, b9 as Service, ba as UpdateServiceParams, bb as DeleteServiceParams, bc as GetServiceParams, bd as GetServicesParams, be as GetAvailabilityParams, bf as AvailabilityResponse, bg as FindServiceProvidersParams, bh as ServiceProvider, bi as CreateServiceProviderParams, bj as UpdateServiceProviderParams, bk as DeleteServiceProviderParams, bl as CreateProviderParams, bm as Provider, bn as UpdateProviderParams, bo as DeleteProviderParams, bp as GetProviderParams, bq as GetProvidersParams, br as CreateProfileParams, bs as Profile$1, bt as GetProfileParams, bu as ProfileDetail, bv as FindProfilesParams, bw as UpdateProfileParams, bx as MergeProfilesParams, by as ImportProfilesParams, bz as ImportProfilesResult, bA as CreateProfileListParams, bB as ProfileList, bC as UpdateProfileListParams, bD as GetProfileListParams, bE as FindProfileListsParams, bF as ImportProfilesIntoProfileListParams, bG as ImportProfilesIntoProfileListResult, bH as ImportProfileListPreviewParams, bI as ImportProfilesPreviewResult, bJ as AddProfileListProfileParams, bK as ProfileListMember, bL as UpdateProfileListProfileParams, bM as RemoveProfileListProfileParams, bN as FindProfileListProfilesParams, bO as CreateMailboxParams, bP as Mailbox, bQ as UpdateMailboxParams, bR as GetMailboxParams, bS as TestMailboxParams, bT as TestMailboxResult, bU as PrepareMailboxParams, bV as FindMailboxesParams, bW as CreateCampaignParams, bX as Campaign, bY as UpdateCampaignParams, bZ as GetCampaignParams, b_ as FindCampaignsParams, b$ as LaunchCampaignParams, c0 as DuplicateCampaignParams, c1 as GetCampaignLaunchReadinessParams, c2 as CampaignLaunchReadiness, c3 as ImportCampaignRecipientsParams, c4 as CampaignRecipientImportResult, c5 as GenerateOutreachPersonalizedDraftsParams, c6 as FindCampaignRecipientsParams, c7 as CampaignRecipient, c8 as GetCampaignRecipientConversationParams, c9 as CampaignRecipientConversationResponse, ca as UpdateCampaignRecipientParams, cb as UpdateCampaignRecipientDraftParams, cc as ReplyCampaignRecipientParams, cd as StopCampaignRecipientParams, ce as FindCampaignMessagesParams, cf as CampaignMessage, cg as UpdateCampaignMessageParams, ch as CreateSuppressionParams, ci as Suppression, cj as UpdateSuppressionParams, ck as GetSuppressionParams, cl as FindSuppressionsParams, cm as CreateLeadResearchRunParams, cn as LeadResearchRun, co as FindLeadResearchRunsParams, cp as GetLeadResearchRunParams, cq as UpdateLeadResearchRunParams, cr as CancelLeadResearchRunParams, cs as SendLeadResearchMessageParams, ct as SendLeadResearchMessageResult, cu as FindLeadResearchMessagesParams, cv as LeadResearchMessage, cw as ValidateLeadEmailParams, cx as LeadEmailValidationResult, cy as FindActivitiesParams, cz as CreateWorkflowParams, cA as Workflow, cB as UpdateWorkflowParams, cC as DeleteWorkflowParams, cD as GetWorkflowParams, cE as GetWorkflowsParams, cF as TriggerWorkflowParams, cG as WorkflowExecution, cH as GetWorkflowExecutionsParams, cI as GetWorkflowExecutionParams, cJ as SubscribeProfileListParams, cK as ProfileListSubscribeResponse, cL as ProfileListAccessParams, cM as ProfileListAccessResponse } from './api-BbBHcd4p.cjs';
|
|
2
|
+
import { f as formatPayment, a as formatMinor, g as getCurrencySymbol, b as getCurrencyName, i as isValidKey, v as validateKey, t as toKey, n as nameToKey, c as getAvailableStock, d as getReservedStock, h as hasStock, e as getInventoryAt, j as getFirstAvailableFCId } from './index-nCF3Z6Af.cjs';
|
|
3
3
|
|
|
4
4
|
interface CartApi {
|
|
5
5
|
current(params?: GetCurrentCartParams, options?: RequestOptions$1): Promise<Cart>;
|
|
@@ -54,22 +54,22 @@ interface CartController {
|
|
|
54
54
|
}
|
|
55
55
|
declare function createCartController(cartApi: CartApi): CartController;
|
|
56
56
|
|
|
57
|
-
type
|
|
57
|
+
type ProfileToken = {
|
|
58
58
|
id: string;
|
|
59
59
|
token: string;
|
|
60
60
|
created_at: number;
|
|
61
61
|
};
|
|
62
62
|
type IdentifyResponse = {
|
|
63
|
-
|
|
64
|
-
token:
|
|
63
|
+
profile: Profile;
|
|
64
|
+
token: ProfileToken;
|
|
65
65
|
store: Store;
|
|
66
66
|
market: Market | null;
|
|
67
67
|
code_sent: boolean;
|
|
68
68
|
};
|
|
69
|
-
type VerifyResponse =
|
|
69
|
+
type VerifyResponse = ProfileToken;
|
|
70
70
|
interface Activity$1 {
|
|
71
71
|
store_id: string;
|
|
72
|
-
|
|
72
|
+
profile_id: string;
|
|
73
73
|
type: string;
|
|
74
74
|
payload: Record<string, unknown>;
|
|
75
75
|
created_at: number;
|
|
@@ -81,67 +81,138 @@ interface TrackParams {
|
|
|
81
81
|
declare const COMMON_ACTIVITY_TYPES: readonly ["page_view", "product_view", "service_view", "provider_view", "cart_added", "cart_removed", "checkout_started", "purchase", "order_created", "signin", "signup", "verified_email", "search", "share", "wishlist_added"];
|
|
82
82
|
type CommonActivityType = (typeof COMMON_ACTIVITY_TYPES)[number];
|
|
83
83
|
|
|
84
|
-
|
|
85
|
-
type Granularity = "hour" | "day" | "week" | "month" | {
|
|
86
|
-
minutes: 5 | 10 | 15 | 30;
|
|
87
|
-
};
|
|
88
|
-
type Measure = "count" | "uniq_customers" | "orders_created" | "new_customers" | "form_submissions" | {
|
|
89
|
-
entity_state: {
|
|
90
|
-
entity: EntityKind;
|
|
91
|
-
status: string;
|
|
92
|
-
};
|
|
93
|
-
};
|
|
94
|
-
type Dimension = "country_code" | "city" | "device_type" | "browser" | "os" | "language" | "activity_type" | "entity" | "entity_status" | {
|
|
95
|
-
time_bucket: {
|
|
96
|
-
granularity: Granularity;
|
|
97
|
-
};
|
|
98
|
-
};
|
|
99
|
-
type FilterField = "type" | "country_code" | "device_type" | "browser" | "os" | "language" | "entity" | "action" | "customer_id";
|
|
100
|
-
type FilterOp = "eq" | "neq" | "in" | "not_in" | "contains";
|
|
101
|
-
interface Filter {
|
|
102
|
-
field: FilterField;
|
|
103
|
-
op: FilterOp;
|
|
104
|
-
values: string[];
|
|
105
|
-
}
|
|
106
|
-
type TimeUnit = "hour" | "day" | "week" | "month";
|
|
107
|
-
type TimeRange = {
|
|
108
|
-
from: number;
|
|
109
|
-
unit: TimeUnit;
|
|
110
|
-
to?: number;
|
|
111
|
-
} | {
|
|
84
|
+
interface AnalyticsTimeRange {
|
|
112
85
|
from: number;
|
|
113
86
|
to: number;
|
|
114
|
-
};
|
|
115
|
-
interface OrderBy {
|
|
116
|
-
field: string;
|
|
117
|
-
dir: "asc" | "desc";
|
|
118
|
-
}
|
|
119
|
-
interface AnalyticsQuery {
|
|
120
|
-
measures: Measure[];
|
|
121
|
-
dimensions?: Dimension[];
|
|
122
|
-
filters?: Filter[];
|
|
123
|
-
time_range: TimeRange;
|
|
124
|
-
granularity?: Granularity;
|
|
125
|
-
order_by?: OrderBy[];
|
|
126
|
-
limit?: number;
|
|
127
|
-
}
|
|
128
|
-
interface AnalyticsRow {
|
|
129
|
-
[key: string]: string | number | null;
|
|
130
87
|
}
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
execution_ms: number;
|
|
136
|
-
};
|
|
137
|
-
}
|
|
138
|
-
type ActivityFeedCategory = "orders" | "carts" | "promo_codes" | "submissions" | "customers" | "audiences" | "products" | "services" | "providers" | "cms" | "workflows" | "agents" | "activities";
|
|
139
|
-
interface ActivityFeedQuery {
|
|
88
|
+
type AnalyticsReportKey = "business_overview" | "profile_funnel" | "outreach_overview" | "outreach_funnel" | "outreach_variant_performance" | "activity_by_country" | "top_activity_pages" | "entity_status_overview" | "data_health" | "orders_created" | "profiles_created" | "form_submissions_created" | "carts_abandoned" | "campaign_messages_sent" | "campaign_messages_received" | "suppressions_created" | "media_count" | "products_by_status" | "services_by_status" | "providers_by_status" | "nodes_by_status" | "profiles_by_status" | "profile_lists_by_status" | "mailboxes_by_status" | "campaigns_by_status" | "campaign_recipients_by_status" | "campaign_messages_by_status" | "support_conversations_by_status" | "lead_research_runs_by_status" | "suppressions_by_status" | "workflows_by_status" | "promo_codes_by_status" | "email_templates_by_status" | "forms_by_status" | "taxonomies_by_status" | "carts_by_status" | "orders_by_status" | "order_items_by_status" | "recent_activity";
|
|
89
|
+
type ActivityFeedCategory = "orders" | "carts" | "promo_codes" | "submissions" | "profiles" | "profile_lists" | "products" | "services" | "providers" | "cms" | "workflows" | "activities";
|
|
90
|
+
interface AnalyticsReportRequest {
|
|
91
|
+
key: AnalyticsReportKey;
|
|
140
92
|
limit?: number;
|
|
141
|
-
|
|
93
|
+
category?: ActivityFeedCategory;
|
|
142
94
|
cursor_created_at?: number;
|
|
143
95
|
cursor_id?: string;
|
|
144
|
-
|
|
96
|
+
}
|
|
97
|
+
interface AnalyticsRequest {
|
|
98
|
+
time?: AnalyticsTimeRange;
|
|
99
|
+
reports?: AnalyticsReportRequest[];
|
|
100
|
+
blocks?: AnalyticsBlockRequest[];
|
|
101
|
+
}
|
|
102
|
+
interface AnalyticsBlockRequest {
|
|
103
|
+
id: string;
|
|
104
|
+
time: AnalyticsTimeRange;
|
|
105
|
+
reports: AnalyticsReportRequest[];
|
|
106
|
+
}
|
|
107
|
+
interface AnalyticsMetricData {
|
|
108
|
+
value: number;
|
|
109
|
+
execution_ms?: number;
|
|
110
|
+
}
|
|
111
|
+
interface AnalyticsBreakdownItem {
|
|
112
|
+
key: string;
|
|
113
|
+
label: string;
|
|
114
|
+
value: number;
|
|
115
|
+
unique_profiles?: number;
|
|
116
|
+
unique_visitors?: number;
|
|
117
|
+
}
|
|
118
|
+
interface AnalyticsBreakdownData {
|
|
119
|
+
items: AnalyticsBreakdownItem[];
|
|
120
|
+
}
|
|
121
|
+
interface BusinessOverviewData {
|
|
122
|
+
visitors: number;
|
|
123
|
+
new_visitors: number;
|
|
124
|
+
known_profiles: number;
|
|
125
|
+
new_known_profiles: number;
|
|
126
|
+
email_known_profiles: number;
|
|
127
|
+
verified_profiles: number;
|
|
128
|
+
new_verified_profiles: number;
|
|
129
|
+
buyers: number;
|
|
130
|
+
orders: number;
|
|
131
|
+
revenue: number;
|
|
132
|
+
revenue_by_currency: RevenueByCurrencyData[];
|
|
133
|
+
average_order_value: number;
|
|
134
|
+
carts: number;
|
|
135
|
+
abandoned_carts: number;
|
|
136
|
+
visitor_to_known_rate: number;
|
|
137
|
+
visitor_to_buyer_rate: number;
|
|
138
|
+
cart_abandonment_rate: number;
|
|
139
|
+
}
|
|
140
|
+
interface RevenueByCurrencyData {
|
|
141
|
+
currency: string;
|
|
142
|
+
orders: number;
|
|
143
|
+
revenue: number;
|
|
144
|
+
average_order_value: number;
|
|
145
|
+
}
|
|
146
|
+
interface ProfileFunnelStage {
|
|
147
|
+
key: "visitors" | "email_known_profiles" | "verified_profiles" | "buyers" | string;
|
|
148
|
+
label: string;
|
|
149
|
+
value: number;
|
|
150
|
+
}
|
|
151
|
+
interface ProfileFunnelData {
|
|
152
|
+
stages: ProfileFunnelStage[];
|
|
153
|
+
visitor_to_known_rate?: number;
|
|
154
|
+
visitor_to_buyer_rate?: number;
|
|
155
|
+
}
|
|
156
|
+
interface OutreachOverviewData {
|
|
157
|
+
profile_lists: number;
|
|
158
|
+
active_profile_lists: number;
|
|
159
|
+
mailboxes: number;
|
|
160
|
+
active_mailboxes: number;
|
|
161
|
+
campaigns: number;
|
|
162
|
+
active_campaigns: number;
|
|
163
|
+
campaign_recipients: number;
|
|
164
|
+
new_campaign_recipients: number;
|
|
165
|
+
active_campaign_recipients: number;
|
|
166
|
+
completed_campaign_recipients: number;
|
|
167
|
+
replied_campaign_recipients: number;
|
|
168
|
+
suppressed_campaign_recipients: number;
|
|
169
|
+
failed_campaign_recipients: number;
|
|
170
|
+
campaign_messages_sent: number;
|
|
171
|
+
outreach_bounces: number;
|
|
172
|
+
campaign_messages_received: number;
|
|
173
|
+
suppressions: number;
|
|
174
|
+
active_suppressions: number;
|
|
175
|
+
new_suppressions: number;
|
|
176
|
+
reply_rate: number;
|
|
177
|
+
bounce_rate: number;
|
|
178
|
+
suppression_rate: number;
|
|
179
|
+
}
|
|
180
|
+
interface OutreachFunnelStage {
|
|
181
|
+
key: "profile_lists" | "campaigns" | "campaign_recipients" | "campaign_messages_sent" | "outreach_bounces" | "campaign_messages_received" | string;
|
|
182
|
+
label: string;
|
|
183
|
+
value: number;
|
|
184
|
+
}
|
|
185
|
+
interface OutreachFunnelData {
|
|
186
|
+
stages: OutreachFunnelStage[];
|
|
187
|
+
reply_rate?: number;
|
|
188
|
+
bounce_rate?: number;
|
|
189
|
+
suppression_rate?: number;
|
|
190
|
+
}
|
|
191
|
+
interface OutreachVariantPerformanceItem {
|
|
192
|
+
campaign_id: string;
|
|
193
|
+
step_id: string;
|
|
194
|
+
step_position: number;
|
|
195
|
+
step_variant_id: string;
|
|
196
|
+
step_variant_name: string;
|
|
197
|
+
sent: number;
|
|
198
|
+
bounced: number;
|
|
199
|
+
failed: number;
|
|
200
|
+
replies: number;
|
|
201
|
+
reply_rate: number;
|
|
202
|
+
bounce_rate: number;
|
|
203
|
+
}
|
|
204
|
+
interface OutreachVariantPerformanceData {
|
|
205
|
+
variants: OutreachVariantPerformanceItem[];
|
|
206
|
+
}
|
|
207
|
+
interface EntityStatusOverviewData {
|
|
208
|
+
entities: Record<string, AnalyticsBreakdownItem[]>;
|
|
209
|
+
}
|
|
210
|
+
interface DataHealthData {
|
|
211
|
+
anonymous_profiles: number;
|
|
212
|
+
known_profiles: number;
|
|
213
|
+
duplicate_emails: number;
|
|
214
|
+
unknown_country_events: number;
|
|
215
|
+
unknown_device_events: number;
|
|
145
216
|
}
|
|
146
217
|
interface ActivityFeedItem {
|
|
147
218
|
id: string;
|
|
@@ -150,12 +221,11 @@ interface ActivityFeedItem {
|
|
|
150
221
|
action: string;
|
|
151
222
|
event_type: string;
|
|
152
223
|
status: string;
|
|
153
|
-
|
|
224
|
+
profile_id: string;
|
|
154
225
|
category: string;
|
|
155
226
|
title: string;
|
|
156
227
|
description: string;
|
|
157
228
|
href?: string | null;
|
|
158
|
-
booking_count: number;
|
|
159
229
|
data: unknown;
|
|
160
230
|
payload: unknown;
|
|
161
231
|
created_at: number;
|
|
@@ -164,8 +234,8 @@ interface ActivityFeedSummary {
|
|
|
164
234
|
total: number;
|
|
165
235
|
orders: number;
|
|
166
236
|
submissions: number;
|
|
167
|
-
|
|
168
|
-
|
|
237
|
+
profiles: number;
|
|
238
|
+
profile_lists: number;
|
|
169
239
|
abandoned_carts: number;
|
|
170
240
|
carts: number;
|
|
171
241
|
promo_codes: number;
|
|
@@ -174,7 +244,6 @@ interface ActivityFeedSummary {
|
|
|
174
244
|
providers: number;
|
|
175
245
|
cms: number;
|
|
176
246
|
workflows: number;
|
|
177
|
-
agents: number;
|
|
178
247
|
activities: number;
|
|
179
248
|
window_start: number;
|
|
180
249
|
}
|
|
@@ -182,7 +251,7 @@ interface ActivityFeedCursor {
|
|
|
182
251
|
created_at: number;
|
|
183
252
|
id: string;
|
|
184
253
|
}
|
|
185
|
-
interface
|
|
254
|
+
interface ActivityFeedData {
|
|
186
255
|
items: ActivityFeedItem[];
|
|
187
256
|
summary: ActivityFeedSummary;
|
|
188
257
|
next_cursor?: ActivityFeedCursor | null;
|
|
@@ -191,11 +260,191 @@ interface ActivityFeedResponse {
|
|
|
191
260
|
execution_ms: number;
|
|
192
261
|
};
|
|
193
262
|
}
|
|
263
|
+
type AnalyticsMetricReportKey = "orders_created" | "profiles_created" | "form_submissions_created" | "carts_abandoned" | "campaign_messages_sent" | "campaign_messages_received" | "suppressions_created" | "media_count";
|
|
264
|
+
type AnalyticsBreakdownReportKey = "activity_by_country" | "top_activity_pages" | "products_by_status" | "services_by_status" | "providers_by_status" | "nodes_by_status" | "profiles_by_status" | "profile_lists_by_status" | "mailboxes_by_status" | "campaigns_by_status" | "campaign_recipients_by_status" | "campaign_messages_by_status" | "support_conversations_by_status" | "lead_research_runs_by_status" | "suppressions_by_status" | "workflows_by_status" | "promo_codes_by_status" | "email_templates_by_status" | "forms_by_status" | "taxonomies_by_status" | "carts_by_status" | "orders_by_status" | "order_items_by_status";
|
|
265
|
+
type AnalyticsActivityReportKey = "recent_activity";
|
|
266
|
+
type AnalyticsCompositeReportKey = "business_overview" | "profile_funnel" | "outreach_overview" | "outreach_funnel" | "outreach_variant_performance" | "entity_status_overview" | "data_health";
|
|
267
|
+
type AnalyticsReport = {
|
|
268
|
+
key: AnalyticsMetricReportKey;
|
|
269
|
+
data: AnalyticsMetricData;
|
|
270
|
+
} | {
|
|
271
|
+
key: AnalyticsBreakdownReportKey;
|
|
272
|
+
data: AnalyticsBreakdownData;
|
|
273
|
+
} | {
|
|
274
|
+
key: "business_overview";
|
|
275
|
+
data: BusinessOverviewData;
|
|
276
|
+
} | {
|
|
277
|
+
key: "profile_funnel";
|
|
278
|
+
data: ProfileFunnelData;
|
|
279
|
+
} | {
|
|
280
|
+
key: "outreach_overview";
|
|
281
|
+
data: OutreachOverviewData;
|
|
282
|
+
} | {
|
|
283
|
+
key: "outreach_funnel";
|
|
284
|
+
data: OutreachFunnelData;
|
|
285
|
+
} | {
|
|
286
|
+
key: "outreach_variant_performance";
|
|
287
|
+
data: OutreachVariantPerformanceData;
|
|
288
|
+
} | {
|
|
289
|
+
key: "entity_status_overview";
|
|
290
|
+
data: EntityStatusOverviewData;
|
|
291
|
+
} | {
|
|
292
|
+
key: "data_health";
|
|
293
|
+
data: DataHealthData;
|
|
294
|
+
} | {
|
|
295
|
+
key: AnalyticsActivityReportKey;
|
|
296
|
+
data: ActivityFeedData;
|
|
297
|
+
};
|
|
298
|
+
interface AnalyticsBlockResponse {
|
|
299
|
+
id: string;
|
|
300
|
+
time: AnalyticsTimeRange;
|
|
301
|
+
reports: AnalyticsReport[];
|
|
302
|
+
}
|
|
303
|
+
interface AnalyticsResponse {
|
|
304
|
+
time?: AnalyticsTimeRange;
|
|
305
|
+
reports?: AnalyticsReport[];
|
|
306
|
+
blocks?: AnalyticsBlockResponse[];
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
interface SupportAgentNode {
|
|
310
|
+
type: "message" | "input" | "ai_handoff" | "action";
|
|
311
|
+
text?: string;
|
|
312
|
+
buttons?: string[];
|
|
313
|
+
prompt?: string;
|
|
314
|
+
field?: string;
|
|
315
|
+
input_type?: "text" | "email" | "phone";
|
|
316
|
+
validation?: string;
|
|
317
|
+
system_prompt_override?: string;
|
|
318
|
+
tools?: string[];
|
|
319
|
+
action?: SupportAction;
|
|
320
|
+
}
|
|
321
|
+
interface SupportAction {
|
|
322
|
+
type: "end_conversation" | "human_handoff";
|
|
323
|
+
message?: string;
|
|
324
|
+
}
|
|
325
|
+
interface SupportAgentEdge {
|
|
326
|
+
source: string;
|
|
327
|
+
target: string;
|
|
328
|
+
trigger: EdgeTrigger;
|
|
329
|
+
}
|
|
330
|
+
type EdgeTrigger = {
|
|
331
|
+
type: "button";
|
|
332
|
+
label: string;
|
|
333
|
+
} | {
|
|
334
|
+
type: "input";
|
|
335
|
+
field: string;
|
|
336
|
+
} | {
|
|
337
|
+
type: "default";
|
|
338
|
+
};
|
|
339
|
+
interface SupportAgentAiConfig {
|
|
340
|
+
integration_id: string;
|
|
341
|
+
system_prompt: string;
|
|
342
|
+
tools: string[];
|
|
343
|
+
max_context_messages: number;
|
|
344
|
+
}
|
|
345
|
+
interface SupportAgent {
|
|
346
|
+
id: string;
|
|
347
|
+
key: string;
|
|
348
|
+
store_id: string;
|
|
349
|
+
name: string;
|
|
350
|
+
status: "draft" | "active" | "archived";
|
|
351
|
+
entry_node_id: string;
|
|
352
|
+
nodes: Record<string, SupportAgentNode>;
|
|
353
|
+
edges: SupportAgentEdge[];
|
|
354
|
+
ai_config?: SupportAgentAiConfig;
|
|
355
|
+
created_at: number;
|
|
356
|
+
updated_at: number;
|
|
357
|
+
}
|
|
358
|
+
interface SupportConversation {
|
|
359
|
+
id: string;
|
|
360
|
+
store_id: string;
|
|
361
|
+
agent_id?: string;
|
|
362
|
+
current_node_id?: string;
|
|
363
|
+
profile_id?: string;
|
|
364
|
+
assigned_account_id?: string | null;
|
|
365
|
+
status: "active" | "ai_mode" | "escalated" | "resolved";
|
|
366
|
+
data: Record<string, unknown>;
|
|
367
|
+
metadata: Record<string, unknown>;
|
|
368
|
+
created_at: number;
|
|
369
|
+
updated_at: number;
|
|
370
|
+
}
|
|
371
|
+
interface SupportMessage {
|
|
372
|
+
id: string;
|
|
373
|
+
store_id: string;
|
|
374
|
+
conversation_id: string;
|
|
375
|
+
role: "system" | "user" | "assistant" | "staff" | "activity";
|
|
376
|
+
content: string;
|
|
377
|
+
buttons?: string[];
|
|
378
|
+
metadata: Record<string, unknown>;
|
|
379
|
+
created_at: number;
|
|
380
|
+
}
|
|
381
|
+
interface SupportConversationResponse {
|
|
382
|
+
conversation: SupportConversation;
|
|
383
|
+
messages: SupportMessage[];
|
|
384
|
+
}
|
|
385
|
+
interface StartSupportConversationParams {
|
|
386
|
+
store_id: string;
|
|
387
|
+
agent_key?: string;
|
|
388
|
+
metadata?: Record<string, unknown>;
|
|
389
|
+
}
|
|
390
|
+
interface SendSupportMessageParams {
|
|
391
|
+
store_id: string;
|
|
392
|
+
conversation_id: string;
|
|
393
|
+
input: {
|
|
394
|
+
type: "button";
|
|
395
|
+
label: string;
|
|
396
|
+
} | {
|
|
397
|
+
type: "text";
|
|
398
|
+
content: string;
|
|
399
|
+
};
|
|
400
|
+
}
|
|
401
|
+
interface ReplySupportConversationParams {
|
|
402
|
+
store_id: string;
|
|
403
|
+
conversation_id: string;
|
|
404
|
+
content: string;
|
|
405
|
+
resolve?: boolean;
|
|
406
|
+
}
|
|
407
|
+
interface ResolveSupportConversationParams {
|
|
408
|
+
store_id: string;
|
|
409
|
+
conversation_id: string;
|
|
410
|
+
}
|
|
411
|
+
interface AssignSupportConversationParams {
|
|
412
|
+
store_id: string;
|
|
413
|
+
conversation_id: string;
|
|
414
|
+
account_id?: string | null;
|
|
415
|
+
}
|
|
416
|
+
interface GetSupportConversationParams {
|
|
417
|
+
store_id: string;
|
|
418
|
+
conversation_id: string;
|
|
419
|
+
message_limit?: number;
|
|
420
|
+
after_created_at?: number;
|
|
421
|
+
after_id?: string;
|
|
422
|
+
}
|
|
423
|
+
interface CreateSupportAgentParams {
|
|
424
|
+
store_id: string;
|
|
425
|
+
key: string;
|
|
426
|
+
name: string;
|
|
427
|
+
status?: "draft" | "active" | "archived";
|
|
428
|
+
entry_node_id: string;
|
|
429
|
+
nodes: Record<string, SupportAgentNode>;
|
|
430
|
+
edges: SupportAgentEdge[];
|
|
431
|
+
ai_config?: SupportAgentAiConfig;
|
|
432
|
+
}
|
|
433
|
+
interface UpdateSupportAgentParams {
|
|
434
|
+
store_id: string;
|
|
435
|
+
id: string;
|
|
436
|
+
name?: string;
|
|
437
|
+
status?: "draft" | "active" | "archived";
|
|
438
|
+
entry_node_id?: string;
|
|
439
|
+
nodes?: Record<string, SupportAgentNode>;
|
|
440
|
+
edges?: SupportAgentEdge[];
|
|
441
|
+
ai_config?: SupportAgentAiConfig;
|
|
442
|
+
}
|
|
194
443
|
|
|
195
444
|
interface Activity {
|
|
196
445
|
id: string;
|
|
197
446
|
store_id: string;
|
|
198
|
-
|
|
447
|
+
profile_id: string;
|
|
199
448
|
type: string;
|
|
200
449
|
payload: Record<string, unknown>;
|
|
201
450
|
created_at: number;
|
|
@@ -210,7 +459,7 @@ interface Activity {
|
|
|
210
459
|
session_idx?: number | null;
|
|
211
460
|
}
|
|
212
461
|
interface TimelineParams {
|
|
213
|
-
|
|
462
|
+
profile_id: string;
|
|
214
463
|
store_id?: string;
|
|
215
464
|
limit?: number;
|
|
216
465
|
cursor?: string;
|
|
@@ -250,11 +499,6 @@ interface IntegrationService {
|
|
|
250
499
|
}>;
|
|
251
500
|
}
|
|
252
501
|
|
|
253
|
-
interface InvitationTokenData {
|
|
254
|
-
auth: AuthToken;
|
|
255
|
-
store_id?: string | null;
|
|
256
|
-
}
|
|
257
|
-
|
|
258
502
|
interface LocationState {
|
|
259
503
|
code: string;
|
|
260
504
|
name: string;
|
|
@@ -356,7 +600,7 @@ declare function fetchSvgContent(mediaObject: any): Promise<string | null>;
|
|
|
356
600
|
declare function getSvgContentForAstro(mediaObject: any): Promise<string>;
|
|
357
601
|
declare function injectSvgIntoElement(mediaObject: any, targetElement: HTMLElement, className?: string): Promise<void>;
|
|
358
602
|
|
|
359
|
-
declare const SDK_VERSION = "0.
|
|
603
|
+
declare const SDK_VERSION = "0.9.2";
|
|
360
604
|
declare const SUPPORTED_FRAMEWORKS: readonly ["astro", "react", "vue", "svelte", "vanilla"];
|
|
361
605
|
|
|
362
606
|
interface ApiConfig {
|
|
@@ -373,22 +617,22 @@ interface AdminSessionInternal {
|
|
|
373
617
|
access_expires_at?: number;
|
|
374
618
|
email?: string;
|
|
375
619
|
}
|
|
376
|
-
interface
|
|
620
|
+
interface ProfileSessionInternal {
|
|
377
621
|
access_token: string;
|
|
378
|
-
|
|
622
|
+
profile: Profile;
|
|
379
623
|
store: Store;
|
|
380
624
|
market: Market | null;
|
|
381
625
|
}
|
|
382
626
|
interface AdminSession {
|
|
383
627
|
email?: string;
|
|
384
628
|
}
|
|
385
|
-
interface
|
|
386
|
-
|
|
629
|
+
interface ProfileSession {
|
|
630
|
+
profile: Profile;
|
|
387
631
|
store: Store;
|
|
388
632
|
market: Market | null;
|
|
389
633
|
}
|
|
390
634
|
type AdminSessionUpdater = (updater: (prev: AdminSessionInternal | null) => AdminSessionInternal | null) => void;
|
|
391
|
-
type
|
|
635
|
+
type ProfileSessionUpdater = (updater: (prev: ProfileSessionInternal | null) => ProfileSessionInternal | null) => void;
|
|
392
636
|
type AuthStateListener<T> = (session: T | null) => void;
|
|
393
637
|
|
|
394
638
|
type CreateAdminConfig = Omit<HttpClientConfig, "authStorage" | "storeId"> & {
|
|
@@ -464,13 +708,11 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
464
708
|
createPortalSession(params: CreatePortalSessionParams, options?: RequestOptions$1): Promise<{
|
|
465
709
|
portal_url: string;
|
|
466
710
|
}>;
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
}>;
|
|
711
|
+
addMember(params: AddMemberParams, options?: RequestOptions$1): Promise<boolean>;
|
|
712
|
+
inviteUser(params: InviteUserParams, options?: RequestOptions$1): Promise<boolean>;
|
|
470
713
|
removeMember(params: RemoveMemberParams, options?: RequestOptions$1): Promise<{
|
|
471
714
|
removed: boolean;
|
|
472
715
|
}>;
|
|
473
|
-
handleInvitation(params: HandleInvitationParams, options?: RequestOptions$1): Promise<InvitationTokenData>;
|
|
474
716
|
testWebhook(params: TestWebhookParams, options?: RequestOptions$1): Promise<{
|
|
475
717
|
tested: boolean;
|
|
476
718
|
}>;
|
|
@@ -508,7 +750,8 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
508
750
|
notification: {
|
|
509
751
|
trackEmailOpen(params: TrackEmailOpenParams, options?: RequestOptions$1): Promise<void>;
|
|
510
752
|
trigger(params: TriggerNotificationParams, options?: RequestOptions$1): Promise<{
|
|
511
|
-
|
|
753
|
+
success: boolean;
|
|
754
|
+
message: string;
|
|
512
755
|
}>;
|
|
513
756
|
};
|
|
514
757
|
promoCode: {
|
|
@@ -555,6 +798,7 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
555
798
|
username?: string;
|
|
556
799
|
password?: string;
|
|
557
800
|
}, options?: RequestOptions$1): Promise<{
|
|
801
|
+
success: boolean;
|
|
558
802
|
message: string;
|
|
559
803
|
}>;
|
|
560
804
|
};
|
|
@@ -621,6 +865,7 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
621
865
|
}>;
|
|
622
866
|
get: (params: GetEmailTemplateParams, options?: RequestOptions$1) => Promise<EmailTemplate>;
|
|
623
867
|
find: (params: GetEmailTemplatesParams, options?: RequestOptions$1) => Promise<PaginatedResponse<EmailTemplate>>;
|
|
868
|
+
preview: (params: PreviewEmailTemplateParams, options?: RequestOptions$1) => Promise<PreviewEmailTemplateResponse>;
|
|
624
869
|
};
|
|
625
870
|
};
|
|
626
871
|
eshop: {
|
|
@@ -681,15 +926,16 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
681
926
|
};
|
|
682
927
|
};
|
|
683
928
|
crm: {
|
|
684
|
-
|
|
685
|
-
create: (params:
|
|
686
|
-
get: (params:
|
|
687
|
-
find: (params?:
|
|
688
|
-
items:
|
|
929
|
+
profile: {
|
|
930
|
+
create: (params: CreateProfileParams, options?: RequestOptions$1) => Promise<Profile$1>;
|
|
931
|
+
get: (params: GetProfileParams, options?: RequestOptions$1) => Promise<ProfileDetail>;
|
|
932
|
+
find: (params?: FindProfilesParams, options?: RequestOptions$1) => Promise<{
|
|
933
|
+
items: Profile$1[];
|
|
689
934
|
cursor?: string;
|
|
690
935
|
}>;
|
|
691
|
-
update: (params:
|
|
692
|
-
merge: (params:
|
|
936
|
+
update: (params: UpdateProfileParams, options?: RequestOptions$1) => Promise<Profile$1>;
|
|
937
|
+
merge: (params: MergeProfilesParams, options?: RequestOptions$1) => Promise<Profile$1>;
|
|
938
|
+
import: (params: ImportProfilesParams, options?: RequestOptions$1) => Promise<ImportProfilesResult>;
|
|
693
939
|
revokeToken: (params: {
|
|
694
940
|
id: string;
|
|
695
941
|
token_id: string;
|
|
@@ -704,19 +950,92 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
704
950
|
deleted: boolean;
|
|
705
951
|
}>;
|
|
706
952
|
};
|
|
707
|
-
|
|
708
|
-
create
|
|
709
|
-
update
|
|
710
|
-
get
|
|
711
|
-
find
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
953
|
+
profileList: {
|
|
954
|
+
create(params: CreateProfileListParams, options?: RequestOptions$1): Promise<ProfileList>;
|
|
955
|
+
update(params: UpdateProfileListParams, options?: RequestOptions$1): Promise<ProfileList>;
|
|
956
|
+
get(params: GetProfileListParams, options?: RequestOptions$1): Promise<ProfileList>;
|
|
957
|
+
find(params?: FindProfileListsParams, options?: RequestOptions$1): Promise<PaginatedResponse<ProfileList>>;
|
|
958
|
+
importProfiles(params: ImportProfilesIntoProfileListParams, options?: RequestOptions$1): Promise<ImportProfilesIntoProfileListResult>;
|
|
959
|
+
previewImportProfiles(params: ImportProfileListPreviewParams, options?: RequestOptions$1): Promise<ImportProfilesPreviewResult>;
|
|
960
|
+
members: {
|
|
961
|
+
add(params: AddProfileListProfileParams, options?: RequestOptions$1): Promise<ProfileListMember>;
|
|
962
|
+
update(params: UpdateProfileListProfileParams, options?: RequestOptions$1): Promise<ProfileListMember>;
|
|
963
|
+
remove(params: RemoveProfileListProfileParams, options?: RequestOptions$1): Promise<{
|
|
964
|
+
deleted: boolean;
|
|
965
|
+
}>;
|
|
966
|
+
find(params: FindProfileListProfilesParams, options?: RequestOptions$1): Promise<PaginatedResponse<ProfileListMember>>;
|
|
967
|
+
};
|
|
968
|
+
profiles: {
|
|
969
|
+
add(params: AddProfileListProfileParams, options?: RequestOptions$1): Promise<ProfileListMember>;
|
|
970
|
+
update(params: UpdateProfileListProfileParams, options?: RequestOptions$1): Promise<ProfileListMember>;
|
|
971
|
+
remove(params: RemoveProfileListProfileParams, options?: RequestOptions$1): Promise<{
|
|
972
|
+
deleted: boolean;
|
|
973
|
+
}>;
|
|
974
|
+
find(params: FindProfileListProfilesParams, options?: RequestOptions$1): Promise<PaginatedResponse<ProfileListMember>>;
|
|
975
|
+
};
|
|
976
|
+
};
|
|
977
|
+
mailbox: {
|
|
978
|
+
create(params: CreateMailboxParams, options?: RequestOptions$1): Promise<Mailbox>;
|
|
979
|
+
update(params: UpdateMailboxParams, options?: RequestOptions$1): Promise<Mailbox>;
|
|
980
|
+
get(params: GetMailboxParams, options?: RequestOptions$1): Promise<Mailbox>;
|
|
981
|
+
test(params: TestMailboxParams, options?: RequestOptions$1): Promise<TestMailboxResult>;
|
|
982
|
+
prepare(params: PrepareMailboxParams, options?: RequestOptions$1): Promise<Mailbox>;
|
|
983
|
+
find(params?: FindMailboxesParams, options?: RequestOptions$1): Promise<PaginatedResponse<Mailbox>>;
|
|
984
|
+
};
|
|
985
|
+
campaign: {
|
|
986
|
+
create(params: CreateCampaignParams, options?: RequestOptions$1): Promise<Campaign>;
|
|
987
|
+
update(params: UpdateCampaignParams, options?: RequestOptions$1): Promise<Campaign>;
|
|
988
|
+
get(params: GetCampaignParams, options?: RequestOptions$1): Promise<Campaign>;
|
|
989
|
+
find(params?: FindCampaignsParams, options?: RequestOptions$1): Promise<PaginatedResponse<Campaign>>;
|
|
990
|
+
launch(params: LaunchCampaignParams, options?: RequestOptions$1): Promise<Campaign>;
|
|
991
|
+
duplicate(params: DuplicateCampaignParams, options?: RequestOptions$1): Promise<Campaign>;
|
|
992
|
+
launchReadiness(params: GetCampaignLaunchReadinessParams, options?: RequestOptions$1): Promise<CampaignLaunchReadiness>;
|
|
993
|
+
importRecipients(params: ImportCampaignRecipientsParams, options?: RequestOptions$1): Promise<CampaignRecipientImportResult>;
|
|
994
|
+
generatePersonalizedDrafts(params: GenerateOutreachPersonalizedDraftsParams, options?: RequestOptions$1): Promise<Campaign>;
|
|
995
|
+
};
|
|
996
|
+
campaignRecipient: {
|
|
997
|
+
find(params?: FindCampaignRecipientsParams, options?: RequestOptions$1): Promise<PaginatedResponse<CampaignRecipient>>;
|
|
998
|
+
get(params: GetCampaignRecipientConversationParams, options?: RequestOptions$1): Promise<CampaignRecipientConversationResponse>;
|
|
999
|
+
update(params: UpdateCampaignRecipientParams, options?: RequestOptions$1): Promise<CampaignRecipient>;
|
|
1000
|
+
updateDraft(params: UpdateCampaignRecipientDraftParams, options?: RequestOptions$1): Promise<CampaignRecipient>;
|
|
1001
|
+
reply(params: ReplyCampaignRecipientParams, options?: RequestOptions$1): Promise<CampaignRecipientConversationResponse>;
|
|
1002
|
+
stop(params: StopCampaignRecipientParams, options?: RequestOptions$1): Promise<CampaignRecipientConversationResponse>;
|
|
1003
|
+
};
|
|
1004
|
+
campaignMessage: {
|
|
1005
|
+
find(params?: FindCampaignMessagesParams, options?: RequestOptions$1): Promise<PaginatedResponse<CampaignMessage>>;
|
|
1006
|
+
update(params: UpdateCampaignMessageParams, options?: RequestOptions$1): Promise<CampaignMessage>;
|
|
1007
|
+
};
|
|
1008
|
+
suppression: {
|
|
1009
|
+
create(params: CreateSuppressionParams, options?: RequestOptions$1): Promise<Suppression>;
|
|
1010
|
+
update(params: UpdateSuppressionParams, options?: RequestOptions$1): Promise<Suppression>;
|
|
1011
|
+
get(params: GetSuppressionParams, options?: RequestOptions$1): Promise<Suppression>;
|
|
1012
|
+
find(params?: FindSuppressionsParams, options?: RequestOptions$1): Promise<PaginatedResponse<Suppression>>;
|
|
1013
|
+
};
|
|
1014
|
+
leadResearch: {
|
|
1015
|
+
run: {
|
|
1016
|
+
create: (params: CreateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1017
|
+
find: (params?: FindLeadResearchRunsParams, options?: RequestOptions$1) => Promise<PaginatedResponse<LeadResearchRun>>;
|
|
1018
|
+
get: (params: GetLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1019
|
+
update: (params: UpdateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1020
|
+
cancel: (params: CancelLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1021
|
+
sendMessage: (params: SendLeadResearchMessageParams, options?: RequestOptions$1) => Promise<SendLeadResearchMessageResult>;
|
|
1022
|
+
findMessages: (params: FindLeadResearchMessagesParams, options?: RequestOptions$1) => Promise<LeadResearchMessage[]>;
|
|
1023
|
+
};
|
|
1024
|
+
message: {
|
|
1025
|
+
send: (params: SendLeadResearchMessageParams, options?: RequestOptions$1) => Promise<SendLeadResearchMessageResult>;
|
|
1026
|
+
find: (params: FindLeadResearchMessagesParams, options?: RequestOptions$1) => Promise<LeadResearchMessage[]>;
|
|
1027
|
+
};
|
|
1028
|
+
email: {
|
|
1029
|
+
validate: (params: ValidateLeadEmailParams, options?: RequestOptions$1) => Promise<LeadEmailValidationResult>;
|
|
1030
|
+
};
|
|
1031
|
+
createRun: (params: CreateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1032
|
+
findRuns: (params?: FindLeadResearchRunsParams, options?: RequestOptions$1) => Promise<PaginatedResponse<LeadResearchRun>>;
|
|
1033
|
+
getRun: (params: GetLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1034
|
+
updateRun: (params: UpdateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1035
|
+
cancelRun: (params: CancelLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1036
|
+
sendMessage: (params: SendLeadResearchMessageParams, options?: RequestOptions$1) => Promise<SendLeadResearchMessageResult>;
|
|
1037
|
+
findMessages: (params: FindLeadResearchMessagesParams, options?: RequestOptions$1) => Promise<LeadResearchMessage[]>;
|
|
1038
|
+
validateEmail: (params: ValidateLeadEmailParams, options?: RequestOptions$1) => Promise<LeadEmailValidationResult>;
|
|
720
1039
|
};
|
|
721
1040
|
activity: {
|
|
722
1041
|
timeline(params: TimelineParams, options?: RequestOptions$1): Promise<{
|
|
@@ -729,25 +1048,33 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
729
1048
|
}>;
|
|
730
1049
|
};
|
|
731
1050
|
};
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
create: (params:
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
rateChat: (params: RateAgentChatParams, options?: RequestOptions$1) => Promise<AgentChat>;
|
|
746
|
-
getStoreChats: (params: GetStoreChatsParams, options?: RequestOptions$1) => Promise<PaginatedResponse<AgentChat>>;
|
|
747
|
-
getChatMessages: (params: GetAgentChatParams & {
|
|
748
|
-
limit?: number;
|
|
749
|
-
}, options?: RequestOptions$1) => Promise<PaginatedResponse<AgentChatMessage>>;
|
|
1051
|
+
leadResearch: {
|
|
1052
|
+
run: {
|
|
1053
|
+
create: (params: CreateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1054
|
+
find: (params?: FindLeadResearchRunsParams, options?: RequestOptions$1) => Promise<PaginatedResponse<LeadResearchRun>>;
|
|
1055
|
+
get: (params: GetLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1056
|
+
update: (params: UpdateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1057
|
+
cancel: (params: CancelLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1058
|
+
sendMessage: (params: SendLeadResearchMessageParams, options?: RequestOptions$1) => Promise<SendLeadResearchMessageResult>;
|
|
1059
|
+
findMessages: (params: FindLeadResearchMessagesParams, options?: RequestOptions$1) => Promise<LeadResearchMessage[]>;
|
|
1060
|
+
};
|
|
1061
|
+
message: {
|
|
1062
|
+
send: (params: SendLeadResearchMessageParams, options?: RequestOptions$1) => Promise<SendLeadResearchMessageResult>;
|
|
1063
|
+
find: (params: FindLeadResearchMessagesParams, options?: RequestOptions$1) => Promise<LeadResearchMessage[]>;
|
|
750
1064
|
};
|
|
1065
|
+
email: {
|
|
1066
|
+
validate: (params: ValidateLeadEmailParams, options?: RequestOptions$1) => Promise<LeadEmailValidationResult>;
|
|
1067
|
+
};
|
|
1068
|
+
createRun: (params: CreateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1069
|
+
findRuns: (params?: FindLeadResearchRunsParams, options?: RequestOptions$1) => Promise<PaginatedResponse<LeadResearchRun>>;
|
|
1070
|
+
getRun: (params: GetLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1071
|
+
updateRun: (params: UpdateLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1072
|
+
cancelRun: (params: CancelLeadResearchRunParams, options?: RequestOptions$1) => Promise<LeadResearchRun>;
|
|
1073
|
+
sendMessage: (params: SendLeadResearchMessageParams, options?: RequestOptions$1) => Promise<SendLeadResearchMessageResult>;
|
|
1074
|
+
findMessages: (params: FindLeadResearchMessagesParams, options?: RequestOptions$1) => Promise<LeadResearchMessage[]>;
|
|
1075
|
+
validateEmail: (params: ValidateLeadEmailParams, options?: RequestOptions$1) => Promise<LeadEmailValidationResult>;
|
|
1076
|
+
};
|
|
1077
|
+
automation: {
|
|
751
1078
|
workflow: {
|
|
752
1079
|
create: (params: CreateWorkflowParams, options?: RequestOptions$1) => Promise<Workflow>;
|
|
753
1080
|
update: (params: UpdateWorkflowParams, options?: RequestOptions$1) => Promise<Workflow>;
|
|
@@ -760,14 +1087,51 @@ declare function createAdmin(config: CreateAdminConfig): {
|
|
|
760
1087
|
getExecutions: (params: GetWorkflowExecutionsParams, options?: RequestOptions$1) => Promise<PaginatedResponse<WorkflowExecution>>;
|
|
761
1088
|
getExecution: (params: GetWorkflowExecutionParams, options?: RequestOptions$1) => Promise<WorkflowExecution>;
|
|
762
1089
|
};
|
|
1090
|
+
support: {
|
|
1091
|
+
agent: {
|
|
1092
|
+
create(params: CreateSupportAgentParams, opts?: RequestOptions$1): Promise<SupportAgent>;
|
|
1093
|
+
get(params: {
|
|
1094
|
+
store_id: string;
|
|
1095
|
+
id: string;
|
|
1096
|
+
}, opts?: RequestOptions$1): Promise<SupportAgent>;
|
|
1097
|
+
find(params: {
|
|
1098
|
+
store_id: string;
|
|
1099
|
+
status?: string;
|
|
1100
|
+
limit?: number;
|
|
1101
|
+
cursor?: string;
|
|
1102
|
+
}, opts?: RequestOptions$1): Promise<{
|
|
1103
|
+
items: SupportAgent[];
|
|
1104
|
+
cursor?: string;
|
|
1105
|
+
}>;
|
|
1106
|
+
update(params: UpdateSupportAgentParams, opts?: RequestOptions$1): Promise<SupportAgent>;
|
|
1107
|
+
delete(params: {
|
|
1108
|
+
store_id: string;
|
|
1109
|
+
id: string;
|
|
1110
|
+
}, opts?: RequestOptions$1): Promise<void>;
|
|
1111
|
+
};
|
|
1112
|
+
conversation: {
|
|
1113
|
+
find(params: {
|
|
1114
|
+
store_id: string;
|
|
1115
|
+
status?: string;
|
|
1116
|
+
agent_id?: string;
|
|
1117
|
+
limit?: number;
|
|
1118
|
+
cursor?: string;
|
|
1119
|
+
}, opts?: RequestOptions$1): Promise<{
|
|
1120
|
+
items: SupportConversation[];
|
|
1121
|
+
cursor?: string;
|
|
1122
|
+
}>;
|
|
1123
|
+
get(params: GetSupportConversationParams, opts?: RequestOptions$1): Promise<SupportConversationResponse>;
|
|
1124
|
+
sendMessage(params: SendSupportMessageParams, opts?: RequestOptions$1): Promise<SupportConversationResponse>;
|
|
1125
|
+
reply(params: ReplySupportConversationParams, opts?: RequestOptions$1): Promise<SupportConversationResponse>;
|
|
1126
|
+
resolve(params: ResolveSupportConversationParams, opts?: RequestOptions$1): Promise<SupportConversation>;
|
|
1127
|
+
assign(params: AssignSupportConversationParams, opts?: RequestOptions$1): Promise<SupportConversation>;
|
|
1128
|
+
};
|
|
1129
|
+
};
|
|
763
1130
|
};
|
|
764
1131
|
analytics: {
|
|
765
|
-
|
|
766
|
-
store_id?: string;
|
|
767
|
-
}) => Promise<AnalyticsQueryResponse>;
|
|
768
|
-
activityFeed: (query?: ActivityFeedQuery, options?: RequestOptions$1 & {
|
|
1132
|
+
get(request: AnalyticsRequest, options?: RequestOptions$1 & {
|
|
769
1133
|
store_id?: string;
|
|
770
|
-
})
|
|
1134
|
+
}): Promise<AnalyticsResponse>;
|
|
771
1135
|
};
|
|
772
1136
|
setStoreId: (storeId: string) => void;
|
|
773
1137
|
getStoreId: () => string;
|
|
@@ -835,15 +1199,15 @@ declare function createStorefront(config: CreateStorefrontConfig): {
|
|
|
835
1199
|
email?: string;
|
|
836
1200
|
verify?: boolean;
|
|
837
1201
|
market?: string;
|
|
838
|
-
}) => Promise<
|
|
1202
|
+
}) => Promise<ProfileSession>;
|
|
839
1203
|
verify: (params: {
|
|
840
1204
|
code: string;
|
|
841
|
-
}) => Promise<
|
|
1205
|
+
}) => Promise<ProfileToken>;
|
|
842
1206
|
logout: () => Promise<void>;
|
|
843
|
-
me: () => Promise<
|
|
844
|
-
readonly session:
|
|
1207
|
+
me: () => Promise<ProfileDetail>;
|
|
1208
|
+
readonly session: ProfileSession | null;
|
|
845
1209
|
readonly isAuthenticated: boolean;
|
|
846
|
-
onAuthStateChanged(listener: AuthStateListener<
|
|
1210
|
+
onAuthStateChanged(listener: AuthStateListener<ProfileSession>): () => void;
|
|
847
1211
|
store: {
|
|
848
1212
|
getStore(options?: RequestOptions$1): Promise<Store>;
|
|
849
1213
|
location: {
|
|
@@ -936,7 +1300,7 @@ declare function createStorefront(config: CreateStorefrontConfig): {
|
|
|
936
1300
|
};
|
|
937
1301
|
};
|
|
938
1302
|
crm: {
|
|
939
|
-
|
|
1303
|
+
profile: {
|
|
940
1304
|
identify(params?: {
|
|
941
1305
|
email?: string;
|
|
942
1306
|
verify?: boolean;
|
|
@@ -946,15 +1310,13 @@ declare function createStorefront(config: CreateStorefrontConfig): {
|
|
|
946
1310
|
code: string;
|
|
947
1311
|
}, options?: RequestOptions$1): Promise<VerifyResponse>;
|
|
948
1312
|
logout(options?: RequestOptions$1): Promise<void>;
|
|
949
|
-
getMe(options?: RequestOptions$1): Promise<
|
|
1313
|
+
getMe(options?: RequestOptions$1): Promise<ProfileDetail>;
|
|
950
1314
|
};
|
|
951
|
-
|
|
952
|
-
get(params:
|
|
953
|
-
find(params
|
|
954
|
-
subscribe(params:
|
|
955
|
-
checkAccess(params:
|
|
956
|
-
id: string;
|
|
957
|
-
}, options?: RequestOptions$1): Promise<AudienceAccessResponse>;
|
|
1315
|
+
profileList: {
|
|
1316
|
+
get(params: GetProfileListParams, options?: RequestOptions$1): Promise<ProfileList>;
|
|
1317
|
+
find(params?: FindProfileListsParams, options?: RequestOptions$1): Promise<PaginatedResponse<ProfileList>>;
|
|
1318
|
+
subscribe(params: SubscribeProfileListParams, options?: RequestOptions$1): Promise<ProfileListSubscribeResponse>;
|
|
1319
|
+
checkAccess(params: ProfileListAccessParams, options?: RequestOptions$1): Promise<ProfileListAccessResponse>;
|
|
958
1320
|
unsubscribe(token: string, options?: RequestOptions$1): Promise<{
|
|
959
1321
|
unsubscribed: boolean;
|
|
960
1322
|
}>;
|
|
@@ -967,38 +1329,10 @@ declare function createStorefront(config: CreateStorefrontConfig): {
|
|
|
967
1329
|
COMMON_ACTIVITY_TYPES: readonly ["page_view", "product_view", "service_view", "provider_view", "cart_added", "cart_removed", "checkout_started", "purchase", "order_created", "signin", "signup", "verified_email", "search", "share", "wishlist_added"];
|
|
968
1330
|
track(params: TrackParams): Promise<void>;
|
|
969
1331
|
};
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
id: string;
|
|
975
|
-
store_id?: string;
|
|
976
|
-
}, options?: RequestOptions$1): Promise<Agent>;
|
|
977
|
-
sendMessage(params: {
|
|
978
|
-
id: string;
|
|
979
|
-
message: string;
|
|
980
|
-
chat_id?: string;
|
|
981
|
-
store_id?: string;
|
|
982
|
-
}, options?: RequestOptions$1): Promise<AgentChatMessage>;
|
|
983
|
-
getChat(params: {
|
|
984
|
-
id: string;
|
|
985
|
-
chat_id: string;
|
|
986
|
-
store_id?: string;
|
|
987
|
-
}, options?: RequestOptions$1): Promise<AgentChat>;
|
|
988
|
-
getChatMessages(params: {
|
|
989
|
-
id: string;
|
|
990
|
-
chat_id: string;
|
|
991
|
-
limit?: number;
|
|
992
|
-
store_id?: string;
|
|
993
|
-
}, options?: RequestOptions$1): Promise<PaginatedResponse<AgentChatMessage>>;
|
|
994
|
-
rateChat(params: {
|
|
995
|
-
id: string;
|
|
996
|
-
chat_id: string;
|
|
997
|
-
rating: number;
|
|
998
|
-
comment?: string;
|
|
999
|
-
store_id?: string;
|
|
1000
|
-
}, options?: RequestOptions$1): Promise<AgentChat>;
|
|
1001
|
-
};
|
|
1332
|
+
support: {
|
|
1333
|
+
startConversation(params?: Omit<StartSupportConversationParams, "store_id">, opts?: RequestOptions$1): Promise<SupportConversationResponse>;
|
|
1334
|
+
sendMessage(params: Omit<SendSupportMessageParams, "store_id">, opts?: RequestOptions$1): Promise<SupportConversationResponse>;
|
|
1335
|
+
getConversation(params: Omit<GetSupportConversationParams, "store_id">, opts?: RequestOptions$1): Promise<SupportConversationResponse>;
|
|
1002
1336
|
};
|
|
1003
1337
|
setStoreId: (storeId: string) => void;
|
|
1004
1338
|
getStoreId: () => string;
|
|
@@ -1052,4 +1386,4 @@ declare function createStorefront(config: CreateStorefrontConfig): {
|
|
|
1052
1386
|
};
|
|
1053
1387
|
};
|
|
1054
1388
|
|
|
1055
|
-
export { type
|
|
1389
|
+
export { type LocationState as $, type AuthStateListener as A, type CartControllerInitParams as B, type CreateStorefrontConfig as C, type CartControllerListener as D, type CartControllerQuoteParams as E, type CartControllerRefreshParams as F, type GetSupportConversationParams as G, type CartControllerRemoveItemParams as H, type IdentifyResponse as I, type CartControllerState as J, type CartControllerUpdateParams as K, type HttpClientConfig as L, type AuthStorage as M, SDK_VERSION as N, SUPPORTED_FRAMEWORKS as O, type ProfileSession as P, type ApiConfig as Q, type AdminSessionInternal as R, type StartSupportConversationParams as S, type TrackParams as T, type ProfileSessionInternal as U, type VerifyResponse as V, type AdminSession as W, type AdminSessionUpdater as X, type ProfileSessionUpdater as Y, type CreateAdminConfig as Z, createAdmin as _, type ProfileToken as a, type LocationCountry as a0, type GetCountriesResponse as a1, type AnalyticsTimeRange as a2, type AnalyticsReportKey as a3, type AnalyticsMetricReportKey as a4, type AnalyticsBreakdownReportKey as a5, type AnalyticsActivityReportKey as a6, type AnalyticsCompositeReportKey as a7, type AnalyticsReportRequest as a8, type AnalyticsBlockRequest as a9, type SupportMessage as aA, type SupportAgentNode as aB, type SupportAgentEdge as aC, type SupportAgentAiConfig as aD, type EdgeTrigger as aE, type SupportAction as aF, type AssignSupportConversationParams as aG, type ReplySupportConversationParams as aH, type ResolveSupportConversationParams as aI, type IntegrationOperation as aJ, type IntegrationResource as aK, type IntegrationService as aL, type AnalyticsRequest as aa, type AnalyticsMetricData as ab, type AnalyticsBreakdownItem as ac, type AnalyticsBreakdownData as ad, type BusinessOverviewData as ae, type RevenueByCurrencyData as af, type ProfileFunnelStage as ag, type ProfileFunnelData as ah, type OutreachOverviewData as ai, type OutreachFunnelStage as aj, type OutreachFunnelData as ak, type OutreachVariantPerformanceItem as al, type OutreachVariantPerformanceData as am, type EntityStatusOverviewData as an, type DataHealthData as ao, type AnalyticsReport as ap, type AnalyticsBlockResponse as aq, type AnalyticsResponse as ar, type ActivityFeedCategory as as, type ActivityFeedItem as at, type ActivityFeedSummary as au, type ActivityFeedCursor as av, type ActivityFeedData as aw, type TimelineParams as ax, type SupportAgent as ay, type SupportConversation as az, type CartController as b, type SupportConversationResponse as c, type SendSupportMessageParams as d, extractBlockValues as e, formatBlockValue as f, getBlockLabel as g, findTimeZone as h, humanize as i, categorify as j, formatDate as k, getSvgContentForAstro as l, fetchSvgContent as m, injectSvgIntoElement as n, type Activity$1 as o, prepareBlocksForSubmission as p, COMMON_ACTIVITY_TYPES as q, createStorefront as r, slugify as s, createCartController as t, type CommonActivityType as u, validatePhoneNumber as v, type CartApi as w, type CartControllerAddItemParams as x, type CartControllerCheckoutParams as y, type CartControllerClearParams as z };
|