samva 0.34.0 → 0.36.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 (129) hide show
  1. package/AGENTS.md +17 -0
  2. package/README.md +2 -1
  3. package/dist/client/sdk.gen.d.ts +325 -331
  4. package/dist/client/sdk.gen.js +406 -454
  5. package/dist/client/types.gen.d.ts +3465 -750
  6. package/dist/effect/agents.d.ts +222 -17
  7. package/dist/effect/agents.js +7 -1
  8. package/dist/effect/analytics.d.ts +21 -15
  9. package/dist/effect/api-keys.d.ts +30 -24
  10. package/dist/effect/campaigns.d.ts +695 -39
  11. package/dist/effect/categories.d.ts +3 -3
  12. package/dist/effect/contact-groups.d.ts +15 -15
  13. package/dist/effect/contacts.d.ts +56 -52
  14. package/dist/effect/conversations.d.ts +51 -45
  15. package/dist/effect/email.d.ts +82 -82
  16. package/dist/effect/errors.d.ts +1 -1
  17. package/dist/effect/errors.js +2 -2
  18. package/dist/effect/extension-installations.d.ts +64 -12
  19. package/dist/effect/extensions.d.ts +16 -16
  20. package/dist/effect/generated/agents.d.ts +2902 -150
  21. package/dist/effect/generated/agents.js +219 -31
  22. package/dist/effect/generated/analytics.d.ts +127 -136
  23. package/dist/effect/generated/analytics.js +72 -37
  24. package/dist/effect/generated/api-keys.d.ts +243 -47
  25. package/dist/effect/generated/api-keys.js +27 -12
  26. package/dist/effect/generated/attachments.d.ts +89 -1
  27. package/dist/effect/generated/attachments.js +10 -2
  28. package/dist/effect/generated/brands.d.ts +133 -1
  29. package/dist/effect/generated/brands.js +22 -10
  30. package/dist/effect/generated/campaigns.d.ts +1467 -143
  31. package/dist/effect/generated/campaigns.js +84 -20
  32. package/dist/effect/generated/contact-events.d.ts +26 -4
  33. package/dist/effect/generated/contact-events.js +5 -3
  34. package/dist/effect/generated/contact-groups.d.ts +233 -13
  35. package/dist/effect/generated/contact-groups.js +33 -17
  36. package/dist/effect/generated/contacts.d.ts +634 -96
  37. package/dist/effect/generated/contacts.js +82 -20
  38. package/dist/effect/generated/conversations.d.ts +501 -108
  39. package/dist/effect/generated/conversations.js +106 -22
  40. package/dist/effect/generated/custom-fields.d.ts +89 -1
  41. package/dist/effect/generated/custom-fields.js +11 -3
  42. package/dist/effect/generated/email.d.ts +1447 -83
  43. package/dist/effect/generated/email.js +167 -43
  44. package/dist/effect/generated/events.d.ts +51 -7
  45. package/dist/effect/generated/events.js +9 -5
  46. package/dist/effect/generated/extension-installations.d.ts +1052 -77
  47. package/dist/effect/generated/extension-installations.js +45 -31
  48. package/dist/effect/generated/extensions.d.ts +123 -13
  49. package/dist/effect/generated/extensions.js +20 -10
  50. package/dist/effect/generated/feedback.d.ts +23 -1
  51. package/dist/effect/generated/feedback.js +6 -4
  52. package/dist/effect/generated/index.d.ts +3 -1
  53. package/dist/effect/generated/journeys.d.ts +684 -16
  54. package/dist/effect/generated/journeys.js +37 -9
  55. package/dist/effect/generated/mailboxes.d.ts +6169 -1734
  56. package/dist/effect/generated/mailboxes.js +549 -344
  57. package/dist/effect/generated/media.d.ts +125 -15
  58. package/dist/effect/generated/media.js +15 -2
  59. package/dist/effect/generated/messages.d.ts +2036 -117
  60. package/dist/effect/generated/messages.js +286 -54
  61. package/dist/effect/generated/namespaces.d.ts +215 -55
  62. package/dist/effect/generated/namespaces.js +30 -12
  63. package/dist/effect/generated/newsletter-domains.d.ts +98 -12
  64. package/dist/effect/generated/newsletter-domains.js +20 -13
  65. package/dist/effect/generated/newsletter-issues.d.ts +354 -19
  66. package/dist/effect/generated/newsletter-issues.js +162 -98
  67. package/dist/effect/generated/newsletters.d.ts +123 -13
  68. package/dist/effect/generated/newsletters.js +19 -9
  69. package/dist/effect/generated/operations.d.ts +76 -10
  70. package/dist/effect/generated/operations.js +12 -6
  71. package/dist/effect/generated/organizations.d.ts +287 -7
  72. package/dist/effect/generated/organizations.js +33 -5
  73. package/dist/effect/generated/policies.d.ts +953 -0
  74. package/dist/effect/generated/policies.js +116 -0
  75. package/dist/effect/generated/scheduled-messages.d.ts +4418 -49
  76. package/dist/effect/generated/scheduled-messages.js +77 -13
  77. package/dist/effect/generated/shared.d.ts +3213 -521
  78. package/dist/effect/generated/shared.js +713 -128
  79. package/dist/effect/generated/subscriptions.d.ts +23 -1
  80. package/dist/effect/generated/subscriptions.js +6 -4
  81. package/dist/effect/generated/templates.d.ts +2081 -693
  82. package/dist/effect/generated/templates.js +482 -267
  83. package/dist/effect/generated/topic-forms.d.ts +111 -1
  84. package/dist/effect/generated/topic-forms.js +23 -13
  85. package/dist/effect/generated/topics.d.ts +353 -43
  86. package/dist/effect/generated/topics.js +67 -19
  87. package/dist/effect/generated/webhooks.d.ts +318 -57
  88. package/dist/effect/generated/webhooks.js +68 -17
  89. package/dist/effect/generated/whoami.d.ts +35 -5
  90. package/dist/effect/generated/whoami.js +4 -2
  91. package/dist/effect/generated-metadata.d.ts +56 -32
  92. package/dist/effect/generated-metadata.js +137 -105
  93. package/dist/effect/index.d.ts +1 -0
  94. package/dist/effect/index.js +3 -2
  95. package/dist/effect/internal/client.js +1 -1
  96. package/dist/effect/internal/email-sender.d.ts +1 -1
  97. package/dist/effect/internal/operation.js +5 -32
  98. package/dist/effect/internal/send.d.ts +1 -1
  99. package/dist/effect/journeys.d.ts +169 -83
  100. package/dist/effect/mailboxes.d.ts +978 -301
  101. package/dist/effect/mailboxes.js +1 -11
  102. package/dist/effect/media.d.ts +1 -1
  103. package/dist/effect/messages.d.ts +40 -40
  104. package/dist/effect/namespaces.d.ts +15 -15
  105. package/dist/effect/newsletter-domains.d.ts +5 -5
  106. package/dist/effect/newsletters.d.ts +1 -1
  107. package/dist/effect/operations.d.ts +11 -11
  108. package/dist/effect/organizations.d.ts +2 -2
  109. package/dist/effect/policies.d.ts +65 -0
  110. package/dist/effect/policies.js +16 -0
  111. package/dist/effect/scheduled-messages.d.ts +869 -8
  112. package/dist/effect/templates.d.ts +43 -45
  113. package/dist/effect/templates.js +5 -3
  114. package/dist/effect/topics.d.ts +23 -23
  115. package/dist/effect/webhooks.d.ts +29 -26
  116. package/dist/index.js +2 -2
  117. package/dist/mailbox/test.js +11 -4
  118. package/dist/mailbox/types.d.ts +39 -3
  119. package/dist/normalize.js +13 -1
  120. package/dist/package.js +1 -1
  121. package/dist/promises/client.d.ts +4 -2
  122. package/dist/promises/client.js +5 -3
  123. package/dist/promises/errors.gen.d.ts +38 -2
  124. package/dist/promises/errors.gen.js +394 -34
  125. package/dist/promises/index.js +2 -2
  126. package/dist/promises/types.gen.d.ts +1 -1
  127. package/dist/service-map.d.ts +39 -28
  128. package/dist/service-map.js +220 -782
  129. package/package.json +13 -8
