@oursprivacy/platform-sdk 1.43.0 → 1.44.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 (75) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/client.d.mts +8 -2
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +8 -2
  5. package/client.d.ts.map +1 -1
  6. package/client.js +6 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +6 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/audience-conversion-reports.d.mts +216 -0
  12. package/resources/audience-conversion-reports.d.mts.map +1 -0
  13. package/resources/audience-conversion-reports.d.ts +216 -0
  14. package/resources/audience-conversion-reports.d.ts.map +1 -0
  15. package/resources/audience-conversion-reports.js +55 -0
  16. package/resources/audience-conversion-reports.js.map +1 -0
  17. package/resources/audience-conversion-reports.mjs +51 -0
  18. package/resources/audience-conversion-reports.mjs.map +1 -0
  19. package/resources/destinations.d.mts +20 -0
  20. package/resources/destinations.d.mts.map +1 -1
  21. package/resources/destinations.d.ts +20 -0
  22. package/resources/destinations.d.ts.map +1 -1
  23. package/resources/experiments.d.mts +6 -4
  24. package/resources/experiments.d.mts.map +1 -1
  25. package/resources/experiments.d.ts +6 -4
  26. package/resources/experiments.d.ts.map +1 -1
  27. package/resources/experiments.js +4 -3
  28. package/resources/experiments.js.map +1 -1
  29. package/resources/experiments.mjs +4 -3
  30. package/resources/experiments.mjs.map +1 -1
  31. package/resources/funnels.d.mts +811 -5
  32. package/resources/funnels.d.mts.map +1 -1
  33. package/resources/funnels.d.ts +811 -5
  34. package/resources/funnels.d.ts.map +1 -1
  35. package/resources/funnels.js +22 -0
  36. package/resources/funnels.js.map +1 -1
  37. package/resources/funnels.mjs +22 -0
  38. package/resources/funnels.mjs.map +1 -1
  39. package/resources/index.d.mts +3 -1
  40. package/resources/index.d.mts.map +1 -1
  41. package/resources/index.d.ts +3 -1
  42. package/resources/index.d.ts.map +1 -1
  43. package/resources/index.js +5 -1
  44. package/resources/index.js.map +1 -1
  45. package/resources/index.mjs +2 -0
  46. package/resources/index.mjs.map +1 -1
  47. package/resources/video-channels.d.mts +237 -0
  48. package/resources/video-channels.d.mts.map +1 -0
  49. package/resources/video-channels.d.ts +237 -0
  50. package/resources/video-channels.d.ts.map +1 -0
  51. package/resources/video-channels.js +95 -0
  52. package/resources/video-channels.js.map +1 -0
  53. package/resources/video-channels.mjs +91 -0
  54. package/resources/video-channels.mjs.map +1 -0
  55. package/resources/web-scanners.d.mts +10 -8
  56. package/resources/web-scanners.d.mts.map +1 -1
  57. package/resources/web-scanners.d.ts +10 -8
  58. package/resources/web-scanners.d.ts.map +1 -1
  59. package/resources/web-scanners.js +9 -8
  60. package/resources/web-scanners.js.map +1 -1
  61. package/resources/web-scanners.mjs +9 -8
  62. package/resources/web-scanners.mjs.map +1 -1
  63. package/src/client.ts +78 -0
  64. package/src/resources/audience-conversion-reports.ts +466 -0
  65. package/src/resources/destinations.ts +113 -0
  66. package/src/resources/experiments.ts +6 -4
  67. package/src/resources/funnels.ts +1366 -4
  68. package/src/resources/index.ts +36 -0
  69. package/src/resources/video-channels.ts +405 -0
  70. package/src/resources/web-scanners.ts +11 -8
  71. package/src/version.ts +1 -1
  72. package/version.d.mts +1 -1
  73. package/version.d.ts +1 -1
  74. package/version.js +1 -1
  75. package/version.mjs +1 -1
