@oursprivacy/platform-sdk 1.46.0 → 1.47.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/CHANGELOG.md +7 -0
- package/client.d.mts +20 -11
- package/client.d.mts.map +1 -1
- package/client.d.ts +20 -11
- package/client.d.ts.map +1 -1
- package/client.js +11 -2
- package/client.js.map +1 -1
- package/client.mjs +11 -2
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/attribution.d.mts +9 -1
- package/resources/attribution.d.mts.map +1 -1
- package/resources/attribution.d.ts +9 -1
- package/resources/attribution.d.ts.map +1 -1
- package/resources/consent-settings.d.mts +48 -0
- package/resources/consent-settings.d.mts.map +1 -1
- package/resources/consent-settings.d.ts +48 -0
- package/resources/consent-settings.d.ts.map +1 -1
- package/resources/conversion-journey-summaries.d.mts +38 -0
- package/resources/conversion-journey-summaries.d.mts.map +1 -1
- package/resources/conversion-journey-summaries.d.ts +38 -0
- package/resources/conversion-journey-summaries.d.ts.map +1 -1
- package/resources/conversion-journey-summaries.js +38 -0
- package/resources/conversion-journey-summaries.js.map +1 -1
- package/resources/conversion-journey-summaries.mjs +38 -0
- package/resources/conversion-journey-summaries.mjs.map +1 -1
- package/resources/data-governance.d.mts +5 -5
- package/resources/data-governance.d.mts.map +1 -1
- package/resources/data-governance.d.ts +5 -5
- package/resources/data-governance.d.ts.map +1 -1
- package/resources/destinations.d.mts +7 -27
- package/resources/destinations.d.mts.map +1 -1
- package/resources/destinations.d.ts +7 -27
- package/resources/destinations.d.ts.map +1 -1
- package/resources/experiment-variants.d.mts +4 -2
- package/resources/experiment-variants.d.mts.map +1 -1
- package/resources/experiment-variants.d.ts +4 -2
- package/resources/experiment-variants.d.ts.map +1 -1
- package/resources/experiments.d.mts +677 -102
- package/resources/experiments.d.mts.map +1 -1
- package/resources/experiments.d.ts +677 -102
- package/resources/experiments.d.ts.map +1 -1
- package/resources/experiments.js +32 -2
- package/resources/experiments.js.map +1 -1
- package/resources/experiments.mjs +32 -2
- package/resources/experiments.mjs.map +1 -1
- package/resources/funnels.d.mts +172 -22
- package/resources/funnels.d.mts.map +1 -1
- package/resources/funnels.d.ts +172 -22
- package/resources/funnels.d.ts.map +1 -1
- package/resources/funnels.js +10 -2
- package/resources/funnels.js.map +1 -1
- package/resources/funnels.mjs +10 -2
- package/resources/funnels.mjs.map +1 -1
- package/resources/heatmap-pages.d.mts +42 -14
- package/resources/heatmap-pages.d.mts.map +1 -1
- package/resources/heatmap-pages.d.ts +42 -14
- package/resources/heatmap-pages.d.ts.map +1 -1
- package/resources/heatmap-pages.js +11 -7
- package/resources/heatmap-pages.js.map +1 -1
- package/resources/heatmap-pages.mjs +11 -7
- package/resources/heatmap-pages.mjs.map +1 -1
- package/resources/index.d.mts +8 -5
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +8 -5
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +7 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +3 -0
- package/resources/index.mjs.map +1 -1
- package/resources/mappings.d.mts +2 -2
- package/resources/mappings.d.mts.map +1 -1
- package/resources/mappings.d.ts +2 -2
- package/resources/mappings.d.ts.map +1 -1
- package/resources/session-replays.d.mts +91 -0
- package/resources/session-replays.d.mts.map +1 -0
- package/resources/session-replays.d.ts +91 -0
- package/resources/session-replays.d.ts.map +1 -0
- package/resources/session-replays.js +24 -0
- package/resources/session-replays.js.map +1 -0
- package/resources/session-replays.mjs +20 -0
- package/resources/session-replays.mjs.map +1 -0
- package/resources/short-links.d.mts +138 -37
- package/resources/short-links.d.mts.map +1 -1
- package/resources/short-links.d.ts +138 -37
- package/resources/short-links.d.ts.map +1 -1
- package/resources/short-links.js +27 -12
- package/resources/short-links.js.map +1 -1
- package/resources/short-links.mjs +27 -12
- package/resources/short-links.mjs.map +1 -1
- package/resources/sources.d.mts +10 -6
- package/resources/sources.d.mts.map +1 -1
- package/resources/sources.d.ts +10 -6
- package/resources/sources.d.ts.map +1 -1
- package/resources/tag-manager-tags.d.mts +2 -2
- package/resources/tag-manager-tags.d.ts +2 -2
- package/resources/tag-manager-tags.js +2 -2
- package/resources/tag-manager-tags.mjs +2 -2
- package/resources/tag-manager-triggers.d.mts +18 -1
- package/resources/tag-manager-triggers.d.mts.map +1 -1
- package/resources/tag-manager-triggers.d.ts +18 -1
- package/resources/tag-manager-triggers.d.ts.map +1 -1
- package/resources/translation-widgets.d.mts +62 -0
- package/resources/translation-widgets.d.mts.map +1 -0
- package/resources/translation-widgets.d.ts +62 -0
- package/resources/translation-widgets.d.ts.map +1 -0
- package/resources/translation-widgets.js +18 -0
- package/resources/translation-widgets.js.map +1 -0
- package/resources/translation-widgets.mjs +14 -0
- package/resources/translation-widgets.mjs.map +1 -0
- package/resources/video-channels.d.mts +17 -17
- package/resources/video-channels.d.mts.map +1 -1
- package/resources/video-channels.d.ts +17 -17
- package/resources/video-channels.d.ts.map +1 -1
- package/resources/video-channels.js +17 -16
- package/resources/video-channels.js.map +1 -1
- package/resources/video-channels.mjs +17 -16
- package/resources/video-channels.mjs.map +1 -1
- package/resources/web-analytics.d.mts +345 -0
- package/resources/web-analytics.d.mts.map +1 -0
- package/resources/web-analytics.d.ts +345 -0
- package/resources/web-analytics.d.ts.map +1 -0
- package/resources/web-analytics.js +61 -0
- package/resources/web-analytics.js.map +1 -0
- package/resources/web-analytics.mjs +57 -0
- package/resources/web-analytics.mjs.map +1 -0
- package/resources/web-scanners.d.mts +314 -14
- package/resources/web-scanners.d.mts.map +1 -1
- package/resources/web-scanners.d.ts +314 -14
- package/resources/web-scanners.d.ts.map +1 -1
- package/resources/web-scanners.js +139 -13
- package/resources/web-scanners.js.map +1 -1
- package/resources/web-scanners.mjs +139 -13
- package/resources/web-scanners.mjs.map +1 -1
- package/src/client.ts +116 -19
- package/src/resources/attribution.ts +11 -1
- package/src/resources/consent-settings.ts +56 -0
- package/src/resources/conversion-journey-summaries.ts +38 -0
- package/src/resources/data-governance.ts +5 -5
- package/src/resources/destinations.ts +18 -115
- package/src/resources/experiment-variants.ts +4 -2
- package/src/resources/experiments.ts +812 -101
- package/src/resources/funnels.ts +276 -21
- package/src/resources/heatmap-pages.ts +49 -14
- package/src/resources/index.ts +47 -3
- package/src/resources/mappings.ts +2 -2
- package/src/resources/session-replays.ts +138 -0
- package/src/resources/short-links.ts +164 -36
- package/src/resources/sources.ts +11 -0
- package/src/resources/tag-manager-tags.ts +2 -2
- package/src/resources/tag-manager-triggers.ts +18 -1
- package/src/resources/translation-widgets.ts +97 -0
- package/src/resources/video-channels.ts +19 -18
- package/src/resources/web-analytics.ts +494 -0
- package/src/resources/web-scanners.ts +443 -13
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -0,0 +1,345 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.js";
|
|
2
|
+
import { APIPromise } from "../core/api-promise.js";
|
|
3
|
+
import { RequestOptions } from "../internal/request-options.js";
|
|
4
|
+
export declare class WebAnalytics extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* Return privacy-first traffic metrics and a timeseries for the requested date
|
|
7
|
+
* range. Filter by source, geography, page, campaign, device, or other supported
|
|
8
|
+
* dimensions with the JSON-encoded `filters` query parameter. Requires scope:
|
|
9
|
+
* web-analytics:view
|
|
10
|
+
*/
|
|
11
|
+
overview(query: WebAnalyticsOverviewParams, options?: RequestOptions): APIPromise<WebAnalyticsOverviewResponse>;
|
|
12
|
+
/**
|
|
13
|
+
* Return visitor counts grouped by referrer or UTM source dimension for the
|
|
14
|
+
* requested date range. Requires scope: web-analytics:view
|
|
15
|
+
*/
|
|
16
|
+
sources(query: WebAnalyticsSourcesParams, options?: RequestOptions): APIPromise<WebAnalyticsSourcesResponse>;
|
|
17
|
+
/**
|
|
18
|
+
* Return page-level traffic metrics for top pages, entry pages, or exit pages in
|
|
19
|
+
* the requested date range. Requires scope: web-analytics:view
|
|
20
|
+
*/
|
|
21
|
+
pages(query: WebAnalyticsPagesParams, options?: RequestOptions): APIPromise<WebAnalyticsPagesResponse>;
|
|
22
|
+
/**
|
|
23
|
+
* Return visitor counts grouped by country, region, or city for the requested date
|
|
24
|
+
* range. Requires scope: web-analytics:view
|
|
25
|
+
*/
|
|
26
|
+
locations(query: WebAnalyticsLocationsParams, options?: RequestOptions): APIPromise<WebAnalyticsLocationsResponse>;
|
|
27
|
+
/**
|
|
28
|
+
* Return visitor counts grouped by device type, browser, or operating system for
|
|
29
|
+
* the requested date range. Requires scope: web-analytics:view
|
|
30
|
+
*/
|
|
31
|
+
devices(query: WebAnalyticsDevicesParams, options?: RequestOptions): APIPromise<WebAnalyticsDevicesResponse>;
|
|
32
|
+
/**
|
|
33
|
+
* Return the distinct visitors active in the most recent 15-minute window,
|
|
34
|
+
* optionally scoped to one web source. Requires scope: web-analytics:view
|
|
35
|
+
*/
|
|
36
|
+
currentVisitors(query?: WebAnalyticsCurrentVisitorsParams | null | undefined, options?: RequestOptions): APIPromise<WebAnalyticsCurrentVisitorsResponse>;
|
|
37
|
+
/**
|
|
38
|
+
* Return the next or previous journey steps for a pinned path. The `path` and
|
|
39
|
+
* `filters` query parameters are JSON-encoded arrays. Requires scope:
|
|
40
|
+
* web-analytics:view
|
|
41
|
+
*/
|
|
42
|
+
journey(query: WebAnalyticsJourneyParams, options?: RequestOptions): APIPromise<WebAnalyticsJourneyResponse>;
|
|
43
|
+
}
|
|
44
|
+
export interface WebAnalyticsOverviewResponse {
|
|
45
|
+
dataUpdatedAt: string;
|
|
46
|
+
metrics: WebAnalyticsOverviewResponse.Metrics | null;
|
|
47
|
+
timeseries: Array<WebAnalyticsOverviewResponse.Timesery> | null;
|
|
48
|
+
}
|
|
49
|
+
export declare namespace WebAnalyticsOverviewResponse {
|
|
50
|
+
interface Metrics {
|
|
51
|
+
/**
|
|
52
|
+
* Percentage from 0 to 100 of visits with exactly one pageview.
|
|
53
|
+
*/
|
|
54
|
+
bounceRate: number;
|
|
55
|
+
pageviews: number;
|
|
56
|
+
totalVisits: number;
|
|
57
|
+
uniqueVisitors: number;
|
|
58
|
+
/**
|
|
59
|
+
* Average pageviews per visit.
|
|
60
|
+
*/
|
|
61
|
+
viewsPerVisit: number;
|
|
62
|
+
/**
|
|
63
|
+
* Average visit duration in seconds.
|
|
64
|
+
*/
|
|
65
|
+
visitDuration: number;
|
|
66
|
+
}
|
|
67
|
+
interface Timesery {
|
|
68
|
+
date: string;
|
|
69
|
+
value: number;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
export interface WebAnalyticsSourcesResponse {
|
|
73
|
+
dataUpdatedAt: string;
|
|
74
|
+
rows: Array<WebAnalyticsSourcesResponse.Row>;
|
|
75
|
+
totalCount: number;
|
|
76
|
+
}
|
|
77
|
+
export declare namespace WebAnalyticsSourcesResponse {
|
|
78
|
+
interface Row {
|
|
79
|
+
name: string;
|
|
80
|
+
visitors: number;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
export interface WebAnalyticsPagesResponse {
|
|
84
|
+
dataUpdatedAt: string;
|
|
85
|
+
rows: Array<WebAnalyticsPagesResponse.Row>;
|
|
86
|
+
totalCount: number;
|
|
87
|
+
}
|
|
88
|
+
export declare namespace WebAnalyticsPagesResponse {
|
|
89
|
+
interface Row {
|
|
90
|
+
/**
|
|
91
|
+
* Percentage from 0 to 100 of visits to the page that bounced.
|
|
92
|
+
*/
|
|
93
|
+
bounceRate: number | null;
|
|
94
|
+
entries: number | null;
|
|
95
|
+
/**
|
|
96
|
+
* Percentage from 0 to 100 of pageviews that ended a visit.
|
|
97
|
+
*/
|
|
98
|
+
exitRate: number | null;
|
|
99
|
+
exits: number | null;
|
|
100
|
+
pageHostname: string;
|
|
101
|
+
pagePath: string;
|
|
102
|
+
pageviews: number | null;
|
|
103
|
+
/**
|
|
104
|
+
* Average time on page in seconds when available.
|
|
105
|
+
*/
|
|
106
|
+
timeOnPage: number | null;
|
|
107
|
+
visitors: number | null;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
export interface WebAnalyticsLocationsResponse {
|
|
111
|
+
dataUpdatedAt: string;
|
|
112
|
+
rows: Array<WebAnalyticsLocationsResponse.Row>;
|
|
113
|
+
totalCount: number;
|
|
114
|
+
}
|
|
115
|
+
export declare namespace WebAnalyticsLocationsResponse {
|
|
116
|
+
interface Row {
|
|
117
|
+
code: string | null;
|
|
118
|
+
name: string;
|
|
119
|
+
visitors: number;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
export interface WebAnalyticsDevicesResponse {
|
|
123
|
+
dataUpdatedAt: string;
|
|
124
|
+
rows: Array<WebAnalyticsDevicesResponse.Row>;
|
|
125
|
+
totalCount: number;
|
|
126
|
+
}
|
|
127
|
+
export declare namespace WebAnalyticsDevicesResponse {
|
|
128
|
+
interface Row {
|
|
129
|
+
name: string;
|
|
130
|
+
visitors: number;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
export interface WebAnalyticsCurrentVisitorsResponse {
|
|
134
|
+
count: number;
|
|
135
|
+
}
|
|
136
|
+
export interface WebAnalyticsJourneyResponse {
|
|
137
|
+
anchorSessions: number;
|
|
138
|
+
hasMore: boolean;
|
|
139
|
+
steps: Array<WebAnalyticsJourneyResponse.Step>;
|
|
140
|
+
}
|
|
141
|
+
export declare namespace WebAnalyticsJourneyResponse {
|
|
142
|
+
interface Step {
|
|
143
|
+
isOther: boolean;
|
|
144
|
+
isTerminal: boolean;
|
|
145
|
+
key: string;
|
|
146
|
+
kind: 'PAGE' | 'EVENT' | null;
|
|
147
|
+
label: string;
|
|
148
|
+
sessions: number;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
export interface WebAnalyticsOverviewParams {
|
|
152
|
+
/**
|
|
153
|
+
* Inclusive lower bound of the analysis window as `YYYY-MM-DD`.
|
|
154
|
+
*/
|
|
155
|
+
from: string;
|
|
156
|
+
/**
|
|
157
|
+
* Timeseries bucket interval. Minute queries are capped to the most recent 24
|
|
158
|
+
* hours.
|
|
159
|
+
*/
|
|
160
|
+
interval: 'minute' | 'day' | 'week' | 'month';
|
|
161
|
+
metric: 'unique_visitors' | 'total_visits' | 'pageviews' | 'views_per_visit' | 'bounce_rate' | 'visit_duration';
|
|
162
|
+
/**
|
|
163
|
+
* Inclusive upper bound of the analysis window as `YYYY-MM-DD`.
|
|
164
|
+
*/
|
|
165
|
+
to: string;
|
|
166
|
+
/**
|
|
167
|
+
* Exclude detected bot sessions. Defaults to true.
|
|
168
|
+
*/
|
|
169
|
+
excludeBots?: boolean;
|
|
170
|
+
/**
|
|
171
|
+
* Optional JSON-encoded array of up to 20 filters. Dimensions: `page`,
|
|
172
|
+
* `entry_page`, `exit_page`, `source`, `medium`, `campaign`, `content`, `term`,
|
|
173
|
+
* `referrer`, `country`, `region`, `city`, `device`, `browser`, `os`. Each filter
|
|
174
|
+
* has a dimension, optional operator (`IS`, `IS_NOT`, `CONTAINS`, `NOT_CONTAINS`;
|
|
175
|
+
* defaults to `IS`), and one or more values. Example:
|
|
176
|
+
* `[{"dimension":"country","values":["United States"]}]`.
|
|
177
|
+
*/
|
|
178
|
+
filters?: string;
|
|
179
|
+
/**
|
|
180
|
+
* Optional ISO timestamp used as the lower bound for realtime queries.
|
|
181
|
+
*/
|
|
182
|
+
realtimeFrom?: string;
|
|
183
|
+
/**
|
|
184
|
+
* Optional web source UUID. Omit to aggregate all web sources in the account.
|
|
185
|
+
*/
|
|
186
|
+
webSourceId?: string;
|
|
187
|
+
}
|
|
188
|
+
export interface WebAnalyticsSourcesParams {
|
|
189
|
+
dimension: 'referrer' | 'campaign' | 'source' | 'medium' | 'content' | 'term';
|
|
190
|
+
/**
|
|
191
|
+
* Inclusive lower bound of the analysis window as `YYYY-MM-DD`.
|
|
192
|
+
*/
|
|
193
|
+
from: string;
|
|
194
|
+
/**
|
|
195
|
+
* Inclusive upper bound of the analysis window as `YYYY-MM-DD`.
|
|
196
|
+
*/
|
|
197
|
+
to: string;
|
|
198
|
+
/**
|
|
199
|
+
* Exclude detected bot sessions. Defaults to true.
|
|
200
|
+
*/
|
|
201
|
+
excludeBots?: boolean;
|
|
202
|
+
/**
|
|
203
|
+
* Optional JSON-encoded array of up to 20 filters. Dimensions: `page`,
|
|
204
|
+
* `entry_page`, `exit_page`, `source`, `medium`, `campaign`, `content`, `term`,
|
|
205
|
+
* `referrer`, `country`, `region`, `city`, `device`, `browser`, `os`. Each filter
|
|
206
|
+
* has a dimension, optional operator (`IS`, `IS_NOT`, `CONTAINS`, `NOT_CONTAINS`;
|
|
207
|
+
* defaults to `IS`), and one or more values. Example:
|
|
208
|
+
* `[{"dimension":"country","values":["United States"]}]`.
|
|
209
|
+
*/
|
|
210
|
+
filters?: string;
|
|
211
|
+
/**
|
|
212
|
+
* Optional web source UUID. Omit to aggregate all web sources in the account.
|
|
213
|
+
*/
|
|
214
|
+
webSourceId?: string;
|
|
215
|
+
}
|
|
216
|
+
export interface WebAnalyticsPagesParams {
|
|
217
|
+
/**
|
|
218
|
+
* Inclusive lower bound of the analysis window as `YYYY-MM-DD`.
|
|
219
|
+
*/
|
|
220
|
+
from: string;
|
|
221
|
+
/**
|
|
222
|
+
* Inclusive upper bound of the analysis window as `YYYY-MM-DD`.
|
|
223
|
+
*/
|
|
224
|
+
to: string;
|
|
225
|
+
view: 'top' | 'entry' | 'exit';
|
|
226
|
+
/**
|
|
227
|
+
* Exclude detected bot sessions. Defaults to true.
|
|
228
|
+
*/
|
|
229
|
+
excludeBots?: boolean;
|
|
230
|
+
/**
|
|
231
|
+
* Optional JSON-encoded array of up to 20 filters. Dimensions: `page`,
|
|
232
|
+
* `entry_page`, `exit_page`, `source`, `medium`, `campaign`, `content`, `term`,
|
|
233
|
+
* `referrer`, `country`, `region`, `city`, `device`, `browser`, `os`. Each filter
|
|
234
|
+
* has a dimension, optional operator (`IS`, `IS_NOT`, `CONTAINS`, `NOT_CONTAINS`;
|
|
235
|
+
* defaults to `IS`), and one or more values. Example:
|
|
236
|
+
* `[{"dimension":"country","values":["United States"]}]`.
|
|
237
|
+
*/
|
|
238
|
+
filters?: string;
|
|
239
|
+
/**
|
|
240
|
+
* Optional web source UUID. Omit to aggregate all web sources in the account.
|
|
241
|
+
*/
|
|
242
|
+
webSourceId?: string;
|
|
243
|
+
}
|
|
244
|
+
export interface WebAnalyticsLocationsParams {
|
|
245
|
+
dimension: 'country' | 'region' | 'city';
|
|
246
|
+
/**
|
|
247
|
+
* Inclusive lower bound of the analysis window as `YYYY-MM-DD`.
|
|
248
|
+
*/
|
|
249
|
+
from: string;
|
|
250
|
+
/**
|
|
251
|
+
* Inclusive upper bound of the analysis window as `YYYY-MM-DD`.
|
|
252
|
+
*/
|
|
253
|
+
to: string;
|
|
254
|
+
/**
|
|
255
|
+
* Exclude detected bot sessions. Defaults to true.
|
|
256
|
+
*/
|
|
257
|
+
excludeBots?: boolean;
|
|
258
|
+
/**
|
|
259
|
+
* Optional JSON-encoded array of up to 20 filters. Dimensions: `page`,
|
|
260
|
+
* `entry_page`, `exit_page`, `source`, `medium`, `campaign`, `content`, `term`,
|
|
261
|
+
* `referrer`, `country`, `region`, `city`, `device`, `browser`, `os`. Each filter
|
|
262
|
+
* has a dimension, optional operator (`IS`, `IS_NOT`, `CONTAINS`, `NOT_CONTAINS`;
|
|
263
|
+
* defaults to `IS`), and one or more values. Example:
|
|
264
|
+
* `[{"dimension":"country","values":["United States"]}]`.
|
|
265
|
+
*/
|
|
266
|
+
filters?: string;
|
|
267
|
+
/**
|
|
268
|
+
* Optional web source UUID. Omit to aggregate all web sources in the account.
|
|
269
|
+
*/
|
|
270
|
+
webSourceId?: string;
|
|
271
|
+
}
|
|
272
|
+
export interface WebAnalyticsDevicesParams {
|
|
273
|
+
dimension: 'device' | 'browser' | 'os';
|
|
274
|
+
/**
|
|
275
|
+
* Inclusive lower bound of the analysis window as `YYYY-MM-DD`.
|
|
276
|
+
*/
|
|
277
|
+
from: string;
|
|
278
|
+
/**
|
|
279
|
+
* Inclusive upper bound of the analysis window as `YYYY-MM-DD`.
|
|
280
|
+
*/
|
|
281
|
+
to: string;
|
|
282
|
+
/**
|
|
283
|
+
* Exclude detected bot sessions. Defaults to true.
|
|
284
|
+
*/
|
|
285
|
+
excludeBots?: boolean;
|
|
286
|
+
/**
|
|
287
|
+
* Optional JSON-encoded array of up to 20 filters. Dimensions: `page`,
|
|
288
|
+
* `entry_page`, `exit_page`, `source`, `medium`, `campaign`, `content`, `term`,
|
|
289
|
+
* `referrer`, `country`, `region`, `city`, `device`, `browser`, `os`. Each filter
|
|
290
|
+
* has a dimension, optional operator (`IS`, `IS_NOT`, `CONTAINS`, `NOT_CONTAINS`;
|
|
291
|
+
* defaults to `IS`), and one or more values. Example:
|
|
292
|
+
* `[{"dimension":"country","values":["United States"]}]`.
|
|
293
|
+
*/
|
|
294
|
+
filters?: string;
|
|
295
|
+
/**
|
|
296
|
+
* Optional web source UUID. Omit to aggregate all web sources in the account.
|
|
297
|
+
*/
|
|
298
|
+
webSourceId?: string;
|
|
299
|
+
}
|
|
300
|
+
export interface WebAnalyticsCurrentVisitorsParams {
|
|
301
|
+
/**
|
|
302
|
+
* Optional web source UUID. Omit to count visitors across all account web sources.
|
|
303
|
+
*/
|
|
304
|
+
webSourceId?: string;
|
|
305
|
+
}
|
|
306
|
+
export interface WebAnalyticsJourneyParams {
|
|
307
|
+
/**
|
|
308
|
+
* Inclusive lower bound of the analysis window as `YYYY-MM-DD`.
|
|
309
|
+
*/
|
|
310
|
+
from: string;
|
|
311
|
+
/**
|
|
312
|
+
* JSON-encoded ordered path of opaque journey step keys. Use an empty array to
|
|
313
|
+
* request first-column candidates.
|
|
314
|
+
*/
|
|
315
|
+
path: string;
|
|
316
|
+
/**
|
|
317
|
+
* Inclusive upper bound of the analysis window as `YYYY-MM-DD`.
|
|
318
|
+
*/
|
|
319
|
+
to: string;
|
|
320
|
+
direction?: 'forward' | 'reverse';
|
|
321
|
+
/**
|
|
322
|
+
* Exclude detected bot sessions. Defaults to true.
|
|
323
|
+
*/
|
|
324
|
+
excludeBots?: boolean;
|
|
325
|
+
/**
|
|
326
|
+
* Optional JSON-encoded array of up to 20 journey filters. Supports web analytics
|
|
327
|
+
* dimensions plus `event_name`, `ep_currency`, `ep_appointment_id`,
|
|
328
|
+
* `ep_appointment_status`, `ep_service_line`, `ep_provider_id`, `ep_location_id`,
|
|
329
|
+
* `ep_booking_channel`, `ep_revenue_type`, `ep_call_outcome`, and `ep_staff_id`.
|
|
330
|
+
* Each filter has a dimension, optional operator (`IS`, `IS_NOT`, `CONTAINS`,
|
|
331
|
+
* `NOT_CONTAINS`; defaults to `IS`), and one or more values.
|
|
332
|
+
*/
|
|
333
|
+
filters?: string;
|
|
334
|
+
limit?: number;
|
|
335
|
+
search?: string;
|
|
336
|
+
stepKind?: 'PAGE' | 'EVENT';
|
|
337
|
+
/**
|
|
338
|
+
* Optional web source UUID. Omit to aggregate all web sources in the account.
|
|
339
|
+
*/
|
|
340
|
+
webSourceId?: string;
|
|
341
|
+
}
|
|
342
|
+
export declare namespace WebAnalytics {
|
|
343
|
+
export { type WebAnalyticsOverviewResponse as WebAnalyticsOverviewResponse, type WebAnalyticsSourcesResponse as WebAnalyticsSourcesResponse, type WebAnalyticsPagesResponse as WebAnalyticsPagesResponse, type WebAnalyticsLocationsResponse as WebAnalyticsLocationsResponse, type WebAnalyticsDevicesResponse as WebAnalyticsDevicesResponse, type WebAnalyticsCurrentVisitorsResponse as WebAnalyticsCurrentVisitorsResponse, type WebAnalyticsJourneyResponse as WebAnalyticsJourneyResponse, type WebAnalyticsOverviewParams as WebAnalyticsOverviewParams, type WebAnalyticsSourcesParams as WebAnalyticsSourcesParams, type WebAnalyticsPagesParams as WebAnalyticsPagesParams, type WebAnalyticsLocationsParams as WebAnalyticsLocationsParams, type WebAnalyticsDevicesParams as WebAnalyticsDevicesParams, type WebAnalyticsCurrentVisitorsParams as WebAnalyticsCurrentVisitorsParams, type WebAnalyticsJourneyParams as WebAnalyticsJourneyParams, };
|
|
344
|
+
}
|
|
345
|
+
//# sourceMappingURL=web-analytics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-analytics.d.ts","sourceRoot":"","sources":["../src/resources/web-analytics.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAE7D,qBAAa,YAAa,SAAQ,WAAW;IAC3C;;;;;OAKG;IACH,QAAQ,CACN,KAAK,EAAE,0BAA0B,EACjC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,4BAA4B,CAAC;IAI3C;;;OAGG;IACH,OAAO,CACL,KAAK,EAAE,yBAAyB,EAChC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,2BAA2B,CAAC;IAI1C;;;OAGG;IACH,KAAK,CAAC,KAAK,EAAE,uBAAuB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,yBAAyB,CAAC;IAItG;;;OAGG;IACH,SAAS,CACP,KAAK,EAAE,2BAA2B,EAClC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,6BAA6B,CAAC;IAI5C;;;OAGG;IACH,OAAO,CACL,KAAK,EAAE,yBAAyB,EAChC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,2BAA2B,CAAC;IAI1C;;;OAGG;IACH,eAAe,CACb,KAAK,GAAE,iCAAiC,GAAG,IAAI,GAAG,SAAc,EAChE,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,mCAAmC,CAAC;IAIlD;;;;OAIG;IACH,OAAO,CACL,KAAK,EAAE,yBAAyB,EAChC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,2BAA2B,CAAC;CAG3C;AAED,MAAM,WAAW,4BAA4B;IAC3C,aAAa,EAAE,MAAM,CAAC;IAEtB,OAAO,EAAE,4BAA4B,CAAC,OAAO,GAA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jE,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,mCAAmC,IAAI,mCAAmC,EAC/E,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,iCAAiC,IAAI,iCAAiC,EAC3E,KAAK,yBAAyB,IAAI,yBAAyB,GAC5D,CAAC;CACH"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.WebAnalytics = void 0;
|
|
5
|
+
const resource_1 = require("../core/resource.js");
|
|
6
|
+
class WebAnalytics extends resource_1.APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* Return privacy-first traffic metrics and a timeseries for the requested date
|
|
9
|
+
* range. Filter by source, geography, page, campaign, device, or other supported
|
|
10
|
+
* dimensions with the JSON-encoded `filters` query parameter. Requires scope:
|
|
11
|
+
* web-analytics:view
|
|
12
|
+
*/
|
|
13
|
+
overview(query, options) {
|
|
14
|
+
return this._client.get('/rest/v1/web-analytics/overview', { query, ...options });
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Return visitor counts grouped by referrer or UTM source dimension for the
|
|
18
|
+
* requested date range. Requires scope: web-analytics:view
|
|
19
|
+
*/
|
|
20
|
+
sources(query, options) {
|
|
21
|
+
return this._client.get('/rest/v1/web-analytics/sources', { query, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Return page-level traffic metrics for top pages, entry pages, or exit pages in
|
|
25
|
+
* the requested date range. Requires scope: web-analytics:view
|
|
26
|
+
*/
|
|
27
|
+
pages(query, options) {
|
|
28
|
+
return this._client.get('/rest/v1/web-analytics/pages', { query, ...options });
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Return visitor counts grouped by country, region, or city for the requested date
|
|
32
|
+
* range. Requires scope: web-analytics:view
|
|
33
|
+
*/
|
|
34
|
+
locations(query, options) {
|
|
35
|
+
return this._client.get('/rest/v1/web-analytics/locations', { query, ...options });
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Return visitor counts grouped by device type, browser, or operating system for
|
|
39
|
+
* the requested date range. Requires scope: web-analytics:view
|
|
40
|
+
*/
|
|
41
|
+
devices(query, options) {
|
|
42
|
+
return this._client.get('/rest/v1/web-analytics/devices', { query, ...options });
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Return the distinct visitors active in the most recent 15-minute window,
|
|
46
|
+
* optionally scoped to one web source. Requires scope: web-analytics:view
|
|
47
|
+
*/
|
|
48
|
+
currentVisitors(query = {}, options) {
|
|
49
|
+
return this._client.get('/rest/v1/web-analytics/current-visitors', { query, ...options });
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Return the next or previous journey steps for a pinned path. The `path` and
|
|
53
|
+
* `filters` query parameters are JSON-encoded arrays. Requires scope:
|
|
54
|
+
* web-analytics:view
|
|
55
|
+
*/
|
|
56
|
+
journey(query, options) {
|
|
57
|
+
return this._client.get('/rest/v1/web-analytics/journey', { query, ...options });
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
exports.WebAnalytics = WebAnalytics;
|
|
61
|
+
//# sourceMappingURL=web-analytics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-analytics.js","sourceRoot":"","sources":["../src/resources/web-analytics.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C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AAC;IACnF,CAAC;CACF;AA7ED,oCA6EC"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../core/resource.mjs";
|
|
3
|
+
export class WebAnalytics extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* Return privacy-first traffic metrics and a timeseries for the requested date
|
|
6
|
+
* range. Filter by source, geography, page, campaign, device, or other supported
|
|
7
|
+
* dimensions with the JSON-encoded `filters` query parameter. Requires scope:
|
|
8
|
+
* web-analytics:view
|
|
9
|
+
*/
|
|
10
|
+
overview(query, options) {
|
|
11
|
+
return this._client.get('/rest/v1/web-analytics/overview', { query, ...options });
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Return visitor counts grouped by referrer or UTM source dimension for the
|
|
15
|
+
* requested date range. Requires scope: web-analytics:view
|
|
16
|
+
*/
|
|
17
|
+
sources(query, options) {
|
|
18
|
+
return this._client.get('/rest/v1/web-analytics/sources', { query, ...options });
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Return page-level traffic metrics for top pages, entry pages, or exit pages in
|
|
22
|
+
* the requested date range. Requires scope: web-analytics:view
|
|
23
|
+
*/
|
|
24
|
+
pages(query, options) {
|
|
25
|
+
return this._client.get('/rest/v1/web-analytics/pages', { query, ...options });
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Return visitor counts grouped by country, region, or city for the requested date
|
|
29
|
+
* range. Requires scope: web-analytics:view
|
|
30
|
+
*/
|
|
31
|
+
locations(query, options) {
|
|
32
|
+
return this._client.get('/rest/v1/web-analytics/locations', { query, ...options });
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Return visitor counts grouped by device type, browser, or operating system for
|
|
36
|
+
* the requested date range. Requires scope: web-analytics:view
|
|
37
|
+
*/
|
|
38
|
+
devices(query, options) {
|
|
39
|
+
return this._client.get('/rest/v1/web-analytics/devices', { query, ...options });
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Return the distinct visitors active in the most recent 15-minute window,
|
|
43
|
+
* optionally scoped to one web source. Requires scope: web-analytics:view
|
|
44
|
+
*/
|
|
45
|
+
currentVisitors(query = {}, options) {
|
|
46
|
+
return this._client.get('/rest/v1/web-analytics/current-visitors', { query, ...options });
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Return the next or previous journey steps for a pinned path. The `path` and
|
|
50
|
+
* `filters` query parameters are JSON-encoded arrays. Requires scope:
|
|
51
|
+
* web-analytics:view
|
|
52
|
+
*/
|
|
53
|
+
journey(query, options) {
|
|
54
|
+
return this._client.get('/rest/v1/web-analytics/journey', { query, ...options });
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=web-analytics.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-analytics.mjs","sourceRoot":"","sources":["../src/resources/web-analytics.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAI/C,MAAM,OAAO,YAAa,SAAQ,WAAW;IAC3C;;;;;OAKG;IACH,QAAQ,CACN,KAAiC,EACjC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,iCAAiC,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;IAED;;;OAGG;IACH,OAAO,CACL,KAAgC,EAChC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,gCAAgC,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACnF,CAAC;IAED;;;OAGG;IACH,KAAK,CAAC,KAA8B,EAAE,OAAwB;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,8BAA8B,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC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