@@ -6,39 +6,12 @@ import { generateIdempotencyKey, withRetry } from "../retry.js";
6
6
  import { Service } from "./client.js";
7
7
  import { Effect, Predicate } from "effect";
8
8
  // src/effect/internal/operation.ts
9
- const MODULE_NAMES = {
10
- agents: "Agents",
11
- analytics: "Analytics",
12
- apiKeys: "ApiKeys",
13
- attachments: "Attachments",
14
- brands: "Brands",
15
- campaigns: "Campaigns",
16
- contactGroups: "ContactGroups",
17
- contacts: "Contacts",
18
- conversations: "Conversations",
19
- customFields: "CustomFields",
20
- email: "Email",
21
- extensions: "Extensions",
22
- feedback: "Feedback",
23
- mailboxes: "Mailboxes",
24
- media: "Media",
25
- messages: "Messages",
26
- namespaces: "Namespaces",
27
- operations: "Operations",
28
- organizations: "Organizations",
29
- scheduledMessages: "ScheduledMessages",
30
- templates: "Templates",
31
- topics: "Topics",
32
- webhooks: "Webhooks",
33
- whoami: "Whoami"
34
- };
35
9
  const traceName = (operationName) => {
36
- for (const [prefix, moduleName] of Object.entries(MODULE_NAMES)) {
37
- if (!operationName.startsWith(prefix)) continue;
38
- const method = operationName.slice(prefix.length);
39
- return `${moduleName}.${method[0].toLowerCase()}${method.slice(1)}`;
40
- }
41
- return `Samva.${operationName}`;
10
+ const moduleName = SamvaOperations[operationName].group.split(" ").map((word) => word[0].toUpperCase() + word.slice(1).toLowerCase()).join("");
11
+ const prefix = moduleName[0].toLowerCase() + moduleName.slice(1);
12
+ if (!operationName.startsWith(prefix)) return `Samva.${operationName}`;
13
+ const method = operationName.slice(prefix.length);
14
+ return `${moduleName}.${method[0].toLowerCase()}${method.slice(1)}`;
42
15
  };
