@oursprivacy/platform-sdk 1.49.0 → 1.50.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.
Files changed (57) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/client.d.mts +5 -2
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +5 -2
  5. package/client.d.ts.map +1 -1
  6. package/client.js +3 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +3 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/analytics.d.mts +62 -0
  12. package/resources/analytics.d.mts.map +1 -0
  13. package/resources/analytics.d.ts +62 -0
  14. package/resources/analytics.d.ts.map +1 -0
  15. package/resources/analytics.js +25 -0
  16. package/resources/analytics.js.map +1 -0
  17. package/resources/analytics.mjs +21 -0
  18. package/resources/analytics.mjs.map +1 -0
  19. package/resources/consent-settings.d.mts +9 -0
  20. package/resources/consent-settings.d.mts.map +1 -1
  21. package/resources/consent-settings.d.ts +9 -0
  22. package/resources/consent-settings.d.ts.map +1 -1
  23. package/resources/funnels.d.mts +88 -980
  24. package/resources/funnels.d.mts.map +1 -1
  25. package/resources/funnels.d.ts +88 -980
  26. package/resources/funnels.d.ts.map +1 -1
  27. package/resources/funnels.js +24 -19
  28. package/resources/funnels.js.map +1 -1
  29. package/resources/funnels.mjs +24 -19
  30. package/resources/funnels.mjs.map +1 -1
  31. package/resources/index.d.mts +2 -1
  32. package/resources/index.d.mts.map +1 -1
  33. package/resources/index.d.ts +2 -1
  34. package/resources/index.d.ts.map +1 -1
  35. package/resources/index.js +3 -1
  36. package/resources/index.js.map +1 -1
  37. package/resources/index.mjs +1 -0
  38. package/resources/index.mjs.map +1 -1
  39. package/resources/web-scanners.d.mts +129 -1
  40. package/resources/web-scanners.d.mts.map +1 -1
  41. package/resources/web-scanners.d.ts +129 -1
  42. package/resources/web-scanners.d.ts.map +1 -1
  43. package/resources/web-scanners.js +40 -0
  44. package/resources/web-scanners.js.map +1 -1
  45. package/resources/web-scanners.mjs +40 -0
  46. package/resources/web-scanners.mjs.map +1 -1
  47. package/src/client.ts +23 -0
  48. package/src/resources/analytics.ts +98 -0
  49. package/src/resources/consent-settings.ts +16 -0
  50. package/src/resources/funnels.ts +114 -1616
  51. package/src/resources/index.ts +10 -0
  52. package/src/resources/web-scanners.ts +220 -0
  53. package/src/version.ts +1 -1
  54. package/version.d.mts +1 -1
  55. package/version.d.ts +1 -1
  56. package/version.js +1 -1
  57. package/version.mjs +1 -1
@@ -10,6 +10,12 @@ export {
10
10
  type AllowedEventCreateParams,
11
11
  type AllowedEventUpdateParams,
12
12
  } from './allowed-events';