@@ -10,12 +10,28 @@ export declare class Funnels extends APIResource {
10
10
  * decide whether results are available. Requires scope: web-analytics:view
11
11
  */
12
12
  list(options?: RequestOptions): APIPromise<FunnelListResponse>;
13
+ /**
14
+ * Create a session-based funnel with 2 to 10 ordered event steps. Returns the
15
+ * complete saved configuration. Requires scope: web-analytics:write
16
+ */
17
+ create(body: FunnelCreateParams, options?: RequestOptions): APIPromise<FunnelCreateResponse>;
13
18
  /**
14
19
  * Fetch a single funnel configuration by its id. Returns `404` when the funnel
15
20
  * does not exist or belongs to a different account. Requires scope:
16
21
  * web-analytics:view
17
22
  */
18
23
  retrieve(id: string, options?: RequestOptions): APIPromise<FunnelRetrieveResponse>;
24
+ /**
25
+ * Update one or more Funnel fields. Omitted fields remain unchanged. Send `null`
26
+ * to clear an optional field. `globalLogic` and legacy `utmFilters` cannot be set
27
+ * together. Requires scope: web-analytics:write
28
+ */
29
+ update(id: string, body: FunnelUpdateParams, options?: RequestOptions): APIPromise<FunnelUpdateResponse>;
30
+ /**
31
+ * Delete a Funnel configuration. Existing analytics data is unaffected. Requires
32
+ * scope: web-analytics:write
33
+ */
34
+ delete(id: string, options?: RequestOptions): APIPromise<FunnelDeleteResponse>;
19
35
  /**
20
36
  * Compute funnel step analytics for a funnel over a date window. Returns per-step
21
37
  * visitor counts, conversion rates, drop-off rates, average time to next step, and
@@ -44,12 +60,18 @@ export declare namespace FunnelListResponse {
44
60
  conversionWindow?: Entity.ConversionWindow | null;
45
61
  countingMethod?: 'UNIQUES' | 'TOTALS' | 'SESSIONS' | null;
46
62
  description?: string | null;
63
+ /**
64
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
65
+ * UTM filters.
66
+ */
67
+ globalLogic?: Entity.GlobalLogic | null;
47
68
  reportDateRange?: Entity.ReportDateRange | null;
48
69
  stepOrder?: 'EXACT' | 'ANY' | null;
49
70
  /**
50
- * UTM filter object (JSON).
71
+ * Legacy exact-match UTM filters. Do not combine with globalLogic; globalLogic
72
+ * takes precedence.
51
73
  */
52
- utmFilters?: unknown;
74
+ utmFilters?: unknown | null;
53
75
  watched?: boolean | null;
54
76
  }
55
77
  namespace Entity {
@@ -62,17 +84,275 @@ export declare namespace FunnelListResponse {
62
84
  * Step-level event filters (JSON object).
63
85
  */
64
86
  filters?: unknown;
87
+ /**
88
+ * Step-level event logic.
89
+ */
90
+ logic?: Step.Logic | null;
91
+ }
92
+ namespace Step {
93
+ /**
94
+ * Step-level event logic.
95
+ */
96
+ interface Logic {
97
+ /**
98
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
99
+ * or combinator).
100
+ */
101
+ AND?: Array<unknown> | null;
102
+ condition?: Logic.Condition;
103
+ /**
104
+ * Negates a single child logic node.
105
+ */
106
+ NOT?: unknown;
107
+ /**
108
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
109
+ * or combinator).
110
+ */
111
+ OR?: Array<unknown> | null;
112
+ }
113
+ namespace Logic {
114
+ interface Condition {
115
+ /**
116
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
117
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
118
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
119
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
120
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
121
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
122
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
123
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
124
+ */
125
+ 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';
126
+ /**
127
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
128
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
129
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
130
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
131
+ * and would be compared as a literal string.
132
+ */
133
+ property: string;
134
+ /**
135
+ * String compared against the resolved property. Operators that take no value
136
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
137
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
138
+ */
139
+ value: string;
140
+ }
141
+ }
65
142
  }
66
143
  interface ConversionWindow {
67
144
  unit: 'MINUTES' | 'HOURS' | 'DAYS';
68
145
  value: number;
69
146
  }
147
+ /**
148
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
149
+ * UTM filters.
150
+ */
151
+ interface GlobalLogic {
152
+ /**
153
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
154
+ * or combinator).
155
+ */
156
+ AND?: Array<unknown> | null;
157
+ condition?: GlobalLogic.Condition;
158
+ /**
159
+ * Negates a single child logic node.
160
+ */
161
+ NOT?: unknown;
162
+ /**
163
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
164
+ * or combinator).
165
+ */
166
+ OR?: Array<unknown> | null;
167
+ }
168
+ namespace GlobalLogic {
169
+ interface Condition {
170
+ /**
171
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
172
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
173
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
174
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
175
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
176
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
177
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
178
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
179
+ */
180
+ 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';
181
+ /**
182
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
183
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
184
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
185
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
186
+ * and would be compared as a literal string.
187
+ */
188
+ property: string;
189
+ /**
190
+ * String compared against the resolved property. Operators that take no value
191
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
192
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
193
+ */
194
+ value: string;
195
+ }
196
+ }
70
197
  interface ReportDateRange {
71
198
  from: string;
72
199
  to: string;
73
200
  }
74
201
  }