43
16
  const stripUndefined = (input) => {
44
17
  if (!Predicate.isObject(input)) return input;
@@ -4,7 +4,7 @@ import type { SendMessagePayload } from "../generated/shared";
4
4
  import { Service } from "./client";
5
5
  import { type OperationResult } from "./operation";
6
6
  type MessagePayload = typeof SendMessagePayload.Encoded;
7
- export type MessageRecipient = MessagePayload["to"][number];
7
+ export type MessageRecipient = EmailPayload["to"][number];
8
8
  type ContactObjectRecipient = {
9
9
  readonly id: string;
10
10
  };
@@ -1,12 +1,12 @@
1
1
  export declare const list: ((input?: {
2
- readonly status?: "active" | "archived" | "draft" | "paused" | null | undefined;
2
+ readonly status?: "active" | "archived" | "draft" | "paused" | undefined;
3
3
  readonly limit?: number | null | undefined;
4
- readonly cursor?: string | null | undefined;
4
+ readonly cursor?: string | undefined;
5
5
  } | undefined, options?: import("./internal/operation").OperationOptions) => import("./internal/operation").OperationResult<"journeysList">) & {
6
6
  readonly pages: (input?: {
7
- readonly status?: "active" | "archived" | "draft" | "paused" | null | undefined;
7
+ readonly status?: "active" | "archived" | "draft" | "paused" | undefined;
8
8
  readonly limit?: number | null | undefined;
9
- readonly cursor?: string | null | undefined;
9
+ readonly cursor?: string | undefined;
10
10
  } | undefined) => import("effect/Stream").Stream<{
11
11
  readonly items: readonly {
12
12
  readonly id: string & import("effect/Brand").Brand<"JourneyId">;
@@ -18,11 +18,11 @@ export declare const list: ((input?: {
18
18
  readonly updatedAt: string;
19
19
  }[];
20
20
  readonly nextCursor: string | null;
21
- }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
21
+ }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("./errors").MalformedRequestError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
22
22
  readonly items: (input?: {
23
- readonly status?: "active" | "archived" | "draft" | "paused" | null | undefined;
23
+ readonly status?: "active" | "archived" | "draft" | "paused" | undefined;
24
24
  readonly limit?: number | null | undefined;
25
- readonly cursor?: string | null | undefined;
25
+ readonly cursor?: string | undefined;
26
26
  } | undefined) => import("effect/Stream").Stream<{
27
27
  readonly id: string & import("effect/Brand").Brand<"JourneyId">;
28
28
  readonly name: string;
@@ -31,12 +31,15 @@ export declare const list: ((input?: {
31
31
  readonly publishedAt: string | null;
32
32
  readonly createdAt: string;
33
33
  readonly updatedAt: string;
34
- }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
34
+ }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("./errors").MalformedRequestError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
35
35
  };
36
36
  export declare const create: (input: {
37
37
  readonly name: string;
38
38
  readonly definition: {
39
39
  readonly trigger: {
40
+ readonly type: "event";
41
+ readonly eventName: string;
42
+ } | {
40
43
  readonly type: "contact.created";
41
44
  } | {
42
45
  readonly type: "contact.tag_added";
@@ -44,19 +47,10 @@ export declare const create: (input: {
44
47
  } | {
45
48
  readonly type: "contact.joined_group";
46
49
  readonly groupId: string;
47
- } | {
48
- readonly type: "event";
49
- readonly eventName: string;
50
50
  };
51
51
  readonly rootNodeId: string;
52
52
  readonly nodes: {
53
53
  readonly [x: string]: {
54
- readonly type: "exit";
55
- readonly config: {
56
- readonly [x: string]: undefined;
57
- };
58
- readonly next: readonly never[];
59
- } | {
60
54
  readonly type: "send_email";
61
55
  readonly config: {
62
56
  readonly template: string;
@@ -93,26 +87,10 @@ export declare const create: (input: {
93
87
  readonly nodeId: string;
94
88
  }[];
95
89
  } | {
96
- readonly type: "wait";
97
- readonly config: {
98
- readonly durationSeconds: number;
99
- };
100
- readonly next: readonly {
101
- readonly nodeId: string;
102
- }[];
103
- } | {
104
- readonly type: "update_tags";
105
- readonly config: {
106
- readonly add: readonly string[];
107
- readonly remove: readonly string[];
108
- };
109
- readonly next: readonly {
110
- readonly nodeId: string;
111
- }[];
112
- } | {
113
- readonly type: "webhook";
90
+ readonly type: "send_whatsapp";
114
91
  readonly config: {
115
- readonly data?: {
92
+ readonly template: string;
93
+ readonly templateData?: {
116
94
  readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
117
95
  readonly [x: string]: string | number | boolean | any | any | null | undefined;
118
96
  } | null)[] | {
@@ -139,6 +117,22 @@ export declare const create: (input: {
139
117
  readonly [x: string]: string | number | boolean | any | any | null | undefined;
140
118
  } | null | undefined;
141
119
  } | undefined;
120
+ readonly bindings?: {
121
+ readonly [x: string]: {
122
+ readonly contact: "company" | "displayName" | "email" | "externalId" | "firstName" | "id" | "jobTitle" | "lastName" | "name" | "phone";
123
+ } | {
124
+ readonly customField: string;
125
+ } | undefined;
126
+ } | undefined;
127
+ readonly businessAccountId?: string | undefined;
128
+ };
129
+ readonly next: readonly {
130
+ readonly nodeId: string;
131
+ }[];
132
+ } | {
133
+ readonly type: "wait";
134
+ readonly config: {
135
+ readonly durationSeconds: number;
142
136
  };
143
137
  readonly next: readonly {
144
138
  readonly nodeId: string;
@@ -166,10 +160,6 @@ export declare const create: (input: {
166
160
  readonly type: "tag";
167
161
  readonly tag: string;
168
162
  readonly present: boolean;
169
- } | {
170
- readonly type: "event";
171
- readonly eventName: string;
172
- readonly occurred: boolean;
173
163
  } | {
174
164
  readonly type: "property";
175
165
  readonly field: "displayName" | "externalId" | "name" | "profile.company" | "profile.firstName" | "profile.jobTitle" | "profile.lastName" | "profile.location.city" | "profile.location.country" | "profile.location.state" | "profile.location.timezone" | "profile.source" | "status";
@@ -200,9 +190,62 @@ export declare const create: (input: {
200
190
  } | {
201
191
  readonly operator: "exists" | "not_exists";
202
192
  };
193
+ } | {
194
+ readonly type: "event";
195
+ readonly eventName: string;
196
+ readonly occurred: boolean;
203
197
  })[];
204
198
  } | undefined;
205
199
  }[];
200
+ } | {
201
+ readonly type: "update_tags";
202
+ readonly config: {
203
+ readonly add: readonly string[];
204
+ readonly remove: readonly string[];
205
+ };
206
+ readonly next: readonly {
207
+ readonly nodeId: string;
208
+ }[];
209
+ } | {
210
+ readonly type: "webhook";
211
+ readonly config: {
212
+ readonly data?: {
213
+ readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
214
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
215
+ } | null)[] | {
216
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
217
+ } | null)[] | {
218
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
219
+ } | null)[] | {
220
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
221
+ } | null)[] | {
222
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
223
+ } | null)[] | {
224
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
225
+ } | null)[] | {
226
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
227
+ } | null)[] | {
228
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
229
+ } | null)[] | {
230
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
231
+ } | null)[] | {
232
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
233
+ } | null)[] | {
234
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
235
+ } | null)[] | {
236
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
237
+ } | null | undefined;
238
+ } | undefined;
239
+ };
240
+ readonly next: readonly {
241
+ readonly nodeId: string;
242
+ }[];
243
+ } | {
244
+ readonly type: "exit";
245
+ readonly config: {
246
+ readonly [x: string]: undefined;
247
+ };
248
+ readonly next: readonly never[];
206
249
  } | undefined;
207
250
  };
208
251
  readonly goal?: {
@@ -226,6 +269,9 @@ export declare const replaceDraft: (input: {
226
269
  readonly revision: string;
227
270
  readonly definition: {
228
271
  readonly trigger: {
272
+ readonly type: "event";
273
+ readonly eventName: string;
274
+ } | {
229
275
  readonly type: "contact.created";
230
276
  } | {
231
277
  readonly type: "contact.tag_added";
@@ -233,19 +279,10 @@ export declare const replaceDraft: (input: {
233
279
  } | {
234
280
  readonly type: "contact.joined_group";
235
281
  readonly groupId: string;
236
- } | {
237
- readonly type: "event";
238
- readonly eventName: string;
239
282
  };
240
283
  readonly rootNodeId: string;
241
284
  readonly nodes: {
242
285
  readonly [x: string]: {
243
- readonly type: "exit";
244
- readonly config: {
245
- readonly [x: string]: undefined;
246
- };
247
- readonly next: readonly never[];
248
- } | {
249
286
  readonly type: "send_email";
250
287
  readonly config: {
251
288
  readonly template: string;
@@ -282,26 +319,10 @@ export declare const replaceDraft: (input: {
282
319
  readonly nodeId: string;
283
320
  }[];
284
321
  } | {
285
- readonly type: "wait";
286
- readonly config: {
287
- readonly durationSeconds: number;
288
- };
289
- readonly next: readonly {
290
- readonly nodeId: string;
291
- }[];
292
- } | {
293
- readonly type: "update_tags";
294
- readonly config: {
295
- readonly add: readonly string[];
296
- readonly remove: readonly string[];
297
- };
298
- readonly next: readonly {
299
- readonly nodeId: string;
300
- }[];
301
- } | {
302
- readonly type: "webhook";
322
+ readonly type: "send_whatsapp";
303
323
  readonly config: {
304
- readonly data?: {
324
+ readonly template: string;
325
+ readonly templateData?: {
305
326
  readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
306
327
  readonly [x: string]: string | number | boolean | any | any | null | undefined;
307
328
  } | null)[] | {
@@ -328,6 +349,22 @@ export declare const replaceDraft: (input: {
328
349
  readonly [x: string]: string | number | boolean | any | any | null | undefined;
329
350
  } | null | undefined;
330
351
  } | undefined;
352
+ readonly bindings?: {
353
+ readonly [x: string]: {
354
+ readonly contact: "company" | "displayName" | "email" | "externalId" | "firstName" | "id" | "jobTitle" | "lastName" | "name" | "phone";
355
+ } | {
356
+ readonly customField: string;
357
+ } | undefined;
358
+ } | undefined;
359
+ readonly businessAccountId?: string | undefined;
360
+ };
361
+ readonly next: readonly {
362
+ readonly nodeId: string;
363
+ }[];
364
+ } | {
365
+ readonly type: "wait";
366
+ readonly config: {
367
+ readonly durationSeconds: number;
331
368
  };
332
369
  readonly next: readonly {
333
370
  readonly nodeId: string;
@@ -355,10 +392,6 @@ export declare const replaceDraft: (input: {
355
392
  readonly type: "tag";
356
393
  readonly tag: string;
357
394
  readonly present: boolean;
358
- } | {
359
- readonly type: "event";
360
- readonly eventName: string;
361
- readonly occurred: boolean;
362
395
  } | {
363
396
  readonly type: "property";
364
397
  readonly field: "displayName" | "externalId" | "name" | "profile.company" | "profile.firstName" | "profile.jobTitle" | "profile.lastName" | "profile.location.city" | "profile.location.country" | "profile.location.state" | "profile.location.timezone" | "profile.source" | "status";
@@ -389,9 +422,62 @@ export declare const replaceDraft: (input: {
389
422
  } | {
390
423
  readonly operator: "exists" | "not_exists";
391
424
  };
425
+ } | {
426
+ readonly type: "event";
427
+ readonly eventName: string;
428
+ readonly occurred: boolean;
392
429
  })[];
393
430
  } | undefined;
394
431
  }[];
432
+ } | {
433
+ readonly type: "update_tags";
434
+ readonly config: {
435
+ readonly add: readonly string[];
436
+ readonly remove: readonly string[];
437
+ };
438
+ readonly next: readonly {
439
+ readonly nodeId: string;
440
+ }[];
441
+ } | {
442
+ readonly type: "webhook";
443
+ readonly config: {
444
+ readonly data?: {
445
+ readonly [x: string]: string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | readonly (string | number | boolean | any | {
446
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
447
+ } | null)[] | {
448
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
449
+ } | null)[] | {
450
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
451
+ } | null)[] | {
452
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
453
+ } | null)[] | {
454
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
455
+ } | null)[] | {
456
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
457
+ } | null)[] | {
458
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
459
+ } | null)[] | {
460
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
461
+ } | null)[] | {
462
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
463
+ } | null)[] | {
464
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
465
+ } | null)[] | {
466
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
467
+ } | null)[] | {
468
+ readonly [x: string]: string | number | boolean | any | any | null | undefined;
469
+ } | null | undefined;
470
+ } | undefined;
471
+ };
472
+ readonly next: readonly {
473
+ readonly nodeId: string;
474
+ }[];
475
+ } | {
476
+ readonly type: "exit";
477
+ readonly config: {
478
+ readonly [x: string]: undefined;
479
+ };
480
+ readonly next: readonly never[];
395
481
  } | undefined;
396
482
  };
