@oursprivacy/platform-sdk 1.59.0 → 1.61.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 +14 -0
- package/README.md +58 -15
- package/client.d.mts.map +1 -1
- package/client.d.ts.map +1 -1
- package/client.js +10 -1
- package/client.js.map +1 -1
- package/client.mjs +10 -1
- package/client.mjs.map +1 -1
- package/core/error.d.mts.map +1 -1
- package/core/error.d.ts.map +1 -1
- package/core/error.js +2 -1
- package/core/error.js.map +1 -1
- package/core/error.mjs +2 -1
- package/core/error.mjs.map +1 -1
- package/internal/utils/log.d.mts +5 -0
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts +5 -0
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js +62 -1
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +60 -0
- package/internal/utils/log.mjs.map +1 -1
- package/package.json +1 -12
- package/resources/destinations.d.mts +7 -7
- package/resources/destinations.d.mts.map +1 -1
- package/resources/destinations.d.ts +7 -7
- package/resources/destinations.d.ts.map +1 -1
- package/resources/experiment-settings.d.mts +24 -14
- package/resources/experiment-settings.d.mts.map +1 -1
- package/resources/experiment-settings.d.ts +24 -14
- package/resources/experiment-settings.d.ts.map +1 -1
- package/resources/experiment-settings.js +8 -4
- package/resources/experiment-settings.js.map +1 -1
- package/resources/experiment-settings.mjs +8 -4
- package/resources/experiment-settings.mjs.map +1 -1
- package/resources/heatmap-pages.d.mts +51 -28
- package/resources/heatmap-pages.d.mts.map +1 -1
- package/resources/heatmap-pages.d.ts +51 -28
- package/resources/heatmap-pages.d.ts.map +1 -1
- package/resources/heatmap-pages.js +23 -17
- package/resources/heatmap-pages.js.map +1 -1
- package/resources/heatmap-pages.mjs +23 -17
- package/resources/heatmap-pages.mjs.map +1 -1
- package/resources/test-events.d.mts +6 -0
- package/resources/test-events.d.mts.map +1 -1
- package/resources/test-events.d.ts +6 -0
- package/resources/test-events.d.ts.map +1 -1
- package/resources/web-scanners.d.mts +6 -3
- package/resources/web-scanners.d.mts.map +1 -1
- package/resources/web-scanners.d.ts +6 -3
- package/resources/web-scanners.d.ts.map +1 -1
- package/resources/web-scanners.js +4 -1
- package/resources/web-scanners.js.map +1 -1
- package/resources/web-scanners.mjs +4 -1
- package/resources/web-scanners.mjs.map +1 -1
- package/src/client.ts +10 -0
- package/src/core/error.ts +2 -1
- package/src/internal/utils/log.ts +64 -0
- package/src/resources/destinations.ts +9 -2
- package/src/resources/experiment-settings.ts +24 -14
- package/src/resources/heatmap-pages.ts +53 -28
- package/src/resources/test-events.ts +7 -0
- package/src/resources/web-scanners.ts +6 -3
- 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
|
@@ -8,14 +8,15 @@ import { RequestOptions } from '../internal/request-options';
|
|
|
8
8
|
export class HeatmapPages extends APIResource {
|
|
9
9
|
/**
|
|
10
10
|
* List pages with heatmap coverage in a date window, ranked for triage. Each
|
|
11
|
-
* entity is identified by `pageKey
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* `GET /rest/v1/heatmap-pages/summary`.
|
|
15
|
-
* depth capped at roughly 10,000 entries;
|
|
16
|
-
* `from`/`to` or add filters rather than
|
|
17
|
-
* calendar days in `YYYY-MM-DD`; the
|
|
18
|
-
* API-key scope or current OAuth user
|
|
11
|
+
* entity is identified by `pageKey` (origin + pathname, query string stripped).
|
|
12
|
+
* Use `queryParameterFilter` to inspect one survey step or other URL parameter
|
|
13
|
+
* value; filtering narrows events without creating separate page rows. Pass the
|
|
14
|
+
* same filter and returned `pageKey` to `GET /rest/v1/heatmap-pages/summary`.
|
|
15
|
+
* Supports cursor pagination, with cursor depth capped at roughly 10,000 entries;
|
|
16
|
+
* if you need pages beyond that, narrow `from`/`to` or add filters rather than
|
|
17
|
+
* paginating further. `from`/`to` are UTC calendar days in `YYYY-MM-DD`; the
|
|
18
|
+
* window must be 60 days or fewer. Requires API-key scope or current OAuth user
|
|
19
|
+
* permission: web-analytics:view
|
|
19
20
|
*/
|
|
20
21
|
list(
|
|
21
22
|
query: HeatmapPageListParams,
|
|
@@ -32,15 +33,20 @@ export class HeatmapPages extends APIResource {
|
|
|
32
33
|
* depth, and up to 5 curated in-app replay URLs in a single payload. Designed as a
|
|
33
34
|
* one-call diagnosis surface for an AI assistant or marketer — answers "what is
|
|
34
35
|
* happening on this page?" without fanning out across five endpoints. `pageKey`
|
|
35
|
-
* comes from `GET /rest/v1/heatmap-pages`.
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
* `
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
36
|
+
* comes from `GET /rest/v1/heatmap-pages`. A base key includes all query variants
|
|
37
|
+
* regardless of saved splits. Reuse the same `queryParameterFilter` to scope all
|
|
38
|
+
* aggregates and replay links to the selected survey step. Legacy saved split keys
|
|
39
|
+
* remain supported without a filter; combining a query string in `pageKey` with
|
|
40
|
+
* `queryParameterFilter` returns 400. This reads retained historical events
|
|
41
|
+
* containing the parameter, requires no account setting, and does not change
|
|
42
|
+
* web-analytics page paths. The endpoint is identified by query params rather than
|
|
43
|
+
* a path id because heatmap pages are not stored entities; this is a documented
|
|
44
|
+
* derived-read exception. `breakpoint` scopes the bin/scroll aggregations; replays
|
|
45
|
+
* are returned across all breakpoints regardless of `breakpoint` (weighted to
|
|
46
|
+
* cover multiple viewports) so callers can compare devices. `clickGrid` always
|
|
47
|
+
* supplies fine click positions for rendering. `clickBins` derives compatible
|
|
48
|
+
* 64×64 counts from the same grid; its totals must not be added to them. Requires
|
|
49
|
+
* API-key scope or current OAuth user permission: web-analytics:view
|
|
44
50
|
*/
|
|
45
51
|
summary(query: HeatmapPageSummaryParams, options?: RequestOptions): APIPromise<HeatmapPageSummaryResponse> {
|
|
46
52
|
return this._client.get('/rest/v1/heatmap-pages/summary', { query, ...options });
|
|
@@ -59,10 +65,9 @@ export interface HeatmapPageListResponse {
|
|
|
59
65
|
issueScore: number;
|
|
60
66
|
|
|
61
67
|
/**
|
|
62
|
-
* Stable per-page identifier
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
* `GET /rest/v1/heatmap-pages/summary` and the heatmap MCP tools.
|
|
68
|
+
* Stable per-page identifier: origin + pathname with the query string stripped.
|
|
69
|
+
* Query-parameter filtering narrows events without changing this key. Use the same
|
|
70
|
+
* filter when requesting the page summary.
|
|
66
71
|
*/
|
|
67
72
|
pageKey: string;
|
|
68
73
|
|
|
@@ -175,7 +180,7 @@ export namespace HeatmapPageSummaryResponse {
|
|
|
175
180
|
/**
|
|
176
181
|
* Viewport bucket the session was recorded under.
|
|
177
182
|
*/
|
|
178
|
-
breakpoint: '
|
|
183
|
+
breakpoint: 'mobile' | 'tablet' | 'desktop';
|
|
179
184
|
|
|
180
185
|
/**
|
|
181
186
|
* Absolute link to view the session replay in the OursPrivacy web app. Opens the
|
|
@@ -216,6 +221,16 @@ export interface HeatmapPageListParams extends CursorParams {
|
|
|
216
221
|
*/
|
|
217
222
|
country?: string;
|
|
218
223
|
|
|
224
|
+
/**
|
|
225
|
+
* Filter heatmap events by one URL query parameter, such as
|
|
226
|
+
* {"name":"p","values":["Contact Details"]}. Send as JSON in an HTTP query string
|
|
227
|
+
* and as an object in MCP. Matches any listed decoded value; values: [] matches
|
|
228
|
+
* any non-empty value. Apply the same filter to the list and summary. Works on
|
|
229
|
+
* retained historical events containing the parameter, requires no account
|
|
230
|
+
* setting, and does not change web-analytics page paths.
|
|
231
|
+
*/
|
|
232
|
+
queryParameterFilter?: string;
|
|
233
|
+
|
|
219
234
|
/**
|
|
220
235
|
* Filter by visitor region (state/province as stored on events).
|
|
221
236
|
*/
|
|
@@ -229,7 +244,7 @@ export interface HeatmapPageListParams extends CursorParams {
|
|
|
229
244
|
/**
|
|
230
245
|
* Sort key. Defaults to `CLICKS` (descending).
|
|
231
246
|
*/
|
|
232
|
-
sortBy?: 'CLICKS' | '
|
|
247
|
+
sortBy?: 'CLICKS' | 'RAGE_RATE' | 'DEAD_RATE' | 'ISSUE_SCORE';
|
|
233
248
|
|
|
234
249
|
/**
|
|
235
250
|
* Sort direction. Defaults to `DESC`.
|
|
@@ -243,7 +258,7 @@ export interface HeatmapPageSummaryParams {
|
|
|
243
258
|
* computed for. Replays are returned for all breakpoints regardless of this value
|
|
244
259
|
* so callers can compare across devices.
|
|
245
260
|
*/
|
|
246
|
-
breakpoint: '
|
|
261
|
+
breakpoint: 'mobile' | 'tablet' | 'desktop';
|
|
247
262
|
|
|
248
263
|
/**
|
|
249
264
|
* Inclusive lower bound of the heatmap window, as a UTC calendar day in
|
|
@@ -253,10 +268,10 @@ export interface HeatmapPageSummaryParams {
|
|
|
253
268
|
from: string;
|
|
254
269
|
|
|
255
270
|
/**
|
|
256
|
-
*
|
|
257
|
-
*
|
|
258
|
-
*
|
|
259
|
-
*
|
|
271
|
+
* Base page identifier returned by the heatmap pages list. Pass it unchanged,
|
|
272
|
+
* together with the same queryParameterFilter to inspect the same survey step. A
|
|
273
|
+
* legacy saved split key is accepted only without queryParameterFilter; combining
|
|
274
|
+
* them returns 400.
|
|
260
275
|
*/
|
|
261
276
|
pageKey: string;
|
|
262
277
|
|
|
@@ -277,6 +292,16 @@ export interface HeatmapPageSummaryParams {
|
|
|
277
292
|
*/
|
|
278
293
|
country?: string;
|
|
279
294
|
|
|
295
|
+
/**
|
|
296
|
+
* Filter heatmap events by one URL query parameter, such as
|
|
297
|
+
* {"name":"p","values":["Contact Details"]}. Send as JSON in an HTTP query string
|
|
298
|
+
* and as an object in MCP. Matches any listed decoded value; values: [] matches
|
|
299
|
+
* any non-empty value. Apply the same filter to the list and summary. Works on
|
|
300
|
+
* retained historical events containing the parameter, requires no account
|
|
301
|
+
* setting, and does not change web-analytics page paths.
|
|
302
|
+
*/
|
|
303
|
+
queryParameterFilter?: string;
|
|
304
|
+
|
|
280
305
|
/**
|
|
281
306
|
* Filter by visitor region (state/province as stored on events).
|
|
282
307
|
*/
|
|
@@ -331,6 +331,13 @@ export namespace TestEventCreateParams {
|
|
|
331
331
|
*/
|
|
332
332
|
adset_id?: string | null;
|
|
333
333
|
|
|
334
|
+
/**
|
|
335
|
+
* The raw Affiliatly tracking cookie value (affiliatly_v3), set by the Affiliatly
|
|
336
|
+
* script when a visitor lands from an affiliate link. Web-only. Ex:
|
|
337
|
+
* id_hash=abc&id_user=123&aff_uid=45
|
|
338
|
+
*/
|
|
339
|
+
affiliatly_v3?: string | null;
|
|
340
|
+
|
|
334
341
|
/**
|
|
335
342
|
* The AppLovin alart query parameter. Ex: alart123
|
|
336
343
|
*/
|
|
@@ -246,11 +246,14 @@ export class WebScanners extends APIResource {
|
|
|
246
246
|
* used to select the run) to read an earlier run. Cookies paginate with `limit`
|
|
247
247
|
* and `offset` (a documented exception to the cursor-pagination standard, since
|
|
248
248
|
* each run is an immutable snapshot); local-storage entries are returned in full.
|
|
249
|
+
* A missing id and an id this credential cannot access return the same 404.
|
|
249
250
|
* Requires API-key scope or current OAuth user permission: webScanner:find
|
|
250
251
|
*
|
|
251
252
|
* @example
|
|
252
253
|
* ```ts
|
|
253
|
-
* const response = await client.webScanners.cookies(
|
|
254
|
+
* const response = await client.webScanners.cookies(
|
|
255
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
256
|
+
* );
|
|
254
257
|
* ```
|
|
255
258
|
*/
|
|
256
259
|
cookies(
|
|
@@ -1625,12 +1628,12 @@ export interface WebScannerCookiesParams {
|
|
|
1625
1628
|
date?: string;
|
|
1626
1629
|
|
|
1627
1630
|
/**
|
|
1628
|
-
* Maximum number of
|
|
1631
|
+
* Maximum number of cookies to return, from 1 to 100. Defaults to 25.
|
|
1629
1632
|
*/
|
|
1630
1633
|
limit?: number;
|
|
1631
1634
|
|
|
1632
1635
|
/**
|
|
1633
|
-
* Skip this many
|
|
1636
|
+
* Skip this many cookies before returning. Use with `limit` for load-more paging.
|
|
1634
1637
|
*/
|
|
1635
1638
|
offset?: number | null;
|
|
1636
1639
|
}
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '1.
|
|
1
|
+
export const VERSION = '1.61.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.61.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "1.
|
|
1
|
+
export declare const VERSION = "1.61.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '1.
|
|
1
|
+
export const VERSION = '1.61.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|