@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
package/resources/mappings.d.mts
CHANGED
|
@@ -11,7 +11,19 @@ export declare class Mappings extends APIResource {
|
|
|
11
11
|
*/
|
|
12
12
|
list(query: MappingListParams, options?: RequestOptions): PagePromise<MappingListResponsesCursor, MappingListResponse>;
|
|
13
13
|
/**
|
|
14
|
-
* Create a
|
|
14
|
+
* Create a mapping. Two body shapes are accepted:
|
|
15
|
+
*
|
|
16
|
+
* 1. Quick-create — `{ allowedEventId, destinationId }`. Binds an allowed event to
|
|
17
|
+
* a destination. Returns a slim entity with empty `mappings[]`; follow up with
|
|
18
|
+
* PATCH to populate fields.
|
|
19
|
+
* 2. Template fat-create —
|
|
20
|
+
* `{ entityId, templateId, mappings?, logic?, isEnabled?, name?, insertAfterIdx? }`.
|
|
21
|
+
* Lands a fully-shaped mapping in one round-trip. Use
|
|
22
|
+
* `GET /rest/v1/mapping-templates?entityId=...` to discover the valid
|
|
23
|
+
* `templateId` and `mappings[].property` values.
|
|
24
|
+
*
|
|
25
|
+
* Sending both `allowedEventId` and `templateId` returns 400. Requires scope:
|
|
26
|
+
* mapping:create
|
|
15
27
|
*/
|
|
16
28
|
create(body: MappingCreateParams, options?: RequestOptions): APIPromise<MappingCreateResponse>;
|
|
17
29
|
/**
|
|
@@ -19,14 +31,23 @@ export declare class Mappings extends APIResource {
|
|
|
19
31
|
*/
|
|
20
32
|
retrieve(id: string, options?: RequestOptions): APIPromise<MappingRetrieveResponse>;
|
|
21
33
|
/**
|
|
22
|
-
* Partially update a mapping. Only the fields you send are changed.
|
|
23
|
-
*
|
|
34
|
+
* Partially update a mapping. Only the fields you send are changed. Send
|
|
35
|
+
* `isEnabled: false` to pause the mapping without changing other fields (mirrors
|
|
36
|
+
* `status` on destinations). `mappings[]` is replaced wholesale when sent.
|
|
37
|
+
* Requires scope: mapping:update
|
|
24
38
|
*/
|
|
25
39
|
update(id: string, body: MappingUpdateParams, options?: RequestOptions): APIPromise<MappingUpdateResponse>;
|
|
26
40
|
/**
|
|
27
41
|
* Delete a mapping. Requires scope: mapping:delete
|
|
28
42
|
*/
|
|
29
43
|
delete(id: string, options?: RequestOptions): APIPromise<MappingDeleteResponse>;
|
|
44
|
+
/**
|
|
45
|
+
* Reassign `priority` for a set of mappings. Pass `{ uuids: [...] }` with the
|
|
46
|
+
* mapping ids in their new order — index 0 becomes the highest-priority mapping.
|
|
47
|
+
* All ids must belong to the same parent entity (source or destination); mixing
|
|
48
|
+
* entities returns 400. Requires scope: mapping:update
|
|
49
|
+
*/
|
|
50
|
+
reorder(body: MappingReorderParams, options?: RequestOptions): APIPromise<MappingReorderResponse>;
|
|
30
51
|
}
|
|
31
52
|
export type MappingListResponsesCursor = Cursor<MappingListResponse>;
|
|
32
53
|
export interface MappingListResponse {
|
|
@@ -35,6 +56,14 @@ export interface MappingListResponse {
|
|
|
35
56
|
mappings: Array<MappingListResponse.Mapping>;
|
|
36
57
|
destinationId?: string | null;
|
|
37
58
|
isDefaultMapping?: boolean | null;
|
|
59
|
+
/**
|
|
60
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
61
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
62
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
63
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
64
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
65
|
+
*/
|
|
66
|
+
logic?: unknown;
|
|
38
67
|
name?: string | null;
|
|
39
68
|
priority?: number | null;
|
|
40
69
|
sourceId?: string | null;
|
|
@@ -55,6 +84,14 @@ export interface MappingCreateResponse {
|
|
|
55
84
|
mappings: Array<MappingCreateResponse.Mapping>;
|
|
56
85
|
destinationId?: string | null;
|
|
57
86
|
isDefaultMapping?: boolean | null;
|
|
87
|
+
/**
|
|
88
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
89
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
90
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
91
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
92
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
93
|
+
*/
|
|
94
|
+
logic?: unknown;
|
|
58
95
|
name?: string | null;
|
|
59
96
|
priority?: number | null;
|
|
60
97
|
sourceId?: string | null;
|
|
@@ -75,6 +112,14 @@ export interface MappingRetrieveResponse {
|
|
|
75
112
|
mappings: Array<MappingRetrieveResponse.Mapping>;
|
|
76
113
|
destinationId?: string | null;
|
|
77
114
|
isDefaultMapping?: boolean | null;
|
|
115
|
+
/**
|
|
116
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
117
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
118
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
119
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
120
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
121
|
+
*/
|
|
122
|
+
logic?: unknown;
|
|
78
123
|
name?: string | null;
|
|
79
124
|
priority?: number | null;
|
|
80
125
|
sourceId?: string | null;
|
|
@@ -95,6 +140,14 @@ export interface MappingUpdateResponse {
|
|
|
95
140
|
mappings: Array<MappingUpdateResponse.Mapping>;
|
|
96
141
|
destinationId?: string | null;
|
|
97
142
|
isDefaultMapping?: boolean | null;
|
|
143
|
+
/**
|
|
144
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
145
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
146
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
147
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
148
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
149
|
+
*/
|
|
150
|
+
logic?: unknown;
|
|
98
151
|
name?: string | null;
|
|
99
152
|
priority?: number | null;
|
|
100
153
|
sourceId?: string | null;
|
|
@@ -110,6 +163,39 @@ export declare namespace MappingUpdateResponse {
|
|
|
110
163
|
}
|
|
111
164
|
}
|
|
112
165
|
export type MappingDeleteResponse = boolean;
|
|
166
|
+
export interface MappingReorderResponse {
|
|
167
|
+
entities: Array<MappingReorderResponse.Entity>;
|
|
168
|
+
}
|
|
169
|
+
export declare namespace MappingReorderResponse {
|
|
170
|
+
interface Entity {
|
|
171
|
+
id: string;
|
|
172
|
+
isEnabled: boolean;
|
|
173
|
+
mappings: Array<Entity.Mapping>;
|
|
174
|
+
destinationId?: string | null;
|
|
175
|
+
isDefaultMapping?: boolean | null;
|
|
176
|
+
/**
|
|
177
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
178
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
179
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
180
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
181
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
182
|
+
*/
|
|
183
|
+
logic?: unknown;
|
|
184
|
+
name?: string | null;
|
|
185
|
+
priority?: number | null;
|
|
186
|
+
sourceId?: string | null;
|
|
187
|
+
templateId?: string | null;
|
|
188
|
+
templateName?: string | null;
|
|
189
|
+
updatedAt?: string | null;
|
|
190
|
+
}
|
|
191
|
+
namespace Entity {
|
|
192
|
+
interface Mapping {
|
|
193
|
+
map: string;
|
|
194
|
+
property: string;
|
|
195
|
+
modification?: 'CamelCase' | 'DmaIP' | 'DomainOnly' | 'DomainPathOnly' | 'DomainPathUTMs' | 'DomainUTMs' | 'FakeDomain' | 'FakeDomainRealPath' | 'FakeIP' | 'FullUrl' | 'Hash' | 'HashMD5' | 'HashedCountry' | 'HashedDateOfBirth' | 'HashedGender' | 'HashedNormalized' | 'HashedNormalizedNoSpecialChars' | 'HashedPhone' | 'HashedState' | 'HashedZip' | 'KebabCase' | 'LowerCase' | 'None' | 'Null' | 'Redacted' | 'RegionalIP' | 'SnakeCase' | 'StartCase' | 'UpperCase' | null;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}
|
|
113
199
|
export interface MappingListParams extends CursorParams {
|
|
114
200
|
/**
|
|
115
201
|
* Filter mappings by their parent entity id. Must be a destination id or source
|
|
@@ -118,10 +204,97 @@ export interface MappingListParams extends CursorParams {
|
|
|
118
204
|
entityId: string;
|
|
119
205
|
}
|
|
120
206
|
export interface MappingCreateParams {
|
|
121
|
-
|
|
122
|
-
|
|
207
|
+
/**
|
|
208
|
+
* Quick-create variant: allowed event to bind the new mapping to. Required
|
|
209
|
+
* together with `destinationId`. Mutually exclusive with `templateId`/`entityId`.
|
|
210
|
+
*/
|
|
211
|
+
allowedEventId?: string;
|
|
212
|
+
/**
|
|
213
|
+
* Quick-create variant: destination that should receive events matched by this
|
|
214
|
+
* mapping. Required together with `allowedEventId`.
|
|
215
|
+
*/
|
|
216
|
+
destinationId?: string;
|
|
217
|
+
/**
|
|
218
|
+
* Template fat-create variant: destination or source id this mapping belongs to.
|
|
219
|
+
* Required together with `templateId`.
|
|
220
|
+
*/
|
|
221
|
+
entityId?: string;
|
|
222
|
+
/**
|
|
223
|
+
* Template fat-create only. Zero-based position in the destination/source priority
|
|
224
|
+
* order to insert this mapping after. Omit to append at the end.
|
|
225
|
+
*/
|
|
226
|
+
insertAfterIdx?: number;
|
|
227
|
+
/**
|
|
228
|
+
* Template fat-create only. Initial enabled state. Defaults to `true`.
|
|
229
|
+
*/
|
|
230
|
+
isEnabled?: boolean;
|
|
231
|
+
/**
|
|
232
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
233
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
234
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
235
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
236
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
237
|
+
*/
|
|
238
|
+
logic?: MappingCreateParams.Logic;
|
|
239
|
+
/**
|
|
240
|
+
* Template fat-create only. Optional initial property mappings. When omitted the
|
|
241
|
+
* mapping is seeded with template defaults for sources and non-default destination
|
|
242
|
+
* templates, and with `[]` for default destination templates.
|
|
243
|
+
*/
|
|
244
|
+
mappings?: Array<MappingCreateParams.Mapping>;
|
|
245
|
+
/**
|
|
246
|
+
* Template fat-create only. Override the auto-generated mapping name.
|
|
247
|
+
*/
|
|
248
|
+
name?: string | null;
|
|
249
|
+
/**
|
|
250
|
+
* Template fat-create variant: template id from `GET /rest/v1/mapping-templates`.
|
|
251
|
+
* Picks the property descriptor set used to validate `mappings[].property`.
|
|
252
|
+
* Required together with `entityId`.
|
|
253
|
+
*/
|
|
254
|
+
templateId?: string;
|
|
255
|
+
}
|
|
256
|
+
export declare namespace MappingCreateParams {
|
|
257
|
+
/**
|
|
258
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
259
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
260
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
261
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
262
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
263
|
+
*/
|
|
264
|
+
interface Logic {
|
|
265
|
+
/**
|
|
266
|
+
* All child nodes must match. Each child is a `MappingLogic` node.
|
|
267
|
+
*/
|
|
268
|
+
AND?: Array<unknown> | null;
|
|
269
|
+
condition?: Logic.Condition;
|
|
270
|
+
/**
|
|
271
|
+
* Negates a single child `MappingLogic` node.
|
|
272
|
+
*/
|
|
273
|
+
NOT?: unknown;
|
|
274
|
+
/**
|
|
275
|
+
* Any child node must match. Each child is a `MappingLogic` node.
|
|
276
|
+
*/
|
|
277
|
+
OR?: Array<unknown> | null;
|
|
278
|
+
}
|
|
279
|
+
namespace Logic {
|
|
280
|
+
interface Condition {
|
|
281
|
+
operator: 'Is' | 'IsNot' | 'Contains' | 'DoesNotContain' | 'StartsWith' | 'EndsWith' | 'IsFalsy' | 'IsTruthy' | 'IsNull' | 'IsNotNull' | 'IsUndefined' | 'IsNotUndefined' | 'IsGreaterThan' | 'IsGreaterThanOrEqual' | 'IsLessThan' | 'IsLessThanOrEqual' | 'IsIn' | 'IsNotIn' | 'IsFoundIn' | 'IsNotFoundIn' | 'IsTrue' | 'IsFalse' | 'IsBefore' | 'IsAfter' | 'IsBetween' | 'IsOnOrBefore' | 'IsOnOrAfter' | 'MatchesRegex' | 'MatchesRegexIgnoreCase' | 'DoesNotMatchRegex' | 'DoesNotMatchRegexIgnoreCase';
|
|
282
|
+
property: string;
|
|
283
|
+
value: string;
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
interface Mapping {
|
|
287
|
+
map: string;
|
|
288
|
+
property: string;
|
|
289
|
+
modification?: 'CamelCase' | 'DmaIP' | 'DomainOnly' | 'DomainPathOnly' | 'DomainPathUTMs' | 'DomainUTMs' | 'FakeDomain' | 'FakeDomainRealPath' | 'FakeIP' | 'FullUrl' | 'Hash' | 'HashMD5' | 'HashedCountry' | 'HashedDateOfBirth' | 'HashedGender' | 'HashedNormalized' | 'HashedNormalizedNoSpecialChars' | 'HashedPhone' | 'HashedState' | 'HashedZip' | 'KebabCase' | 'LowerCase' | 'None' | 'Null' | 'Redacted' | 'RegionalIP' | 'SnakeCase' | 'StartCase' | 'UpperCase' | null;
|
|
290
|
+
}
|
|
123
291
|
}
|
|
124
292
|
export interface MappingUpdateParams {
|
|
293
|
+
/**
|
|
294
|
+
* Flip the mapping on/off without changing other fields. `null` is treated as
|
|
295
|
+
* omitted.
|
|
296
|
+
*/
|
|
297
|
+
isEnabled?: boolean | null;
|
|
125
298
|
/**
|
|
126
299
|
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
127
300
|
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
@@ -169,7 +342,14 @@ export declare namespace MappingUpdateParams {
|
|
|
169
342
|
modification?: 'CamelCase' | 'DmaIP' | 'DomainOnly' | 'DomainPathOnly' | 'DomainPathUTMs' | 'DomainUTMs' | 'FakeDomain' | 'FakeDomainRealPath' | 'FakeIP' | 'FullUrl' | 'Hash' | 'HashMD5' | 'HashedCountry' | 'HashedDateOfBirth' | 'HashedGender' | 'HashedNormalized' | 'HashedNormalizedNoSpecialChars' | 'HashedPhone' | 'HashedState' | 'HashedZip' | 'KebabCase' | 'LowerCase' | 'None' | 'Null' | 'Redacted' | 'RegionalIP' | 'SnakeCase' | 'StartCase' | 'UpperCase' | null;
|
|
170
343
|
}
|
|
171
344
|
}
|
|
345
|
+
export interface MappingReorderParams {
|
|
346
|
+
/**
|
|
347
|
+
* Mapping ids in their new priority order, low priority index first. All ids must
|
|
348
|
+
* belong to the same parent entity (source or destination).
|
|
349
|
+
*/
|
|
350
|
+
uuids: Array<string>;
|
|
351
|
+
}
|
|
172
352
|
export declare namespace Mappings {
|
|
173
|
-
export { type MappingListResponse as MappingListResponse, type MappingCreateResponse as MappingCreateResponse, type MappingRetrieveResponse as MappingRetrieveResponse, type MappingUpdateResponse as MappingUpdateResponse, type MappingDeleteResponse as MappingDeleteResponse, type MappingListResponsesCursor as MappingListResponsesCursor, type MappingListParams as MappingListParams, type MappingCreateParams as MappingCreateParams, type MappingUpdateParams as MappingUpdateParams, };
|
|
353
|
+
export { type MappingListResponse as MappingListResponse, type MappingCreateResponse as MappingCreateResponse, type MappingRetrieveResponse as MappingRetrieveResponse, type MappingUpdateResponse as MappingUpdateResponse, type MappingDeleteResponse as MappingDeleteResponse, type MappingReorderResponse as MappingReorderResponse, type MappingListResponsesCursor as MappingListResponsesCursor, type MappingListParams as MappingListParams, type MappingCreateParams as MappingCreateParams, type MappingUpdateParams as MappingUpdateParams, type MappingReorderParams as MappingReorderParams, };
|
|
174
354
|
}
|
|
175
355
|
//# sourceMappingURL=mappings.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mappings.d.mts","sourceRoot":"","sources":["../src/resources/mappings.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"mappings.d.mts","sourceRoot":"","sources":["../src/resources/mappings.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,gCAA4B;AACjD,OAAO,EAAE,MAAM,EAAE,KAAK,YAAY,EAAE,WAAW,EAAE,+BAA2B;AAC5E,OAAO,EAAE,cAAc,EAAE,wCAAoC;AAG7D,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;OAKG;IACH,IAAI,CACF,KAAK,EAAE,iBAAiB,EACxB,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,0BAA0B,EAAE,mBAAmB,CAAC;IAI/D;;;;;;;;;;;;;;OAcG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAI9F;;OAEG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,uBAAuB,CAAC;IAInF;;;;;OAKG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAA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AAsB,EACrD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;CACH"}
|
package/resources/mappings.d.ts
CHANGED
|
@@ -11,7 +11,19 @@ export declare class Mappings extends APIResource {
|
|
|
11
11
|
*/
|
|
12
12
|
list(query: MappingListParams, options?: RequestOptions): PagePromise<MappingListResponsesCursor, MappingListResponse>;
|
|
13
13
|
/**
|
|
14
|
-
* Create a
|
|
14
|
+
* Create a mapping. Two body shapes are accepted:
|
|
15
|
+
*
|
|
16
|
+
* 1. Quick-create — `{ allowedEventId, destinationId }`. Binds an allowed event to
|
|
17
|
+
* a destination. Returns a slim entity with empty `mappings[]`; follow up with
|
|
18
|
+
* PATCH to populate fields.
|
|
19
|
+
* 2. Template fat-create —
|
|
20
|
+
* `{ entityId, templateId, mappings?, logic?, isEnabled?, name?, insertAfterIdx? }`.
|
|
21
|
+
* Lands a fully-shaped mapping in one round-trip. Use
|
|
22
|
+
* `GET /rest/v1/mapping-templates?entityId=...` to discover the valid
|
|
23
|
+
* `templateId` and `mappings[].property` values.
|
|
24
|
+
*
|
|
25
|
+
* Sending both `allowedEventId` and `templateId` returns 400. Requires scope:
|
|
26
|
+
* mapping:create
|
|
15
27
|
*/
|
|
16
28
|
create(body: MappingCreateParams, options?: RequestOptions): APIPromise<MappingCreateResponse>;
|
|
17
29
|
/**
|
|
@@ -19,14 +31,23 @@ export declare class Mappings extends APIResource {
|
|
|
19
31
|
*/
|
|
20
32
|
retrieve(id: string, options?: RequestOptions): APIPromise<MappingRetrieveResponse>;
|
|
21
33
|
/**
|
|
22
|
-
* Partially update a mapping. Only the fields you send are changed.
|
|
23
|
-
*
|
|
34
|
+
* Partially update a mapping. Only the fields you send are changed. Send
|
|
35
|
+
* `isEnabled: false` to pause the mapping without changing other fields (mirrors
|
|
36
|
+
* `status` on destinations). `mappings[]` is replaced wholesale when sent.
|
|
37
|
+
* Requires scope: mapping:update
|
|
24
38
|
*/
|
|
25
39
|
update(id: string, body: MappingUpdateParams, options?: RequestOptions): APIPromise<MappingUpdateResponse>;
|
|
26
40
|
/**
|
|
27
41
|
* Delete a mapping. Requires scope: mapping:delete
|
|
28
42
|
*/
|
|
29
43
|
delete(id: string, options?: RequestOptions): APIPromise<MappingDeleteResponse>;
|
|
44
|
+
/**
|
|
45
|
+
* Reassign `priority` for a set of mappings. Pass `{ uuids: [...] }` with the
|
|
46
|
+
* mapping ids in their new order — index 0 becomes the highest-priority mapping.
|
|
47
|
+
* All ids must belong to the same parent entity (source or destination); mixing
|
|
48
|
+
* entities returns 400. Requires scope: mapping:update
|
|
49
|
+
*/
|
|
50
|
+
reorder(body: MappingReorderParams, options?: RequestOptions): APIPromise<MappingReorderResponse>;
|
|
30
51
|
}
|
|
31
52
|
export type MappingListResponsesCursor = Cursor<MappingListResponse>;
|
|
32
53
|
export interface MappingListResponse {
|
|
@@ -35,6 +56,14 @@ export interface MappingListResponse {
|
|
|
35
56
|
mappings: Array<MappingListResponse.Mapping>;
|
|
36
57
|
destinationId?: string | null;
|
|
37
58
|
isDefaultMapping?: boolean | null;
|
|
59
|
+
/**
|
|
60
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
61
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
62
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
63
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
64
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
65
|
+
*/
|
|
66
|
+
logic?: unknown;
|
|
38
67
|
name?: string | null;
|
|
39
68
|
priority?: number | null;
|
|
40
69
|
sourceId?: string | null;
|
|
@@ -55,6 +84,14 @@ export interface MappingCreateResponse {
|
|
|
55
84
|
mappings: Array<MappingCreateResponse.Mapping>;
|
|
56
85
|
destinationId?: string | null;
|
|
57
86
|
isDefaultMapping?: boolean | null;
|
|
87
|
+
/**
|
|
88
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
89
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
90
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
91
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
92
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
93
|
+
*/
|
|
94
|
+
logic?: unknown;
|
|
58
95
|
name?: string | null;
|
|
59
96
|
priority?: number | null;
|
|
60
97
|
sourceId?: string | null;
|
|
@@ -75,6 +112,14 @@ export interface MappingRetrieveResponse {
|
|
|
75
112
|
mappings: Array<MappingRetrieveResponse.Mapping>;
|
|
76
113
|
destinationId?: string | null;
|
|
77
114
|
isDefaultMapping?: boolean | null;
|
|
115
|
+
/**
|
|
116
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
117
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
118
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
119
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
120
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
121
|
+
*/
|
|
122
|
+
logic?: unknown;
|
|
78
123
|
name?: string | null;
|
|
79
124
|
priority?: number | null;
|
|
80
125
|
sourceId?: string | null;
|
|
@@ -95,6 +140,14 @@ export interface MappingUpdateResponse {
|
|
|
95
140
|
mappings: Array<MappingUpdateResponse.Mapping>;
|
|
96
141
|
destinationId?: string | null;
|
|
97
142
|
isDefaultMapping?: boolean | null;
|
|
143
|
+
/**
|
|
144
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
145
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
146
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
147
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
148
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
149
|
+
*/
|
|
150
|
+
logic?: unknown;
|
|
98
151
|
name?: string | null;
|
|
99
152
|
priority?: number | null;
|
|
100
153
|
sourceId?: string | null;
|
|
@@ -110,6 +163,39 @@ export declare namespace MappingUpdateResponse {
|
|
|
110
163
|
}
|
|
111
164
|
}
|
|
112
165
|
export type MappingDeleteResponse = boolean;
|
|
166
|
+
export interface MappingReorderResponse {
|
|
167
|
+
entities: Array<MappingReorderResponse.Entity>;
|
|
168
|
+
}
|
|
169
|
+
export declare namespace MappingReorderResponse {
|
|
170
|
+
interface Entity {
|
|
171
|
+
id: string;
|
|
172
|
+
isEnabled: boolean;
|
|
173
|
+
mappings: Array<Entity.Mapping>;
|
|
174
|
+
destinationId?: string | null;
|
|
175
|
+
isDefaultMapping?: boolean | null;
|
|
176
|
+
/**
|
|
177
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
178
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
179
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
180
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
181
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
182
|
+
*/
|
|
183
|
+
logic?: unknown;
|
|
184
|
+
name?: string | null;
|
|
185
|
+
priority?: number | null;
|
|
186
|
+
sourceId?: string | null;
|
|
187
|
+
templateId?: string | null;
|
|
188
|
+
templateName?: string | null;
|
|
189
|
+
updatedAt?: string | null;
|
|
190
|
+
}
|
|
191
|
+
namespace Entity {
|
|
192
|
+
interface Mapping {
|
|
193
|
+
map: string;
|
|
194
|
+
property: string;
|
|
195
|
+
modification?: 'CamelCase' | 'DmaIP' | 'DomainOnly' | 'DomainPathOnly' | 'DomainPathUTMs' | 'DomainUTMs' | 'FakeDomain' | 'FakeDomainRealPath' | 'FakeIP' | 'FullUrl' | 'Hash' | 'HashMD5' | 'HashedCountry' | 'HashedDateOfBirth' | 'HashedGender' | 'HashedNormalized' | 'HashedNormalizedNoSpecialChars' | 'HashedPhone' | 'HashedState' | 'HashedZip' | 'KebabCase' | 'LowerCase' | 'None' | 'Null' | 'Redacted' | 'RegionalIP' | 'SnakeCase' | 'StartCase' | 'UpperCase' | null;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}
|
|
113
199
|
export interface MappingListParams extends CursorParams {
|
|
114
200
|
/**
|
|
115
201
|
* Filter mappings by their parent entity id. Must be a destination id or source
|
|
@@ -118,10 +204,97 @@ export interface MappingListParams extends CursorParams {
|
|
|
118
204
|
entityId: string;
|
|
119
205
|
}
|
|
120
206
|
export interface MappingCreateParams {
|
|
121
|
-
|
|
122
|
-
|
|
207
|
+
/**
|
|
208
|
+
* Quick-create variant: allowed event to bind the new mapping to. Required
|
|
209
|
+
* together with `destinationId`. Mutually exclusive with `templateId`/`entityId`.
|
|
210
|
+
*/
|
|
211
|
+
allowedEventId?: string;
|
|
212
|
+
/**
|
|
213
|
+
* Quick-create variant: destination that should receive events matched by this
|
|
214
|
+
* mapping. Required together with `allowedEventId`.
|
|
215
|
+
*/
|
|
216
|
+
destinationId?: string;
|
|
217
|
+
/**
|
|
218
|
+
* Template fat-create variant: destination or source id this mapping belongs to.
|
|
219
|
+
* Required together with `templateId`.
|
|
220
|
+
*/
|
|
221
|
+
entityId?: string;
|
|
222
|
+
/**
|
|
223
|
+
* Template fat-create only. Zero-based position in the destination/source priority
|
|
224
|
+
* order to insert this mapping after. Omit to append at the end.
|
|
225
|
+
*/
|
|
226
|
+
insertAfterIdx?: number;
|
|
227
|
+
/**
|
|
228
|
+
* Template fat-create only. Initial enabled state. Defaults to `true`.
|
|
229
|
+
*/
|
|
230
|
+
isEnabled?: boolean;
|
|
231
|
+
/**
|
|
232
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
233
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
234
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
235
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
236
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
237
|
+
*/
|
|
238
|
+
logic?: MappingCreateParams.Logic;
|
|
239
|
+
/**
|
|
240
|
+
* Template fat-create only. Optional initial property mappings. When omitted the
|
|
241
|
+
* mapping is seeded with template defaults for sources and non-default destination
|
|
242
|
+
* templates, and with `[]` for default destination templates.
|
|
243
|
+
*/
|
|
244
|
+
mappings?: Array<MappingCreateParams.Mapping>;
|
|
245
|
+
/**
|
|
246
|
+
* Template fat-create only. Override the auto-generated mapping name.
|
|
247
|
+
*/
|
|
248
|
+
name?: string | null;
|
|
249
|
+
/**
|
|
250
|
+
* Template fat-create variant: template id from `GET /rest/v1/mapping-templates`.
|
|
251
|
+
* Picks the property descriptor set used to validate `mappings[].property`.
|
|
252
|
+
* Required together with `entityId`.
|
|
253
|
+
*/
|
|
254
|
+
templateId?: string;
|
|
255
|
+
}
|
|
256
|
+
export declare namespace MappingCreateParams {
|
|
257
|
+
/**
|
|
258
|
+
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
259
|
+
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
260
|
+
* themselves `MappingLogic` nodes, so trees nest arbitrarily. Example leaf:
|
|
261
|
+
* `{ "condition": { "property": "$event.event", "operator": "Is", "value": "page_view" } }`.
|
|
262
|
+
* Example combinator: `{ "AND": [{ "condition": ... }, { "OR": [...] }] }`.
|
|
263
|
+
*/
|
|
264
|
+
interface Logic {
|
|
265
|
+
/**
|
|
266
|
+
* All child nodes must match. Each child is a `MappingLogic` node.
|
|
267
|
+
*/
|
|
268
|
+
AND?: Array<unknown> | null;
|
|
269
|
+
condition?: Logic.Condition;
|
|
270
|
+
/**
|
|
271
|
+
* Negates a single child `MappingLogic` node.
|
|
272
|
+
*/
|
|
273
|
+
NOT?: unknown;
|
|
274
|
+
/**
|
|
275
|
+
* Any child node must match. Each child is a `MappingLogic` node.
|
|
276
|
+
*/
|
|
277
|
+
OR?: Array<unknown> | null;
|
|
278
|
+
}
|
|
279
|
+
namespace Logic {
|
|
280
|
+
interface Condition {
|
|
281
|
+
operator: 'Is' | 'IsNot' | 'Contains' | 'DoesNotContain' | 'StartsWith' | 'EndsWith' | 'IsFalsy' | 'IsTruthy' | 'IsNull' | 'IsNotNull' | 'IsUndefined' | 'IsNotUndefined' | 'IsGreaterThan' | 'IsGreaterThanOrEqual' | 'IsLessThan' | 'IsLessThanOrEqual' | 'IsIn' | 'IsNotIn' | 'IsFoundIn' | 'IsNotFoundIn' | 'IsTrue' | 'IsFalse' | 'IsBefore' | 'IsAfter' | 'IsBetween' | 'IsOnOrBefore' | 'IsOnOrAfter' | 'MatchesRegex' | 'MatchesRegexIgnoreCase' | 'DoesNotMatchRegex' | 'DoesNotMatchRegexIgnoreCase';
|
|
282
|
+
property: string;
|
|
283
|
+
value: string;
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
interface Mapping {
|
|
287
|
+
map: string;
|
|
288
|
+
property: string;
|
|
289
|
+
modification?: 'CamelCase' | 'DmaIP' | 'DomainOnly' | 'DomainPathOnly' | 'DomainPathUTMs' | 'DomainUTMs' | 'FakeDomain' | 'FakeDomainRealPath' | 'FakeIP' | 'FullUrl' | 'Hash' | 'HashMD5' | 'HashedCountry' | 'HashedDateOfBirth' | 'HashedGender' | 'HashedNormalized' | 'HashedNormalizedNoSpecialChars' | 'HashedPhone' | 'HashedState' | 'HashedZip' | 'KebabCase' | 'LowerCase' | 'None' | 'Null' | 'Redacted' | 'RegionalIP' | 'SnakeCase' | 'StartCase' | 'UpperCase' | null;
|
|
290
|
+
}
|
|
123
291
|
}
|
|
124
292
|
export interface MappingUpdateParams {
|
|
293
|
+
/**
|
|
294
|
+
* Flip the mapping on/off without changing other fields. `null` is treated as
|
|
295
|
+
* omitted.
|
|
296
|
+
*/
|
|
297
|
+
isEnabled?: boolean | null;
|
|
125
298
|
/**
|
|
126
299
|
* Condition tree gating when this mapping fires. A node is either a leaf
|
|
127
300
|
* `condition` or a combinator (`AND`, `OR`, `NOT`). Combinator children are
|
|
@@ -169,7 +342,14 @@ export declare namespace MappingUpdateParams {
|
|
|
169
342
|
modification?: 'CamelCase' | 'DmaIP' | 'DomainOnly' | 'DomainPathOnly' | 'DomainPathUTMs' | 'DomainUTMs' | 'FakeDomain' | 'FakeDomainRealPath' | 'FakeIP' | 'FullUrl' | 'Hash' | 'HashMD5' | 'HashedCountry' | 'HashedDateOfBirth' | 'HashedGender' | 'HashedNormalized' | 'HashedNormalizedNoSpecialChars' | 'HashedPhone' | 'HashedState' | 'HashedZip' | 'KebabCase' | 'LowerCase' | 'None' | 'Null' | 'Redacted' | 'RegionalIP' | 'SnakeCase' | 'StartCase' | 'UpperCase' | null;
|
|
170
343
|
}
|
|
171
344
|
}
|
|
345
|
+
export interface MappingReorderParams {
|
|
346
|
+
/**
|
|
347
|
+
* Mapping ids in their new priority order, low priority index first. All ids must
|
|
348
|
+
* belong to the same parent entity (source or destination).
|
|
349
|
+
*/
|
|
350
|
+
uuids: Array<string>;
|
|
351
|
+
}
|
|
172
352
|
export declare namespace Mappings {
|
|
173
|
-
export { type MappingListResponse as MappingListResponse, type MappingCreateResponse as MappingCreateResponse, type MappingRetrieveResponse as MappingRetrieveResponse, type MappingUpdateResponse as MappingUpdateResponse, type MappingDeleteResponse as MappingDeleteResponse, type MappingListResponsesCursor as MappingListResponsesCursor, type MappingListParams as MappingListParams, type MappingCreateParams as MappingCreateParams, type MappingUpdateParams as MappingUpdateParams, };
|
|
353
|
+
export { type MappingListResponse as MappingListResponse, type MappingCreateResponse as MappingCreateResponse, type MappingRetrieveResponse as MappingRetrieveResponse, type MappingUpdateResponse as MappingUpdateResponse, type MappingDeleteResponse as MappingDeleteResponse, type MappingReorderResponse as MappingReorderResponse, type MappingListResponsesCursor as MappingListResponsesCursor, type MappingListParams as MappingListParams, type MappingCreateParams as MappingCreateParams, type MappingUpdateParams as MappingUpdateParams, type MappingReorderParams as MappingReorderParams, };
|
|
174
354
|
}
|
|
175
355
|
//# sourceMappingURL=mappings.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mappings.d.ts","sourceRoot":"","sources":["../src/resources/mappings.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"mappings.d.ts","sourceRoot":"","sources":["../src/resources/mappings.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AACjD,OAAO,EAAE,MAAM,EAAE,KAAK,YAAY,EAAE,WAAW,EAAE,8BAA2B;AAC5E,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAG7D,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;OAKG;IACH,IAAI,CACF,KAAK,EAAE,iBAAiB,EACxB,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,0BAA0B,EAAE,mBAAmB,CAAC;IAI/D;;;;;;;;;;;;;;OAcG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAI9F;;OAEG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,uBAAuB,CAAC;IAInF;;;;;OAKG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,G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AAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;CACH"}
|
package/resources/mappings.js
CHANGED
|
@@ -16,7 +16,19 @@ class Mappings extends resource_1.APIResource {
|
|
|
16
16
|
return this._client.getAPIList('/rest/v1/mappings', (pagination_1.Cursor), { query, ...options });
|
|
17
17
|
}
|
|
18
18
|
/**
|
|
19
|
-
* Create a
|
|
19
|
+
* Create a mapping. Two body shapes are accepted:
|
|
20
|
+
*
|
|
21
|
+
* 1. Quick-create — `{ allowedEventId, destinationId }`. Binds an allowed event to
|
|
22
|
+
* a destination. Returns a slim entity with empty `mappings[]`; follow up with
|
|
23
|
+
* PATCH to populate fields.
|
|
24
|
+
* 2. Template fat-create —
|
|
25
|
+
* `{ entityId, templateId, mappings?, logic?, isEnabled?, name?, insertAfterIdx? }`.
|
|
26
|
+
* Lands a fully-shaped mapping in one round-trip. Use
|
|
27
|
+
* `GET /rest/v1/mapping-templates?entityId=...` to discover the valid
|
|
28
|
+
* `templateId` and `mappings[].property` values.
|
|
29
|
+
*
|
|
30
|
+
* Sending both `allowedEventId` and `templateId` returns 400. Requires scope:
|
|
31
|
+
* mapping:create
|
|
20
32
|
*/
|
|
21
33
|
create(body, options) {
|
|
22
34
|
return this._client.post('/rest/v1/mappings', { body, ...options });
|
|
@@ -28,8 +40,10 @@ class Mappings extends resource_1.APIResource {
|
|
|
28
40
|
return this._client.get((0, path_1.path) `/rest/v1/mappings/${id}`, options);
|
|
29
41
|
}
|
|
30
42
|
/**
|
|
31
|
-
* Partially update a mapping. Only the fields you send are changed.
|
|
32
|
-
*
|
|
43
|
+
* Partially update a mapping. Only the fields you send are changed. Send
|
|
44
|
+
* `isEnabled: false` to pause the mapping without changing other fields (mirrors
|
|
45
|
+
* `status` on destinations). `mappings[]` is replaced wholesale when sent.
|
|
46
|
+
* Requires scope: mapping:update
|
|
33
47
|
*/
|
|
34
48
|
update(id, body, options) {
|
|
35
49
|
return this._client.patch((0, path_1.path) `/rest/v1/mappings/${id}`, { body, ...options });
|
|
@@ -40,6 +54,15 @@ class Mappings extends resource_1.APIResource {
|
|
|
40
54
|
delete(id, options) {
|
|
41
55
|
return this._client.delete((0, path_1.path) `/rest/v1/mappings/${id}`, options);
|
|
42
56
|
}
|
|
57
|
+
/**
|
|
58
|
+
* Reassign `priority` for a set of mappings. Pass `{ uuids: [...] }` with the
|
|
59
|
+
* mapping ids in their new order — index 0 becomes the highest-priority mapping.
|
|
60
|
+
* All ids must belong to the same parent entity (source or destination); mixing
|
|
61
|
+
* entities returns 400. Requires scope: mapping:update
|
|
62
|
+
*/
|
|
63
|
+
reorder(body, options) {
|
|
64
|
+
return this._client.post('/rest/v1/mappings/reorder', { body, ...options });
|
|
65
|
+
}
|
|
43
66
|
}
|
|
44
67
|
exports.Mappings = Mappings;
|
|
45
68
|
//# sourceMappingURL=mappings.js.map
|