13
+ export {
14
+ Analytics,
15
+ type AnalyticsQueryCatalogResponse,
16
+ type AnalyticsPropertySuggestionsResponse,
17
+ type AnalyticsPropertySuggestionsParams,
18
+ } from './analytics';
13
19
  export {
14
20
  Attribution,
15
21
  type AttributionInitialResponse,
@@ -445,6 +451,8 @@ export {
445
451
  type WebScannerFindingsResponse,
446
452
  type WebScannerCookiesResponse,
447
453
  type WebScannerSummaryResponse,
454
+ type WebScannerDecisionQueueResponse,
455
+ type WebScannerResolveCoverageGapResponse,
448
456
  type WebScannerCreateParams,
449
457
  type WebScannerUpdateParams,
450
458
  type WebScannerAuthenticatedScanParams,
@@ -454,4 +462,6 @@ export {
454
462
  type WebScannerFindingsParams,
455
463
  type WebScannerCookiesParams,
456
464
  type WebScannerSummaryParams,
465
+ type WebScannerDecisionQueueParams,
466
+ type WebScannerResolveCoverageGapParams,
457
467
  } from './web-scanners';
@@ -278,6 +278,56 @@ export class WebScanners extends APIResource {
278
278
  ): APIPromise<WebScannerSummaryResponse> {
279
279
  return this._client.get(path`/rest/v1/web-scanners/${id}/summary`, { query, ...options });
280
280
  }
281
+
282
+ /**
283
+ * List every normalized host in the selected scan run that is neither covered by a
284
+ * current CMP consent service nor matched by an active suppression rule. Results
285
+ * are sorted by risk and hostname. Continue with pagination.nextCursor while
286
+ * preserving runRevision and coverageRevision; changed evidence returns HTTP 400
287
+ * and requires restarting from the first page. Historical runs are evaluated
288
+ * against current coverage configuration. Requires scope: webScanner:find
289
+ *
290
+ * @example
291
+ * ```ts
292
+ * const response = await client.webScanners.decisionQueue(
293
+ * 'id',
294
+ * );
295
+ * ```
296
+ */
297
+ decisionQueue(
298
+ id: string,
299
+ query: WebScannerDecisionQueueParams | null | undefined = {},
300
+ options?: RequestOptions,
301
+ ): APIPromise<WebScannerDecisionQueueResponse> {
302
+ return this._client.get(path`/rest/v1/web-scanners/${id}/decision-queue`, { query, ...options });
303
+ }
304
+
305
+ /**
306
+ * Resolve one hostname from a revision-bound Web Scanner decision queue by
307
+ * creating an exact-host suppression rule. The request is bound to the reviewed
308
+ * run, and retrying the same idempotency key returns the recorded outcome without
309
+ * repeating the write. Requires scope: webScanner:update
310
+ *
311
+ * @example
312
+ * ```ts
313
+ * const response =
314
+ * await client.webScanners.resolveCoverageGap('id', {
315
+ * coverageRevision: 'x',
316
+ * hostname: 'x',
317
+ * idempotencyKey: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
318
+ * runDate: '2019-12-27T18:11:19.117Z',
319
+ * runRevision: 'x',
320
+ * suppression: { reason: 'ignore' },
321
+ * });
322
+ * ```
323
+ */
324
+ resolveCoverageGap(
325
+ id: string,
326
+ body: WebScannerResolveCoverageGapParams,
327
+ options?: RequestOptions,
328
+ ): APIPromise<WebScannerResolveCoverageGapResponse> {
329
+ return this._client.post(path`/rest/v1/web-scanners/${id}/resolve-coverage-gap`, { body, ...options });
330
+ }
281
331
  }
282
332
 
283
333
  export interface WebScannerListResponse {
@@ -948,9 +998,13 @@ export interface WebScannerSummaryResponse {
948
998
  */
949
999
  accessibility?: WebScannerSummaryResponse.Accessibility | null;
950
1000
 
1001
+ coverageRevision?: string | null;
1002
+
951
1003
  delta?: WebScannerSummaryResponse.Delta | null;
952
1004
 
953
1005
  runDate?: string | null;
1006
+
1007
+ runRevision?: string | null;
954
1008
  }
955
1009
 
956
1010
  export namespace WebScannerSummaryResponse {
@@ -1181,6 +1235,117 @@ export namespace WebScannerSummaryResponse {
1181
1235
  }
1182
1236
  }
1183
1237
 
1238
+ export interface WebScannerDecisionQueueResponse {
1239
+ entities: Array<WebScannerDecisionQueueResponse.Entity>;
1240
+
1241
+ pagination: WebScannerDecisionQueueResponse.Pagination;
1242
+
1243
+ scannerId: string;
1244
+
1245
+ total: number;
1246
+
1247
+ coverageRevision?: string | null;
1248
+
1249
+ runDate?: string | null;
1250
+
1251
+ runRevision?: string | null;
1252
+ }
1253
+
1254
+ export namespace WebScannerDecisionQueueResponse {
1255
+ export interface Entity {
1256
+ hostname: string;
1257
+
1258
+ seenOn: Array<string>;
1259
+
1260
+ category?: string | null;
1261
+
1262
+ dataFlow?: Entity.DataFlow | null;
1263
+
1264
+ displayName?: string | null;
1265
+
1266
+ risk?: string | null;
1267
+ }
1268
+
1269
+ export namespace Entity {
1270
+ export interface DataFlow {
1271
+ categories: Array<
1272
+ | 'credit_card'
1273
+ | 'date_of_birth'
1274
+ | 'diagnosis'
1275
+ | 'email'
1276
+ | 'health_condition'
1277
+ | 'health_plan_id'
1278
+ | 'ip_address'
1279
+ | 'medical_record_number'
1280
+ | 'medication'
1281
+ | 'phone'
1282
+ | 'ssn'
1283
+ >;
1284
+
1285
+ recipient: DataFlow.Recipient;
1286
+
1287
+ requestCount: number;
1288
+
1289
+ signals: Array<DataFlow.Signal>;
1290
+ }
1291
+
1292
+ export namespace DataFlow {
1293
+ export interface Recipient {
1294
+ hostname: string;
1295
+
1296
+ category?: string | null;
1297
+
1298
+ displayName?: string | null;
1299
+
1300
+ risk?: string | null;
1301
+ }
1302
+
1303
+ export interface Signal {
1304
+ category:
1305
+ | 'credit_card'
1306
+ | 'date_of_birth'
1307
+ | 'diagnosis'
1308
+ | 'email'
1309
+ | 'health_condition'
1310
+ | 'health_plan_id'
1311
+ | 'ip_address'
1312
+ | 'medical_record_number'
1313
+ | 'medication'
1314
+ | 'phone'
1315
+ | 'ssn';
1316
+
1317
+ source: 'query_parameter' | 'request_body';
1318
+
1319
+ encoding?: string | null;
1320
+
1321
+ field?: string | null;
1322
+ }
1323
+ }
1324
+ }
1325
+
1326
+ export interface Pagination {
1327
+ hasMore: boolean;
1328
+
1329
+ nextCursor?: string | null;
1330
+ }
1331
+ }
1332
+
1333
+ export interface WebScannerResolveCoverageGapResponse {
1334
+ committedCoverageRevision: string;
1335
+
1336
+ coverageSource: 'cmp' | 'suppression';
1337
+
1338
+ effectState: 'preexisting_coverage' | 'suppression_active';
1339
+
1340
+ hostname: string;
1341
+
1342
+ status: 'already_resolved' | 'applied' | 'replayed';
1343
+
1344
+ coveredByVendorLabel?: string | null;
1345
+
1346
+ suppressionRuleId?: string | null;
1347
+ }
1348
+
1184
1349
  export interface WebScannerCreateParams {
1185
1350
  /**
1186
1351
  * Root domain to crawl (e.g. `example.com`). Required on create. Missing or empty
@@ -1339,12 +1504,63 @@ export interface WebScannerCookiesParams {
1339
1504
  }
1340
1505
 
1341
1506
  export interface WebScannerSummaryParams {
1507
+ coverageRevision?: string;
1508
+
1509
+ /**
1510
+ * Which scan run to read, as an ISO-8601 timestamp. Only the UTC calendar day is
1511
+ * used to select the run; the time component is ignored. Defaults to the most
1512
+ * recent run when omitted.
1513
+ */
1514
+ date?: string;
1515
+
1516
+ runRevision?: string;
1517
+ }
1518
+
1519
+ export interface WebScannerDecisionQueueParams {
1520
+ coverageRevision?: string;
1521
+
1522
+ /**
1523
+ * Opaque pagination cursor from pagination.nextCursor in the previous response. Do
1524
+ * not decode or modify it. Malformed cursors return 400 Bad Request.
1525
+ */
1526
+ cursor?: string;
1527
+
1342
1528
  /**
1343
1529
  * Which scan run to read, as an ISO-8601 timestamp. Only the UTC calendar day is
1344
1530
  * used to select the run; the time component is ignored. Defaults to the most
1345
1531
  * recent run when omitted.
1346
1532
  */
1347
1533
  date?: string;
1534
+
1535
+ /**
1536
+ * Maximum number of items to return. Defaults to 25; values below 1 are clamped to
1537
+ * 1 and values above 100 are clamped to 100.
1538
+ */
1539
+ limit?: number | null;
1540
+
1541
+ runRevision?: string;
1542
+ }
1543
+
1544
+ export interface WebScannerResolveCoverageGapParams {
1545
+ coverageRevision: string;
1546
+
1547
+ hostname: string;
1548
+
1549
+ idempotencyKey: string;
1550
+
1551
+ runDate: string;
1552
+
1553
+ runRevision: string;
1554
+
1555
+ suppression: WebScannerResolveCoverageGapParams.Suppression;
1556
+ }
1557
+
1558
+ export namespace WebScannerResolveCoverageGapParams {
1559
+ export interface Suppression {
1560
+ reason: 'ignore' | 'baa' | 'internal' | 'approved' | 'compliant' | 'firstParty' | 'other';
1561
+
1562
+ notes?: string | null;
1563
+ }
1348
1564
  }
1349
1565
 
1350
1566
  export declare namespace WebScanners {
@@ -1362,6 +1578,8 @@ export declare namespace WebScanners {
1362
1578
  type WebScannerFindingsResponse as WebScannerFindingsResponse,
1363
1579
  type WebScannerCookiesResponse as WebScannerCookiesResponse,
1364
1580
  type WebScannerSummaryResponse as WebScannerSummaryResponse,
1581
+ type WebScannerDecisionQueueResponse as WebScannerDecisionQueueResponse,
1582
+ type WebScannerResolveCoverageGapResponse as WebScannerResolveCoverageGapResponse,
1365
1583
  type WebScannerCreateParams as WebScannerCreateParams,
1366
1584
  type WebScannerUpdateParams as WebScannerUpdateParams,
1367
1585
  type WebScannerAuthenticatedScanParams as WebScannerAuthenticatedScanParams,
@@ -1371,5 +1589,7 @@ export declare namespace WebScanners {
1371
1589
  type WebScannerFindingsParams as WebScannerFindingsParams,
1372
1590
  type WebScannerCookiesParams as WebScannerCookiesParams,
1373
1591
  type WebScannerSummaryParams as WebScannerSummaryParams,
1592
+ type WebScannerDecisionQueueParams as WebScannerDecisionQueueParams,
1593
+ type WebScannerResolveCoverageGapParams as WebScannerResolveCoverageGapParams,
1374
1594
  };
1375
1595
  }
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '1.49.0'; // x-release-please-version
1
+ export const VERSION = '1.50.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "1.49.0";
1
+ export declare const VERSION = "1.50.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "1.49.0";
1
+ export declare const VERSION = "1.50.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '1.49.0'; // x-release-please-version
4
+ exports.VERSION = '1.50.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '1.49.0'; // x-release-please-version
1
+ export const VERSION = '1.50.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map