@oursprivacy/platform-sdk 1.19.0 → 1.21.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 +31 -0
- package/README.md +8 -12
- package/api-promise.d.mts +1 -0
- package/api-promise.d.mts.map +1 -1
- package/api-promise.d.ts +1 -0
- package/api-promise.d.ts.map +1 -1
- package/api-promise.mjs +1 -0
- package/api-promise.mjs.map +1 -1
- package/client.d.mts +21 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +21 -6
- package/client.d.ts.map +1 -1
- package/client.js +17 -2
- package/client.js.map +1 -1
- package/client.mjs +17 -2
- package/client.mjs.map +1 -1
- package/core/api-promise.d.mts.map +1 -1
- package/core/api-promise.d.ts.map +1 -1
- package/core/api-promise.mjs.map +1 -1
- package/core/error.mjs.map +1 -1
- package/core/pagination.d.mts.map +1 -1
- package/core/pagination.d.ts.map +1 -1
- package/core/pagination.mjs.map +1 -1
- package/core/resource.d.mts.map +1 -1
- package/core/resource.d.ts.map +1 -1
- package/core/uploads.d.mts.map +1 -1
- package/core/uploads.d.ts.map +1 -1
- package/core/uploads.mjs.map +1 -1
- package/error.d.mts +1 -0
- package/error.d.mts.map +1 -1
- package/error.d.ts +1 -0
- package/error.d.ts.map +1 -1
- package/error.mjs +1 -0
- package/error.mjs.map +1 -1
- package/index.d.mts.map +1 -1
- package/index.d.ts.map +1 -1
- package/index.mjs.map +1 -1
- package/internal/detect-platform.mjs.map +1 -1
- package/internal/headers.mjs.map +1 -1
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.mjs.map +1 -1
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts.map +1 -1
- package/internal/shims.d.mts +6 -0
- package/internal/shims.d.mts.map +1 -1
- package/internal/shims.d.ts +6 -0
- package/internal/shims.d.ts.map +1 -1
- package/internal/to-file.d.mts.map +1 -1
- package/internal/to-file.d.ts.map +1 -1
- package/internal/to-file.mjs.map +1 -1
- package/internal/types.d.mts +4 -4
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +4 -4
- package/internal/types.d.ts.map +1 -1
- package/internal/uploads.d.mts.map +1 -1
- package/internal/uploads.d.ts.map +1 -1
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/base64.mjs.map +1 -1
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/path.mjs.map +1 -1
- package/internal/utils/query.mjs.map +1 -1
- package/internal/utils/values.mjs.map +1 -1
- package/internal/utils.d.mts.map +1 -1
- package/internal/utils.d.ts.map +1 -1
- package/internal/utils.mjs.map +1 -1
- package/package.json +1 -1
- package/pagination.d.mts +1 -0
- package/pagination.d.mts.map +1 -1
- package/pagination.d.ts +1 -0
- package/pagination.d.ts.map +1 -1
- package/pagination.mjs +1 -0
- package/pagination.mjs.map +1 -1
- package/resource.d.mts +1 -0
- package/resource.d.mts.map +1 -1
- package/resource.d.ts +1 -0
- package/resource.d.ts.map +1 -1
- package/resource.mjs +1 -0
- package/resource.mjs.map +1 -1
- package/resources/allowed-events.d.mts.map +1 -1
- package/resources/allowed-events.d.ts.map +1 -1
- package/resources/allowed-events.mjs.map +1 -1
- package/resources/consent-settings.d.mts.map +1 -1
- package/resources/consent-settings.d.ts.map +1 -1
- package/resources/consent-settings.mjs.map +1 -1
- package/resources/default-mappings.d.mts +140 -0
- package/resources/default-mappings.d.mts.map +1 -0
- package/resources/default-mappings.d.ts +140 -0
- package/resources/default-mappings.d.ts.map +1 -0
- package/resources/default-mappings.js +38 -0
- package/resources/default-mappings.js.map +1 -0
- package/resources/default-mappings.mjs +34 -0
- package/resources/default-mappings.mjs.map +1 -0
- package/resources/destination-types.d.mts +21 -13
- package/resources/destination-types.d.mts.map +1 -1
- package/resources/destination-types.d.ts +21 -13
- package/resources/destination-types.d.ts.map +1 -1
- package/resources/destination-types.js.map +1 -1
- package/resources/destination-types.mjs.map +1 -1
- package/resources/destinations.d.mts +61 -98
- package/resources/destinations.d.mts.map +1 -1
- package/resources/destinations.d.ts +61 -98
- package/resources/destinations.d.ts.map +1 -1
- package/resources/destinations.js +11 -13
- package/resources/destinations.js.map +1 -1
- package/resources/destinations.mjs +11 -13
- package/resources/destinations.mjs.map +1 -1
- package/resources/experiment-settings.d.mts.map +1 -1
- package/resources/experiment-settings.d.ts.map +1 -1
- package/resources/experiment-settings.mjs.map +1 -1
- package/resources/experiment-variants.d.mts.map +1 -1
- package/resources/experiment-variants.d.ts.map +1 -1
- package/resources/experiment-variants.mjs.map +1 -1
- package/resources/experiments.d.mts.map +1 -1
- package/resources/experiments.d.ts.map +1 -1
- package/resources/experiments.mjs.map +1 -1
- package/resources/global-dispatch-centers.d.mts.map +1 -1
- package/resources/global-dispatch-centers.d.ts.map +1 -1
- package/resources/global-dispatch-centers.mjs.map +1 -1
- package/resources/heatmap-pages.d.mts.map +1 -1
- package/resources/heatmap-pages.d.ts.map +1 -1
- package/resources/heatmap-pages.mjs.map +1 -1
- package/resources/index.d.mts +7 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +7 -2
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +11 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +5 -0
- package/resources/index.mjs.map +1 -1
- package/resources/locations.d.mts +270 -0
- package/resources/locations.d.mts.map +1 -0
- package/resources/locations.d.ts +270 -0
- package/resources/locations.d.ts.map +1 -0
- package/resources/locations.js +48 -0
- package/resources/locations.js.map +1 -0
- package/resources/locations.mjs +44 -0
- package/resources/locations.mjs.map +1 -0
- package/resources/mapping-templates.d.mts +101 -0
- package/resources/mapping-templates.d.mts.map +1 -0
- package/resources/mapping-templates.d.ts +101 -0
- package/resources/mapping-templates.d.ts.map +1 -0
- package/resources/mapping-templates.js +22 -0
- package/resources/mapping-templates.js.map +1 -0
- package/resources/mapping-templates.mjs +18 -0
- package/resources/mapping-templates.mjs.map +1 -0
- package/resources/mappings.d.mts +186 -6
- package/resources/mappings.d.mts.map +1 -1
- package/resources/mappings.d.ts +186 -6
- package/resources/mappings.d.ts.map +1 -1
- package/resources/mappings.js +26 -3
- package/resources/mappings.js.map +1 -1
- package/resources/mappings.mjs +26 -3
- package/resources/mappings.mjs.map +1 -1
- package/resources/replay-settings.d.mts.map +1 -1
- package/resources/replay-settings.d.ts.map +1 -1
- package/resources/replay-settings.mjs.map +1 -1
- package/resources/sources.d.mts.map +1 -1
- package/resources/sources.d.ts.map +1 -1
- package/resources/sources.mjs.map +1 -1
- package/resources/versions.d.mts.map +1 -1
- package/resources/versions.d.ts.map +1 -1
- package/resources/versions.mjs.map +1 -1
- package/resources/web-scanner-rules.d.mts +195 -0
- package/resources/web-scanner-rules.d.mts.map +1 -0
- package/resources/web-scanner-rules.d.ts +195 -0
- package/resources/web-scanner-rules.d.ts.map +1 -0
- package/resources/web-scanner-rules.js +48 -0
- package/resources/web-scanner-rules.js.map +1 -0
- package/resources/web-scanner-rules.mjs +44 -0
- package/resources/web-scanner-rules.mjs.map +1 -0
- package/resources/web-scanners.d.mts +199 -0
- package/resources/web-scanners.d.mts.map +1 -0
- package/resources/web-scanners.d.ts +199 -0
- package/resources/web-scanners.d.ts.map +1 -0
- package/resources/web-scanners.js +67 -0
- package/resources/web-scanners.js.map +1 -0
- package/resources/web-scanners.mjs +63 -0
- package/resources/web-scanners.mjs.map +1 -0
- package/resources.d.mts.map +1 -1
- package/resources.d.ts.map +1 -1
- package/resources.mjs.map +1 -1
- package/src/client.ts +116 -5
- package/src/resources/default-mappings.ts +332 -0
- package/src/resources/destination-types.ts +117 -202
- package/src/resources/destinations.ts +227 -212
- package/src/resources/index.ts +48 -0
- package/src/resources/locations.ts +463 -0
- package/src/resources/mapping-templates.ts +203 -0
- package/src/resources/mappings.ts +320 -5
- package/src/resources/web-scanner-rules.ts +304 -0
- package/src/resources/web-scanners.ts +333 -0
- package/src/version.ts +1 -1
- package/uploads.d.mts +1 -0
- package/uploads.d.mts.map +1 -1
- package/uploads.d.ts +1 -0
- package/uploads.d.ts.map +1 -1
- package/uploads.mjs +1 -0
- package/uploads.mjs.map +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,195 @@
|
|
|
1
|
+
import { APIResource } from "../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../core/api-promise.mjs";
|
|
3
|
+
import { RequestOptions } from "../internal/request-options.mjs";
|
|
4
|
+
export declare class WebScannerRules extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* List suppression rules for a single web scanner. Requires the `scannerId` query
|
|
7
|
+
* parameter — rules are always scoped to a parent scanner. Not paginated; the
|
|
8
|
+
* per-scanner rule count is bounded. Requires scope: webScanner:find
|
|
9
|
+
*/
|
|
10
|
+
list(query: WebScannerRuleListParams, options?: RequestOptions): APIPromise<WebScannerRuleListResponse>;
|
|
11
|
+
/**
|
|
12
|
+
* Create a suppression rule on a web scanner. Auth is enforced against the parent
|
|
13
|
+
* scanner via `webScanner:update`. At least one of `cookiePatterns`,
|
|
14
|
+
* `domainPatterns`, or `scriptPatterns` should be set for the rule to match
|
|
15
|
+
* anything; omitted pattern arrays default to `[]`. Requires scope:
|
|
16
|
+
* webScanner:update
|
|
17
|
+
*/
|
|
18
|
+
create(body: WebScannerRuleCreateParams, options?: RequestOptions): APIPromise<WebScannerRuleCreateResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Find a single web scanner rule by ID. Requires scope: webScanner:find
|
|
21
|
+
*/
|
|
22
|
+
retrieve(id: string, options?: RequestOptions): APIPromise<WebScannerRuleRetrieveResponse>;
|
|
23
|
+
/**
|
|
24
|
+
* Partially update a suppression rule. Only the fields you send are changed.
|
|
25
|
+
* List-valued fields (`cookiePatterns`, `domainPatterns`, `scriptPatterns`) are
|
|
26
|
+
* replaced wholesale when sent. Requires scope: webScanner:update
|
|
27
|
+
*/
|
|
28
|
+
update(id: string, body: WebScannerRuleUpdateParams, options?: RequestOptions): APIPromise<WebScannerRuleUpdateResponse>;
|
|
29
|
+
/**
|
|
30
|
+
* Delete a web scanner rule. Requires scope: webScanner:update
|
|
31
|
+
*/
|
|
32
|
+
delete(id: string, options?: RequestOptions): APIPromise<WebScannerRuleDeleteResponse>;
|
|
33
|
+
}
|
|
34
|
+
export interface WebScannerRuleListResponse {
|
|
35
|
+
entities: Array<WebScannerRuleListResponse.Entity>;
|
|
36
|
+
}
|
|
37
|
+
export declare namespace WebScannerRuleListResponse {
|
|
38
|
+
interface Entity {
|
|
39
|
+
id: string;
|
|
40
|
+
accountId: string;
|
|
41
|
+
cookiePatterns: Array<string>;
|
|
42
|
+
createdAt: string;
|
|
43
|
+
domainPatterns: Array<string>;
|
|
44
|
+
name: string;
|
|
45
|
+
priority: number;
|
|
46
|
+
scannerId: string;
|
|
47
|
+
scriptPatterns: Array<string>;
|
|
48
|
+
createdByUserId?: string | null;
|
|
49
|
+
notes?: string | null;
|
|
50
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
51
|
+
updatedAt?: string | null;
|
|
52
|
+
updatedByUserId?: string | null;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
export interface WebScannerRuleCreateResponse {
|
|
56
|
+
id: string;
|
|
57
|
+
accountId: string;
|
|
58
|
+
cookiePatterns: Array<string>;
|
|
59
|
+
createdAt: string;
|
|
60
|
+
domainPatterns: Array<string>;
|
|
61
|
+
name: string;
|
|
62
|
+
priority: number;
|
|
63
|
+
scannerId: string;
|
|
64
|
+
scriptPatterns: Array<string>;
|
|
65
|
+
createdByUserId?: string | null;
|
|
66
|
+
notes?: string | null;
|
|
67
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
68
|
+
updatedAt?: string | null;
|
|
69
|
+
updatedByUserId?: string | null;
|
|
70
|
+
}
|
|
71
|
+
export interface WebScannerRuleRetrieveResponse {
|
|
72
|
+
id: string;
|
|
73
|
+
accountId: string;
|
|
74
|
+
cookiePatterns: Array<string>;
|
|
75
|
+
createdAt: string;
|
|
76
|
+
domainPatterns: Array<string>;
|
|
77
|
+
name: string;
|
|
78
|
+
priority: number;
|
|
79
|
+
scannerId: string;
|
|
80
|
+
scriptPatterns: Array<string>;
|
|
81
|
+
createdByUserId?: string | null;
|
|
82
|
+
notes?: string | null;
|
|
83
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
84
|
+
updatedAt?: string | null;
|
|
85
|
+
updatedByUserId?: string | null;
|
|
86
|
+
}
|
|
87
|
+
export interface WebScannerRuleUpdateResponse {
|
|
88
|
+
id: string;
|
|
89
|
+
accountId: string;
|
|
90
|
+
cookiePatterns: Array<string>;
|
|
91
|
+
createdAt: string;
|
|
92
|
+
domainPatterns: Array<string>;
|
|
93
|
+
name: string;
|
|
94
|
+
priority: number;
|
|
95
|
+
scannerId: string;
|
|
96
|
+
scriptPatterns: Array<string>;
|
|
97
|
+
createdByUserId?: string | null;
|
|
98
|
+
notes?: string | null;
|
|
99
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
100
|
+
updatedAt?: string | null;
|
|
101
|
+
updatedByUserId?: string | null;
|
|
102
|
+
}
|
|
103
|
+
export interface WebScannerRuleDeleteResponse {
|
|
104
|
+
/**
|
|
105
|
+
* The id of the suppression rule that was deleted.
|
|
106
|
+
*/
|
|
107
|
+
id: string;
|
|
108
|
+
/**
|
|
109
|
+
* True when the underlying mutation succeeded.
|
|
110
|
+
*/
|
|
111
|
+
deleted: boolean;
|
|
112
|
+
}
|
|
113
|
+
export interface WebScannerRuleListParams {
|
|
114
|
+
/**
|
|
115
|
+
* The web scanner whose suppression rules should be returned.
|
|
116
|
+
*/
|
|
117
|
+
scannerId: string;
|
|
118
|
+
}
|
|
119
|
+
export interface WebScannerRuleCreateParams {
|
|
120
|
+
/**
|
|
121
|
+
* User-friendly name for the suppression rule.
|
|
122
|
+
*/
|
|
123
|
+
name: string;
|
|
124
|
+
/**
|
|
125
|
+
* Rule priority (1–10,000). Lower numbers are evaluated first when multiple rules
|
|
126
|
+
* match.
|
|
127
|
+
*/
|
|
128
|
+
priority: number;
|
|
129
|
+
/**
|
|
130
|
+
* The web scanner this rule belongs to.
|
|
131
|
+
*/
|
|
132
|
+
scannerId: string;
|
|
133
|
+
/**
|
|
134
|
+
* Glob patterns matched against cookie names (e.g. `_ga*`). Max 100 entries. When
|
|
135
|
+
* sent on PATCH, replaces the existing list wholesale.
|
|
136
|
+
*/
|
|
137
|
+
cookiePatterns?: Array<string>;
|
|
138
|
+
/**
|
|
139
|
+
* Glob patterns matched against cookie domain / script hostname (e.g.
|
|
140
|
+
* `*.google-analytics.com`). Max 100 entries. When sent on PATCH, replaces the
|
|
141
|
+
* existing list wholesale.
|
|
142
|
+
*/
|
|
143
|
+
domainPatterns?: Array<string>;
|
|
144
|
+
/**
|
|
145
|
+
* Free-form notes about why this rule exists or what it covers. Trimmed
|
|
146
|
+
* server-side; empty strings become `null`.
|
|
147
|
+
*/
|
|
148
|
+
notes?: string | null;
|
|
149
|
+
/**
|
|
150
|
+
* Why this rule was added. Surfaced in audit views. Send `null` to clear an
|
|
151
|
+
* existing reason on patch.
|
|
152
|
+
*/
|
|
153
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
154
|
+
/**
|
|
155
|
+
* Glob patterns matched against full script URLs (e.g.
|
|
156
|
+
* `https://www.googletagmanager.com/gtm.js?id=*`). Max 100 entries. When sent on
|
|
157
|
+
* PATCH, replaces the existing list wholesale.
|
|
158
|
+
*/
|
|
159
|
+
scriptPatterns?: Array<string>;
|
|
160
|
+
}
|
|
161
|
+
export interface WebScannerRuleUpdateParams {
|
|
162
|
+
/**
|
|
163
|
+
* Glob patterns matched against cookie names (e.g. `_ga*`). Max 100 entries. When
|
|
164
|
+
* sent on PATCH, replaces the existing list wholesale.
|
|
165
|
+
*/
|
|
166
|
+
cookiePatterns?: Array<string>;
|
|
167
|
+
/**
|
|
168
|
+
* Glob patterns matched against cookie domain / script hostname (e.g.
|
|
169
|
+
* `*.google-analytics.com`). Max 100 entries. When sent on PATCH, replaces the
|
|
170
|
+
* existing list wholesale.
|
|
171
|
+
*/
|
|
172
|
+
domainPatterns?: Array<string>;
|
|
173
|
+
name?: string;
|
|
174
|
+
/**
|
|
175
|
+
* Free-form notes about why this rule exists or what it covers. Trimmed
|
|
176
|
+
* server-side; empty strings become `null`.
|
|
177
|
+
*/
|
|
178
|
+
notes?: string | null;
|
|
179
|
+
priority?: number;
|
|
180
|
+
/**
|
|
181
|
+
* Why this rule was added. Surfaced in audit views. Send `null` to clear an
|
|
182
|
+
* existing reason on patch.
|
|
183
|
+
*/
|
|
184
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
185
|
+
/**
|
|
186
|
+
* Glob patterns matched against full script URLs (e.g.
|
|
187
|
+
* `https://www.googletagmanager.com/gtm.js?id=*`). Max 100 entries. When sent on
|
|
188
|
+
* PATCH, replaces the existing list wholesale.
|
|
189
|
+
*/
|
|
190
|
+
scriptPatterns?: Array<string>;
|
|
191
|
+
}
|
|
192
|
+
export declare namespace WebScannerRules {
|
|
193
|
+
export { type WebScannerRuleListResponse as WebScannerRuleListResponse, type WebScannerRuleCreateResponse as WebScannerRuleCreateResponse, type WebScannerRuleRetrieveResponse as WebScannerRuleRetrieveResponse, type WebScannerRuleUpdateResponse as WebScannerRuleUpdateResponse, type WebScannerRuleDeleteResponse as WebScannerRuleDeleteResponse, type WebScannerRuleListParams as WebScannerRuleListParams, type WebScannerRuleCreateParams as WebScannerRuleCreateParams, type WebScannerRuleUpdateParams as WebScannerRuleUpdateParams, };
|
|
194
|
+
}
|
|
195
|
+
//# sourceMappingURL=web-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IAElG;;;;OAIG;IACH,cAAc,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,WAAW,eAAe,CAAC;IACvC,OAAO,EACL,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,0BAA0B,IAAI,0BAA0B,GAC9D,CAAC;CACH"}
|
|
@@ -0,0 +1,195 @@
|
|
|
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 WebScannerRules extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* List suppression rules for a single web scanner. Requires the `scannerId` query
|
|
7
|
+
* parameter — rules are always scoped to a parent scanner. Not paginated; the
|
|
8
|
+
* per-scanner rule count is bounded. Requires scope: webScanner:find
|
|
9
|
+
*/
|
|
10
|
+
list(query: WebScannerRuleListParams, options?: RequestOptions): APIPromise<WebScannerRuleListResponse>;
|
|
11
|
+
/**
|
|
12
|
+
* Create a suppression rule on a web scanner. Auth is enforced against the parent
|
|
13
|
+
* scanner via `webScanner:update`. At least one of `cookiePatterns`,
|
|
14
|
+
* `domainPatterns`, or `scriptPatterns` should be set for the rule to match
|
|
15
|
+
* anything; omitted pattern arrays default to `[]`. Requires scope:
|
|
16
|
+
* webScanner:update
|
|
17
|
+
*/
|
|
18
|
+
create(body: WebScannerRuleCreateParams, options?: RequestOptions): APIPromise<WebScannerRuleCreateResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Find a single web scanner rule by ID. Requires scope: webScanner:find
|
|
21
|
+
*/
|
|
22
|
+
retrieve(id: string, options?: RequestOptions): APIPromise<WebScannerRuleRetrieveResponse>;
|
|
23
|
+
/**
|
|
24
|
+
* Partially update a suppression rule. Only the fields you send are changed.
|
|
25
|
+
* List-valued fields (`cookiePatterns`, `domainPatterns`, `scriptPatterns`) are
|
|
26
|
+
* replaced wholesale when sent. Requires scope: webScanner:update
|
|
27
|
+
*/
|
|
28
|
+
update(id: string, body: WebScannerRuleUpdateParams, options?: RequestOptions): APIPromise<WebScannerRuleUpdateResponse>;
|
|
29
|
+
/**
|
|
30
|
+
* Delete a web scanner rule. Requires scope: webScanner:update
|
|
31
|
+
*/
|
|
32
|
+
delete(id: string, options?: RequestOptions): APIPromise<WebScannerRuleDeleteResponse>;
|
|
33
|
+
}
|
|
34
|
+
export interface WebScannerRuleListResponse {
|
|
35
|
+
entities: Array<WebScannerRuleListResponse.Entity>;
|
|
36
|
+
}
|
|
37
|
+
export declare namespace WebScannerRuleListResponse {
|
|
38
|
+
interface Entity {
|
|
39
|
+
id: string;
|
|
40
|
+
accountId: string;
|
|
41
|
+
cookiePatterns: Array<string>;
|
|
42
|
+
createdAt: string;
|
|
43
|
+
domainPatterns: Array<string>;
|
|
44
|
+
name: string;
|
|
45
|
+
priority: number;
|
|
46
|
+
scannerId: string;
|
|
47
|
+
scriptPatterns: Array<string>;
|
|
48
|
+
createdByUserId?: string | null;
|
|
49
|
+
notes?: string | null;
|
|
50
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
51
|
+
updatedAt?: string | null;
|
|
52
|
+
updatedByUserId?: string | null;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
export interface WebScannerRuleCreateResponse {
|
|
56
|
+
id: string;
|
|
57
|
+
accountId: string;
|
|
58
|
+
cookiePatterns: Array<string>;
|
|
59
|
+
createdAt: string;
|
|
60
|
+
domainPatterns: Array<string>;
|
|
61
|
+
name: string;
|
|
62
|
+
priority: number;
|
|
63
|
+
scannerId: string;
|
|
64
|
+
scriptPatterns: Array<string>;
|
|
65
|
+
createdByUserId?: string | null;
|
|
66
|
+
notes?: string | null;
|
|
67
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
68
|
+
updatedAt?: string | null;
|
|
69
|
+
updatedByUserId?: string | null;
|
|
70
|
+
}
|
|
71
|
+
export interface WebScannerRuleRetrieveResponse {
|
|
72
|
+
id: string;
|
|
73
|
+
accountId: string;
|
|
74
|
+
cookiePatterns: Array<string>;
|
|
75
|
+
createdAt: string;
|
|
76
|
+
domainPatterns: Array<string>;
|
|
77
|
+
name: string;
|
|
78
|
+
priority: number;
|
|
79
|
+
scannerId: string;
|
|
80
|
+
scriptPatterns: Array<string>;
|
|
81
|
+
createdByUserId?: string | null;
|
|
82
|
+
notes?: string | null;
|
|
83
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
84
|
+
updatedAt?: string | null;
|
|
85
|
+
updatedByUserId?: string | null;
|
|
86
|
+
}
|
|
87
|
+
export interface WebScannerRuleUpdateResponse {
|
|
88
|
+
id: string;
|
|
89
|
+
accountId: string;
|
|
90
|
+
cookiePatterns: Array<string>;
|
|
91
|
+
createdAt: string;
|
|
92
|
+
domainPatterns: Array<string>;
|
|
93
|
+
name: string;
|
|
94
|
+
priority: number;
|
|
95
|
+
scannerId: string;
|
|
96
|
+
scriptPatterns: Array<string>;
|
|
97
|
+
createdByUserId?: string | null;
|
|
98
|
+
notes?: string | null;
|
|
99
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
100
|
+
updatedAt?: string | null;
|
|
101
|
+
updatedByUserId?: string | null;
|
|
102
|
+
}
|
|
103
|
+
export interface WebScannerRuleDeleteResponse {
|
|
104
|
+
/**
|
|
105
|
+
* The id of the suppression rule that was deleted.
|
|
106
|
+
*/
|
|
107
|
+
id: string;
|
|
108
|
+
/**
|
|
109
|
+
* True when the underlying mutation succeeded.
|
|
110
|
+
*/
|
|
111
|
+
deleted: boolean;
|
|
112
|
+
}
|
|
113
|
+
export interface WebScannerRuleListParams {
|
|
114
|
+
/**
|
|
115
|
+
* The web scanner whose suppression rules should be returned.
|
|
116
|
+
*/
|
|
117
|
+
scannerId: string;
|
|
118
|
+
}
|
|
119
|
+
export interface WebScannerRuleCreateParams {
|
|
120
|
+
/**
|
|
121
|
+
* User-friendly name for the suppression rule.
|
|
122
|
+
*/
|
|
123
|
+
name: string;
|
|
124
|
+
/**
|
|
125
|
+
* Rule priority (1–10,000). Lower numbers are evaluated first when multiple rules
|
|
126
|
+
* match.
|
|
127
|
+
*/
|
|
128
|
+
priority: number;
|
|
129
|
+
/**
|
|
130
|
+
* The web scanner this rule belongs to.
|
|
131
|
+
*/
|
|
132
|
+
scannerId: string;
|
|
133
|
+
/**
|
|
134
|
+
* Glob patterns matched against cookie names (e.g. `_ga*`). Max 100 entries. When
|
|
135
|
+
* sent on PATCH, replaces the existing list wholesale.
|
|
136
|
+
*/
|
|
137
|
+
cookiePatterns?: Array<string>;
|
|
138
|
+
/**
|
|
139
|
+
* Glob patterns matched against cookie domain / script hostname (e.g.
|
|
140
|
+
* `*.google-analytics.com`). Max 100 entries. When sent on PATCH, replaces the
|
|
141
|
+
* existing list wholesale.
|
|
142
|
+
*/
|
|
143
|
+
domainPatterns?: Array<string>;
|
|
144
|
+
/**
|
|
145
|
+
* Free-form notes about why this rule exists or what it covers. Trimmed
|
|
146
|
+
* server-side; empty strings become `null`.
|
|
147
|
+
*/
|
|
148
|
+
notes?: string | null;
|
|
149
|
+
/**
|
|
150
|
+
* Why this rule was added. Surfaced in audit views. Send `null` to clear an
|
|
151
|
+
* existing reason on patch.
|
|
152
|
+
*/
|
|
153
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
154
|
+
/**
|
|
155
|
+
* Glob patterns matched against full script URLs (e.g.
|
|
156
|
+
* `https://www.googletagmanager.com/gtm.js?id=*`). Max 100 entries. When sent on
|
|
157
|
+
* PATCH, replaces the existing list wholesale.
|
|
158
|
+
*/
|
|
159
|
+
scriptPatterns?: Array<string>;
|
|
160
|
+
}
|
|
161
|
+
export interface WebScannerRuleUpdateParams {
|
|
162
|
+
/**
|
|
163
|
+
* Glob patterns matched against cookie names (e.g. `_ga*`). Max 100 entries. When
|
|
164
|
+
* sent on PATCH, replaces the existing list wholesale.
|
|
165
|
+
*/
|
|
166
|
+
cookiePatterns?: Array<string>;
|
|
167
|
+
/**
|
|
168
|
+
* Glob patterns matched against cookie domain / script hostname (e.g.
|
|
169
|
+
* `*.google-analytics.com`). Max 100 entries. When sent on PATCH, replaces the
|
|
170
|
+
* existing list wholesale.
|
|
171
|
+
*/
|
|
172
|
+
domainPatterns?: Array<string>;
|
|
173
|
+
name?: string;
|
|
174
|
+
/**
|
|
175
|
+
* Free-form notes about why this rule exists or what it covers. Trimmed
|
|
176
|
+
* server-side; empty strings become `null`.
|
|
177
|
+
*/
|
|
178
|
+
notes?: string | null;
|
|
179
|
+
priority?: number;
|
|
180
|
+
/**
|
|
181
|
+
* Why this rule was added. Surfaced in audit views. Send `null` to clear an
|
|
182
|
+
* existing reason on patch.
|
|
183
|
+
*/
|
|
184
|
+
reason?: 'approved' | 'baa' | 'compliant' | 'firstParty' | 'ignore' | 'internal' | 'other' | null;
|
|
185
|
+
/**
|
|
186
|
+
* Glob patterns matched against full script URLs (e.g.
|
|
187
|
+
* `https://www.googletagmanager.com/gtm.js?id=*`). Max 100 entries. When sent on
|
|
188
|
+
* PATCH, replaces the existing list wholesale.
|
|
189
|
+
*/
|
|
190
|
+
scriptPatterns?: Array<string>;
|
|
191
|
+
}
|
|
192
|
+
export declare namespace WebScannerRules {
|
|
193
|
+
export { type WebScannerRuleListResponse as WebScannerRuleListResponse, type WebScannerRuleCreateResponse as WebScannerRuleCreateResponse, type WebScannerRuleRetrieveResponse as WebScannerRuleRetrieveResponse, type WebScannerRuleUpdateResponse as WebScannerRuleUpdateResponse, type WebScannerRuleDeleteResponse as WebScannerRuleDeleteResponse, type WebScannerRuleListParams as WebScannerRuleListParams, type WebScannerRuleCreateParams as WebScannerRuleCreateParams, type WebScannerRuleUpdateParams as WebScannerRuleUpdateParams, };
|
|
194
|
+
}
|
|
195
|
+
//# sourceMappingURL=web-scanner-rules.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-scanner-rules.d.ts","sourceRoot":"","sources":["../src/resources/web-scanner-rules.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAG7D,qBAAa,eAAgB,SAAQ,WAAW;IAC9C;;;;OAIG;IACH,IAAI,CAAC,KAAK,EAAE,wBAAwB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,0BAA0B,CAAC;IAIvG;;;;;;OAMG;IACH,MAAM,CACJ,IAAI,EAAE,0BAA0B,EAChC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,4BAA4B,CAAC;IAI3C;;OAEG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,8BAA8B,CAAC;IAI1F;;;;OAIG;IACH,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,0BAA0B,EAChC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,4BAA4B,CAAC;IAI3C;;OAEG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,4BAA4B,CAAC;CAGvF;AAED,MAAM,WAAW,0BAA0B;IACzC,QAAQ,EAAE,KAAK,CAAC,0BAA0B,CAAC,MAAM,CAAC,CAAC;CACpD;AAED,y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AC;IAEd;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;;OAGG;IACH,MAAM,CAAC,EAAE,UAAU,GAAG,KAAK,GAAG,WAAW,GAAG,YAAY,GAAG,QAAQ,GAAG,UAAU,GAAG,OAAO,GAAG,IAAI,CAAC;IAElG;;;;OAIG;IACH,cAAc,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;CAChC;AAED,MAAM,CAAC,OAAO,WAAW,eAAe,CAAC;IACvC,OAAO,EACL,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,0BAA0B,IAAI,0BAA0B,GAC9D,CAAC;CACH"}
|
|
@@ -0,0 +1,48 @@
|
|
|
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.WebScannerRules = void 0;
|
|
5
|
+
const resource_1 = require("../core/resource.js");
|
|
6
|
+
const path_1 = require("../internal/utils/path.js");
|
|
7
|
+
class WebScannerRules extends resource_1.APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* List suppression rules for a single web scanner. Requires the `scannerId` query
|
|
10
|
+
* parameter — rules are always scoped to a parent scanner. Not paginated; the
|
|
11
|
+
* per-scanner rule count is bounded. Requires scope: webScanner:find
|
|
12
|
+
*/
|
|
13
|
+
list(query, options) {
|
|
14
|
+
return this._client.get('/rest/v1/web-scanner-rules', { query, ...options });
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Create a suppression rule on a web scanner. Auth is enforced against the parent
|
|
18
|
+
* scanner via `webScanner:update`. At least one of `cookiePatterns`,
|
|
19
|
+
* `domainPatterns`, or `scriptPatterns` should be set for the rule to match
|
|
20
|
+
* anything; omitted pattern arrays default to `[]`. Requires scope:
|
|
21
|
+
* webScanner:update
|
|
22
|
+
*/
|
|
23
|
+
create(body, options) {
|
|
24
|
+
return this._client.post('/rest/v1/web-scanner-rules', { body, ...options });
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Find a single web scanner rule by ID. Requires scope: webScanner:find
|
|
28
|
+
*/
|
|
29
|
+
retrieve(id, options) {
|
|
30
|
+
return this._client.get((0, path_1.path) `/rest/v1/web-scanner-rules/${id}`, options);
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Partially update a suppression rule. Only the fields you send are changed.
|
|
34
|
+
* List-valued fields (`cookiePatterns`, `domainPatterns`, `scriptPatterns`) are
|
|
35
|
+
* replaced wholesale when sent. Requires scope: webScanner:update
|
|
36
|
+
*/
|
|
37
|
+
update(id, body, options) {
|
|
38
|
+
return this._client.patch((0, path_1.path) `/rest/v1/web-scanner-rules/${id}`, { body, ...options });
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Delete a web scanner rule. Requires scope: webScanner:update
|
|
42
|
+
*/
|
|
43
|
+
delete(id, options) {
|
|
44
|
+
return this._client.delete((0, path_1.path) `/rest/v1/web-scanner-rules/${id}`, options);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
exports.WebScannerRules = WebScannerRules;
|
|
48
|
+
//# sourceMappingURL=web-scanner-rules.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-scanner-rules.js","sourceRoot":"","sources":["../src/resources/web-scanner-rules.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAG/C,oDAA8C;AAE9C,MAAa,eAAgB,SAAQ,sBAAW;IAC9C;;;;OAIG;IACH,IAAI,CAAC,KAA+B,EAAE,OAAwB;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,4BAA4B,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/E,CAAC;IAED;;;;;;OAMG;IACH,MAAM,CACJ,IAAgC,EAChC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,4BAA4B,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/E,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,EAAU,EAAE,OAAwB;QAC3C,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,8BAA8B,EAAE,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3E,CAAC;IAED;;;;OAIG;IACH,MAAM,CACJ,EAAU,EACV,IAAgC,EAChC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAA,WAAI,EAAA,8BAA8B,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC1F,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,EAAU,EAAE,OAAwB;QACzC,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,8BAA8B,EAAE,EAAE,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC;CACF;AAlDD,0CAkDC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../core/resource.mjs";
|
|
3
|
+
import { path } from "../internal/utils/path.mjs";
|
|
4
|
+
export class WebScannerRules extends APIResource {
|
|
5
|
+
/**
|
|
6
|
+
* List suppression rules for a single web scanner. Requires the `scannerId` query
|
|
7
|
+
* parameter — rules are always scoped to a parent scanner. Not paginated; the
|
|
8
|
+
* per-scanner rule count is bounded. Requires scope: webScanner:find
|
|
9
|
+
*/
|
|
10
|
+
list(query, options) {
|
|
11
|
+
return this._client.get('/rest/v1/web-scanner-rules', { query, ...options });
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Create a suppression rule on a web scanner. Auth is enforced against the parent
|
|
15
|
+
* scanner via `webScanner:update`. At least one of `cookiePatterns`,
|
|
16
|
+
* `domainPatterns`, or `scriptPatterns` should be set for the rule to match
|
|
17
|
+
* anything; omitted pattern arrays default to `[]`. Requires scope:
|
|
18
|
+
* webScanner:update
|
|
19
|
+
*/
|
|
20
|
+
create(body, options) {
|
|
21
|
+
return this._client.post('/rest/v1/web-scanner-rules', { body, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Find a single web scanner rule by ID. Requires scope: webScanner:find
|
|
25
|
+
*/
|
|
26
|
+
retrieve(id, options) {
|
|
27
|
+
return this._client.get(path `/rest/v1/web-scanner-rules/${id}`, options);
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Partially update a suppression rule. Only the fields you send are changed.
|
|
31
|
+
* List-valued fields (`cookiePatterns`, `domainPatterns`, `scriptPatterns`) are
|
|
32
|
+
* replaced wholesale when sent. Requires scope: webScanner:update
|
|
33
|
+
*/
|
|
34
|
+
update(id, body, options) {
|
|
35
|
+
return this._client.patch(path `/rest/v1/web-scanner-rules/${id}`, { body, ...options });
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Delete a web scanner rule. Requires scope: webScanner:update
|
|
39
|
+
*/
|
|
40
|
+
delete(id, options) {
|
|
41
|
+
return this._client.delete(path `/rest/v1/web-scanner-rules/${id}`, options);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
//# sourceMappingURL=web-scanner-rules.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-scanner-rules.mjs","sourceRoot":"","sources":["../src/resources/web-scanner-rules.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAG/C,OAAO,EAAE,IAAI,EAAE,mCAA+B;AAE9C,MAAM,OAAO,eAAgB,SAAQ,WAAW;IAC9C;;;;OAIG;IACH,IAAI,CAAC,KAA+B,EAAE,OAAwB;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,4BAA4B,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/E,CAAC;IAED;;;;;;OAMG;IACH,MAAM,CACJ,IAAgC,EAChC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,4BAA4B,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/E,CAAC;IAED;;OAEG;IACH,QAAQ,CAAC,EAAU,EAAE,OAAwB;QAC3C,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,8BAA8B,EAAE,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3E,CAAC;IAED;;;;OAIG;IACH,MAAM,CACJ,EAAU,EACV,IAAgC,EAChC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAA,8BAA8B,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC1F,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,EAAU,EAAE,OAAwB;QACzC,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAA,8BAA8B,EAAE,EAAE,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC;CACF"}
|