397
483
  readonly goal?: {
@@ -423,17 +509,17 @@ export declare const stats: (input: {
423
509
  }, options?: import("./internal/operation").OperationOptions) => import("./internal/operation").OperationResult<"journeysStats">;
424
510
  export declare const listRuns: ((input: {
425
511
  readonly id: string;
426
- readonly status?: "active" | "exited" | "failed" | "paused" | null | undefined;
427
- readonly contactId?: string | null | undefined;
512
+ readonly status?: "active" | "exited" | "failed" | "paused" | undefined;
513
+ readonly contactId?: string | undefined;
428
514
  readonly limit?: number | null | undefined;
429
- readonly cursor?: string | null | undefined;
515
+ readonly cursor?: string | undefined;
430
516
  }, options?: import("./internal/operation").OperationOptions) => import("./internal/operation").OperationResult<"journeysListRuns">) & {
431
517
  readonly pages: (input: {
432
518
  readonly id: string;
433
- readonly status?: "active" | "exited" | "failed" | "paused" | null | undefined;
434
- readonly contactId?: string | null | undefined;
519
+ readonly status?: "active" | "exited" | "failed" | "paused" | undefined;
520
+ readonly contactId?: string | undefined;
435
521
  readonly limit?: number | null | undefined;
436
- readonly cursor?: string | null | undefined;
522
+ readonly cursor?: string | undefined;
437
523
  }) => import("effect/Stream").Stream<{
438
524
  readonly items: readonly {
439
525
  readonly id: string & import("effect/Brand").Brand<"JourneyRunId">;
@@ -457,13 +543,13 @@ export declare const listRuns: ((input: {
457
543
  readonly endedAt: string | null;
458
544
  }[];
459
545
  readonly nextCursor: string | null;
460
- }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("./errors").ResourceNotFoundError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
546
+ }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("./errors").MalformedRequestError | import("./errors").ResourceNotFoundError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
461
547
  readonly items: (input: {
462
548
  readonly id: string;
463
- readonly status?: "active" | "exited" | "failed" | "paused" | null | undefined;
464
- readonly contactId?: string | null | undefined;
549
+ readonly status?: "active" | "exited" | "failed" | "paused" | undefined;
550
+ readonly contactId?: string | undefined;
465
551
  readonly limit?: number | null | undefined;
466
- readonly cursor?: string | null | undefined;
552
+ readonly cursor?: string | undefined;
467
553
  }) => import("effect/Stream").Stream<{
468
554
  readonly id: string & import("effect/Brand").Brand<"JourneyRunId">;
469
555
  readonly journeyId: string & import("effect/Brand").Brand<"JourneyId">;
@@ -484,7 +570,7 @@ export declare const listRuns: ((input: {
484
570
  };
485
571
  readonly enteredAt: string;
486
572
  readonly endedAt: string | null;
487
- }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("./errors").ResourceNotFoundError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
573
+ }, import("./errors").ForbiddenError | import("./errors").GatewayTimeoutError | import("effect/http/HttpClientError").HttpClientError | import("./errors").InternalError | import("./errors").MalformedRequestError | import("./errors").ResourceNotFoundError | import("effect/Schema").SchemaError | import("./errors").UnauthorizedError | import("./errors").ValidationError, import("./client").Service>;
488
574
  };
489
575
  export declare const getRun: (input: {
490
576
  readonly id: string;