75
202
  }
203
+ /**
204
+ * Created funnel configuration
205
+ */
206
+ export interface FunnelCreateResponse {
207
+ createdAt: string;
208
+ funnelId: string;
209
+ funnelType: 'SESSION_BASED' | 'VISITOR_BASED';
210
+ name: string;
211
+ status: 'READY' | 'PROCESSING';
212
+ steps: Array<FunnelCreateResponse.Step>;
213
+ updatedAt: string;
214
+ conversionWindow?: FunnelCreateResponse.ConversionWindow | null;
215
+ countingMethod?: 'UNIQUES' | 'TOTALS' | 'SESSIONS' | null;
216
+ description?: string | null;
217
+ /**
218
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
219
+ * UTM filters.
220
+ */
221
+ globalLogic?: FunnelCreateResponse.GlobalLogic | null;
222
+ reportDateRange?: FunnelCreateResponse.ReportDateRange | null;
223
+ stepOrder?: 'EXACT' | 'ANY' | null;
224
+ /**
225
+ * Legacy exact-match UTM filters. Do not combine with globalLogic; globalLogic
226
+ * takes precedence.
227
+ */
228
+ utmFilters?: unknown | null;
229
+ watched?: boolean | null;
230
+ }
231
+ export declare namespace FunnelCreateResponse {
232
+ interface Step {
233
+ eventName: string;
234
+ name: string;
235
+ order: number;
236
+ stepId: string;
237
+ /**
238
+ * Step-level event filters (JSON object).
239
+ */
240
+ filters?: unknown;
241
+ /**
242
+ * Step-level event logic.
243
+ */
244
+ logic?: Step.Logic | null;
245
+ }
246
+ namespace Step {
247
+ /**
248
+ * Step-level event logic.
249
+ */
250
+ interface Logic {
251
+ /**
252
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
253
+ * or combinator).
254
+ */
255
+ AND?: Array<unknown> | null;
256
+ condition?: Logic.Condition;
257
+ /**
258
+ * Negates a single child logic node.
259
+ */
260
+ NOT?: unknown;
261
+ /**
262
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
263
+ * or combinator).
264
+ */
265
+ OR?: Array<unknown> | null;
266
+ }
267
+ namespace Logic {
268
+ interface Condition {
269
+ /**
270
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
271
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
272
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
273
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
274
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
275
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
276
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
277
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
278
+ */
279
+ 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';
280
+ /**
281
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
282
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
283
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
284
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
285
+ * and would be compared as a literal string.
286
+ */
287
+ property: string;
288
+ /**
289
+ * String compared against the resolved property. Operators that take no value
290
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
291
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
292
+ */
293
+ value: string;
294
+ }
295
+ }
296
+ }
297
+ interface ConversionWindow {
298
+ unit: 'MINUTES' | 'HOURS' | 'DAYS';
299
+ value: number;
300
+ }
301
+ /**
302
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
303
+ * UTM filters.
304
+ */
305
+ interface GlobalLogic {
306
+ /**
307
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
308
+ * or combinator).
309
+ */
310
+ AND?: Array<unknown> | null;
311
+ condition?: GlobalLogic.Condition;
312
+ /**
313
+ * Negates a single child logic node.
314
+ */
315
+ NOT?: unknown;
316
+ /**
317
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
318
+ * or combinator).
319
+ */
320
+ OR?: Array<unknown> | null;
321
+ }
322
+ namespace GlobalLogic {
323
+ interface Condition {
324
+ /**
325
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
326
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
327
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
328
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
329
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
330
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
331
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
332
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
333
+ */
334
+ 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';
335
+ /**
336
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
337
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
338
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
339
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
340
+ * and would be compared as a literal string.
341
+ */
342
+ property: string;
343
+ /**
344
+ * String compared against the resolved property. Operators that take no value
345
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
346
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
347
+ */
348
+ value: string;
349
+ }
350
+ }
351
+ interface ReportDateRange {
352
+ from: string;
353
+ to: string;
354
+ }
355
+ }
76
356
  /**
77
357
  * Funnel configuration details.
78
358
  */
@@ -87,12 +367,18 @@ export interface FunnelRetrieveResponse {
87
367
  conversionWindow?: FunnelRetrieveResponse.ConversionWindow | null;
88
368
  countingMethod?: 'UNIQUES' | 'TOTALS' | 'SESSIONS' | null;
89
369
  description?: string | null;
370
+ /**
371
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
372
+ * UTM filters.
373
+ */
374
+ globalLogic?: FunnelRetrieveResponse.GlobalLogic | null;
90
375
  reportDateRange?: FunnelRetrieveResponse.ReportDateRange | null;
91
376
  stepOrder?: 'EXACT' | 'ANY' | null;
92
377
  /**
93
- * UTM filter object (JSON).
378
+ * Legacy exact-match UTM filters. Do not combine with globalLogic; globalLogic
379
+ * takes precedence.
94
380
  */
95
- utmFilters?: unknown;
381
+ utmFilters?: unknown | null;
96
382
  watched?: boolean | null;
97
383
  }
98
384
  export declare namespace FunnelRetrieveResponse {
@@ -105,16 +391,278 @@ export declare namespace FunnelRetrieveResponse {
105
391
  * Step-level event filters (JSON object).
106
392
  */
107
393
  filters?: unknown;
394
+ /**
395
+ * Step-level event logic.
396
+ */
397
+ logic?: Step.Logic | null;
398
+ }
399
+ namespace Step {
400
+ /**
401
+ * Step-level event logic.
402
+ */
403
+ interface Logic {
404
+ /**
405
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
406
+ * or combinator).
407
+ */
408
+ AND?: Array<unknown> | null;
409
+ condition?: Logic.Condition;
410
+ /**
411
+ * Negates a single child logic node.
412
+ */
413
+ NOT?: unknown;
414
+ /**
415
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
416
+ * or combinator).
417
+ */
418
+ OR?: Array<unknown> | null;
419
+ }
420
+ namespace Logic {
421
+ interface Condition {
422
+ /**
423
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
424
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
425
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
426
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
427
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
428
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
429
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
430
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
431
+ */
432
+ 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';
433
+ /**
434
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
435
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
436
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
437
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
438
+ * and would be compared as a literal string.
439
+ */
440
+ property: string;
441
+ /**
442
+ * String compared against the resolved property. Operators that take no value
443
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
444
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
445
+ */
446
+ value: string;
447
+ }
448
+ }
108
449
  }
109
450
  interface ConversionWindow {
110
451
  unit: 'MINUTES' | 'HOURS' | 'DAYS';
111
452
  value: number;
112
453
  }
454
+ /**
455
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
456
+ * UTM filters.
457
+ */
458
+ interface GlobalLogic {
459
+ /**
460
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
461
+ * or combinator).
462
+ */
463
+ AND?: Array<unknown> | null;
464
+ condition?: GlobalLogic.Condition;
465
+ /**
466
+ * Negates a single child logic node.
467
+ */
468
+ NOT?: unknown;
469
+ /**
470
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
471
+ * or combinator).
472
+ */
473
+ OR?: Array<unknown> | null;
474
+ }
475
+ namespace GlobalLogic {
476
+ interface Condition {
477
+ /**
478
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
479
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
480
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
481
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
482
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
483
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
484
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
485
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
486
+ */
487
+ 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';
488
+ /**
489
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
490
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
491
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
492
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
493
+ * and would be compared as a literal string.
494
+ */
495
+ property: string;
496
+ /**
497
+ * String compared against the resolved property. Operators that take no value
498
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
499
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
500
+ */
501
+ value: string;
502
+ }
503
+ }
113
504
  interface ReportDateRange {
114
505
  from: string;
115
506
  to: string;
116
507
  }
117
508
  }
509
+ /**
510
+ * Updated funnel configuration
511
+ */
512
+ export interface FunnelUpdateResponse {
513
+ createdAt: string;
514
+ funnelId: string;
515
+ funnelType: 'SESSION_BASED' | 'VISITOR_BASED';
516
+ name: string;
517
+ status: 'READY' | 'PROCESSING';
518
+ steps: Array<FunnelUpdateResponse.Step>;
519
+ updatedAt: string;
520
+ conversionWindow?: FunnelUpdateResponse.ConversionWindow | null;
521
+ countingMethod?: 'UNIQUES' | 'TOTALS' | 'SESSIONS' | null;
522
+ description?: string | null;
523
+ /**
524
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
525
+ * UTM filters.
526
+ */
527
+ globalLogic?: FunnelUpdateResponse.GlobalLogic | null;
528
+ reportDateRange?: FunnelUpdateResponse.ReportDateRange | null;
529
+ stepOrder?: 'EXACT' | 'ANY' | null;
530
+ /**
531
+ * Legacy exact-match UTM filters. Do not combine with globalLogic; globalLogic
532
+ * takes precedence.
533
+ */
534
+ utmFilters?: unknown | null;
535
+ watched?: boolean | null;
536
+ }
537
+ export declare namespace FunnelUpdateResponse {
538
+ interface Step {
539
+ eventName: string;
540
+ name: string;
541
+ order: number;
542
+ stepId: string;
543
+ /**
544
+ * Step-level event filters (JSON object).
545
+ */
546
+ filters?: unknown;
547
+ /**
548
+ * Step-level event logic.
549
+ */
550
+ logic?: Step.Logic | null;
551
+ }
552
+ namespace Step {
553
+ /**
554
+ * Step-level event logic.
555
+ */
556
+ interface Logic {
557
+ /**
558
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
559
+ * or combinator).
560
+ */
561
+ AND?: Array<unknown> | null;
562
+ condition?: Logic.Condition;
563
+ /**
564
+ * Negates a single child logic node.
565
+ */
566
+ NOT?: unknown;
567
+ /**
568
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
569
+ * or combinator).
570
+ */
571
+ OR?: Array<unknown> | null;
572
+ }
573
+ namespace Logic {
574
+ interface Condition {
575
+ /**
576
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
577
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
578
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
579
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
580
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
581
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
582
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
583
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
584
+ */
585
+ 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';
586
+ /**
587
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
588
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
589
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
590
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
591
+ * and would be compared as a literal string.
592
+ */
593
+ property: string;
594
+ /**
595
+ * String compared against the resolved property. Operators that take no value
596
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
597
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
598
+ */
599
+ value: string;
600
+ }
601
+ }
602
+ }
603
+ interface ConversionWindow {
604
+ unit: 'MINUTES' | 'HOURS' | 'DAYS';
605
+ value: number;
606
+ }
607
+ /**
608
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
609
+ * UTM filters.
610
+ */
611
+ interface GlobalLogic {
612
+ /**
613
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
614
+ * or combinator).
615
+ */
616
+ AND?: Array<unknown> | null;
617
+ condition?: GlobalLogic.Condition;
618
+ /**
619
+ * Negates a single child logic node.
620
+ */
621
+ NOT?: unknown;
622
+ /**
623
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
624
+ * or combinator).
625
+ */
626
+ OR?: Array<unknown> | null;
627
+ }
628
+ namespace GlobalLogic {
629
+ interface Condition {
630
+ /**
631
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
632
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
633
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
634
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
635
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
636
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
637
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
638
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
639
+ */
640
+ 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';
641
+ /**
642
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
643
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
644
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
645
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
646
+ * and would be compared as a literal string.
647
+ */
648
+ property: string;
649
+ /**
650
+ * String compared against the resolved property. Operators that take no value
651
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
652
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
653
+ */
654
+ value: string;
655
+ }
656
+ }
657
+ interface ReportDateRange {
658
+ from: string;
659
+ to: string;
660
+ }
661
+ }
662
+ export interface FunnelDeleteResponse {
663
+ deleted: true;
664
+ id: string;
665
+ }
118
666
  export interface FunnelResultsResponse {
119
667
  /**
120
668
  * Conversion rate from first step to last step as a percentage.
@@ -153,6 +701,264 @@ export declare namespace FunnelResultsResponse {
153
701
  avgTimeToNextStep?: number | null;
154
702
  }
155
703
  }
704
+ export interface FunnelCreateParams {
705
+ name: string;
706
+ steps: Array<FunnelCreateParams.Step>;
707
+ conversionWindow?: unknown | null;
708
+ countingMethod?: string | null;
709
+ description?: string | null;
710
+ /**
711
+ * Funnels are session-based. `SESSION_BASED` is the only supported value and is
712
+ * applied when omitted.
713
+ */
714
+ funnelType?: 'SESSION_BASED';
715
+ /**
716
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
717
+ * UTM filters.
718
+ */
719
+ globalLogic?: FunnelCreateParams.GlobalLogic | null;
720
+ stepOrder?: string | null;
721
+ /**
722
+ * Legacy exact-match UTM filters. Do not combine with globalLogic; globalLogic
723
+ * takes precedence.
724
+ */
725
+ utmFilters?: unknown | null;
726
+ watched?: boolean | null;
727
+ }
728
+ export declare namespace FunnelCreateParams {
729
+ interface Step {
730
+ eventName: string;
731
+ name: string;
732
+ order: number;
733
+ filters?: unknown | null;
734
+ logic?: Step.Logic | null;
735
+ }
736
+ namespace Step {
737
+ interface Logic {
738
+ /**
739
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
740
+ * or combinator).
741
+ */
742
+ AND?: Array<unknown> | null;
743
+ condition?: Logic.Condition;
744
+ /**
745
+ * Negates a single child logic node.
746
+ */
747
+ NOT?: unknown;
748
+ /**
749
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
750
+ * or combinator).
751
+ */
752
+ OR?: Array<unknown> | null;
753
+ }
754
+ namespace Logic {
755
+ interface Condition {
756
+ /**
757
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
758
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
759
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
760
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
761
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
762
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
763
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
764
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
765
+ */
766
+ 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';
767
+ /**
768
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
769
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
770
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
771
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
772
+ * and would be compared as a literal string.
773
+ */
774
+ property: string;
775
+ /**
776
+ * String compared against the resolved property. Operators that take no value
777
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
778
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
779
+ */
780
+ value: string;
781
+ }
782
+ }
783
+ }
784
+ /**
785
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
786
+ * UTM filters.
787
+ */
788
+ interface GlobalLogic {
789
+ /**
790
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
791
+ * or combinator).
792
+ */
793
+ AND?: Array<unknown> | null;
794
+ condition?: GlobalLogic.Condition;
795
+ /**
796
+ * Negates a single child logic node.
797
+ */
798
+ NOT?: unknown;
799
+ /**
800
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
801
+ * or combinator).
802
+ */
803
+ OR?: Array<unknown> | null;
804
+ }
805
+ namespace GlobalLogic {
806
+ interface Condition {
807
+ /**
808
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
809
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
810
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
811
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
812
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
813
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
814
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
815
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
816
+ */
817
+ 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';
818
+ /**
819
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
820
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
821
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
822
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
823
+ * and would be compared as a literal string.
824
+ */
825
+ property: string;
826
+ /**
827
+ * String compared against the resolved property. Operators that take no value
828
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
829
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
830
+ */
831
+ value: string;
832
+ }
833
+ }
834
+ }
835
+ export interface FunnelUpdateParams {
836
+ conversionWindow?: unknown | null;
837
+ countingMethod?: string | null;
838
+ description?: string | null;
839
+ funnelType?: 'SESSION_BASED';
840
+ /**
841
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
842
+ * UTM filters.
843
+ */
844
+ globalLogic?: FunnelUpdateParams.GlobalLogic | null;
845
+ name?: string;
846
+ stepOrder?: string | null;
847
+ steps?: Array<FunnelUpdateParams.Step>;
848
+ /**
849
+ * Legacy exact-match UTM filters. Do not combine with globalLogic; globalLogic
850
+ * takes precedence.
851
+ */
852
+ utmFilters?: unknown | null;
853
+ watched?: boolean | null;
854
+ }
855
+ export declare namespace FunnelUpdateParams {
856
+ /**
857
+ * Nested visitor logic for the entire funnel. When supplied, this replaces legacy
858
+ * UTM filters.
859
+ */
860
+ interface GlobalLogic {
861
+ /**
862
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
863
+ * or combinator).
864
+ */
865
+ AND?: Array<unknown> | null;
866
+ condition?: GlobalLogic.Condition;
867
+ /**
868
+ * Negates a single child logic node.
869
+ */
870
+ NOT?: unknown;
871
+ /**
872
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
873
+ * or combinator).
874
+ */
875
+ OR?: Array<unknown> | null;
876
+ }
877
+ namespace GlobalLogic {
878
+ interface Condition {
879
+ /**
880
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
881
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
882
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
883
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
884
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
885
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
886
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
887
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
888
+ */
889
+ 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';
890
+ /**
891
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
892
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
893
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
894
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
895
+ * and would be compared as a literal string.
896
+ */
897
+ property: string;
898
+ /**
899
+ * String compared against the resolved property. Operators that take no value
900
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
901
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
902
+ */
903
+ value: string;
904
+ }
905
+ }
906
+ interface Step {
907
+ eventName: string;
908
+ name: string;
909
+ order: number;
910
+ filters?: unknown | null;
911
+ logic?: Step.Logic | null;
912
+ }
913
+ namespace Step {
914
+ interface Logic {
915
+ /**
916
+ * All child nodes must match. Each child is itself a logic node (leaf `condition`
917
+ * or combinator).
918
+ */
919
+ AND?: Array<unknown> | null;
920
+ condition?: Logic.Condition;
921
+ /**
922
+ * Negates a single child logic node.
923
+ */
924
+ NOT?: unknown;
925
+ /**
926
+ * Any child node must match. Each child is itself a logic node (leaf `condition`
927
+ * or combinator).
928
+ */
929
+ OR?: Array<unknown> | null;
930
+ }
931
+ namespace Logic {
932
+ interface Condition {
933
+ /**
934
+ * Comparison verb in PascalCase. Equality/text: `Is`, `IsNot`, `Contains`,
935
+ * `DoesNotContain`, `StartsWith`, `EndsWith`. Truthiness/nullability: `IsFalsy`,
936
+ * `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`, `IsTrue`,
937
+ * `IsFalse`. Numeric: `IsGreaterThan`, `IsGreaterThanOrEqual`, `IsLessThan`,
938
+ * `IsLessThanOrEqual`. Set membership: `IsIn`, `IsNotIn`, `IsFoundIn`,
939
+ * `IsNotFoundIn`. Date: `IsBefore`, `IsAfter`, `IsBetween`, `IsOnOrBefore`,
940
+ * `IsOnOrAfter`. Regex: `MatchesRegex`, `MatchesRegexIgnoreCase`,
941
+ * `DoesNotMatchRegex`, `DoesNotMatchRegexIgnoreCase`.
942
+ */
943
+ 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';
944
+ /**
945
+ * Bare dotted path into the event/visitor record. Examples: `$event.event`,
946
+ * `$event.event_properties.value`, `visitor.consent.marketing`. The leading `$` is
947
+ * optional and stripped before lookup. Do **not** use `{{...}}` here — that
948
+ * template syntax is for mapping values (`mappings[].map`), not logic conditions,
949
+ * and would be compared as a literal string.
950
+ */
951
+ property: string;
952
+ /**
953
+ * String compared against the resolved property. Operators that take no value
954
+ * (`IsFalsy`, `IsTruthy`, `IsNull`, `IsNotNull`, `IsUndefined`, `IsNotUndefined`,
955
+ * `IsTrue`, `IsFalse`) ignore this field — send `""`.
956
+ */
957
+ value: string;
958
+ }
959
+ }
960
+ }
961
+ }
156
962
  export interface FunnelResultsParams {
157
963
  /**
158
964
  * Inclusive lower bound of the analysis window, as a UTC calendar day in
@@ -206,6 +1012,6 @@ export interface FunnelResultsParams {
206
1012
  utmTerm?: string;
207
1013
  }
208
1014
  export declare namespace Funnels {
209
- export { type FunnelListResponse as FunnelListResponse, type FunnelRetrieveResponse as FunnelRetrieveResponse, type FunnelResultsResponse as FunnelResultsResponse, type FunnelResultsParams as FunnelResultsParams, };
1015
+ export { type FunnelListResponse as FunnelListResponse, type FunnelCreateResponse as FunnelCreateResponse, type FunnelRetrieveResponse as FunnelRetrieveResponse, type FunnelUpdateResponse as FunnelUpdateResponse, type FunnelDeleteResponse as FunnelDeleteResponse, type FunnelResultsResponse as FunnelResultsResponse, type FunnelCreateParams as FunnelCreateParams, type FunnelUpdateParams as FunnelUpdateParams, type FunnelResultsParams as FunnelResultsParams, };
210
1016
  }
211
1017
  //# sourceMappingURL=funnels.d.mts.map