@automate.ax/integration-contracts 0.99.5 → 0.101.1

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.
@@ -0,0 +1,451 @@
1
+ import * as z from "zod";
2
+ export declare const AUTOMATE_AUTOMATION_TRIGGER_CONFIG_SCHEMA: z.ZodObject<{
3
+ automationId: z.ZodString;
4
+ }, z.core.$strip>;
5
+ export declare const AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA: z.ZodObject<{
6
+ projectId: z.ZodString;
7
+ }, z.core.$strip>;
8
+ export declare const AUTOMATE_AUTOMATION_STATE_EVENT_SCHEMA: z.ZodObject<{
9
+ automation: z.ZodObject<{
10
+ description: z.ZodString;
11
+ id: z.ZodString;
12
+ identityKey: z.ZodString;
13
+ }, z.core.$strip>;
14
+ enabled: z.ZodBoolean;
15
+ organization: z.ZodObject<{
16
+ id: z.ZodString;
17
+ name: z.ZodString;
18
+ }, z.core.$strip>;
19
+ previousEnabled: z.ZodBoolean;
20
+ project: z.ZodObject<{
21
+ id: z.ZodString;
22
+ name: z.ZodString;
23
+ }, z.core.$strip>;
24
+ transitionedAt: z.ZodDate;
25
+ }, z.core.$strip>;
26
+ export declare const AUTOMATE_AUTOMATION_ENABLED_EVENT_SCHEMA: z.ZodObject<{
27
+ automation: z.ZodObject<{
28
+ description: z.ZodString;
29
+ id: z.ZodString;
30
+ identityKey: z.ZodString;
31
+ }, z.core.$strip>;
32
+ organization: z.ZodObject<{
33
+ id: z.ZodString;
34
+ name: z.ZodString;
35
+ }, z.core.$strip>;
36
+ project: z.ZodObject<{
37
+ id: z.ZodString;
38
+ name: z.ZodString;
39
+ }, z.core.$strip>;
40
+ transitionedAt: z.ZodDate;
41
+ enabled: z.ZodLiteral<true>;
42
+ previousEnabled: z.ZodLiteral<false>;
43
+ }, z.core.$strip>;
44
+ export declare const AUTOMATE_AUTOMATION_DISABLED_EVENT_SCHEMA: z.ZodObject<{
45
+ automation: z.ZodObject<{
46
+ description: z.ZodString;
47
+ id: z.ZodString;
48
+ identityKey: z.ZodString;
49
+ }, z.core.$strip>;
50
+ organization: z.ZodObject<{
51
+ id: z.ZodString;
52
+ name: z.ZodString;
53
+ }, z.core.$strip>;
54
+ project: z.ZodObject<{
55
+ id: z.ZodString;
56
+ name: z.ZodString;
57
+ }, z.core.$strip>;
58
+ transitionedAt: z.ZodDate;
59
+ enabled: z.ZodLiteral<false>;
60
+ previousEnabled: z.ZodLiteral<true>;
61
+ }, z.core.$strip>;
62
+ export declare const AUTOMATE_DEPLOYMENT_EVENT_SCHEMA: z.ZodObject<{
63
+ deployment: z.ZodObject<{
64
+ completedAt: z.ZodNullable<z.ZodDate>;
65
+ createdAt: z.ZodDate;
66
+ id: z.ZodString;
67
+ }, z.core.$strip>;
68
+ failure: z.ZodNullable<z.ZodObject<{
69
+ message: z.ZodString;
70
+ }, z.core.$strip>>;
71
+ organization: z.ZodObject<{
72
+ id: z.ZodString;
73
+ name: z.ZodString;
74
+ }, z.core.$strip>;
75
+ previousStatus: z.ZodNullable<z.ZodEnum<{
76
+ planning: "planning";
77
+ awaiting_authorization: "awaiting_authorization";
78
+ configuring: "configuring";
79
+ publishing: "publishing";
80
+ succeeded: "succeeded";
81
+ failed: "failed";
82
+ cancelled: "cancelled";
83
+ }>>;
84
+ project: z.ZodObject<{
85
+ id: z.ZodString;
86
+ name: z.ZodString;
87
+ }, z.core.$strip>;
88
+ status: z.ZodEnum<{
89
+ planning: "planning";
90
+ awaiting_authorization: "awaiting_authorization";
91
+ configuring: "configuring";
92
+ publishing: "publishing";
93
+ succeeded: "succeeded";
94
+ failed: "failed";
95
+ cancelled: "cancelled";
96
+ }>;
97
+ transitionedAt: z.ZodDate;
98
+ }, z.core.$strip>;
99
+ export declare const AUTOMATE_DEPLOYMENT_AWAITING_AUTHORIZATION_EVENT_SCHEMA: z.ZodObject<{
100
+ deployment: z.ZodObject<{
101
+ completedAt: z.ZodNullable<z.ZodDate>;
102
+ createdAt: z.ZodDate;
103
+ id: z.ZodString;
104
+ }, z.core.$strip>;
105
+ organization: z.ZodObject<{
106
+ id: z.ZodString;
107
+ name: z.ZodString;
108
+ }, z.core.$strip>;
109
+ previousStatus: z.ZodNullable<z.ZodEnum<{
110
+ planning: "planning";
111
+ awaiting_authorization: "awaiting_authorization";
112
+ configuring: "configuring";
113
+ publishing: "publishing";
114
+ succeeded: "succeeded";
115
+ failed: "failed";
116
+ cancelled: "cancelled";
117
+ }>>;
118
+ project: z.ZodObject<{
119
+ id: z.ZodString;
120
+ name: z.ZodString;
121
+ }, z.core.$strip>;
122
+ transitionedAt: z.ZodDate;
123
+ failure: z.ZodNull;
124
+ status: z.ZodLiteral<"awaiting_authorization">;
125
+ }, z.core.$strip>;
126
+ export declare const AUTOMATE_DEPLOYMENT_CANCELLED_EVENT_SCHEMA: z.ZodObject<{
127
+ organization: z.ZodObject<{
128
+ id: z.ZodString;
129
+ name: z.ZodString;
130
+ }, z.core.$strip>;
131
+ previousStatus: z.ZodNullable<z.ZodEnum<{
132
+ planning: "planning";
133
+ awaiting_authorization: "awaiting_authorization";
134
+ configuring: "configuring";
135
+ publishing: "publishing";
136
+ succeeded: "succeeded";
137
+ failed: "failed";
138
+ cancelled: "cancelled";
139
+ }>>;
140
+ project: z.ZodObject<{
141
+ id: z.ZodString;
142
+ name: z.ZodString;
143
+ }, z.core.$strip>;
144
+ transitionedAt: z.ZodDate;
145
+ deployment: z.ZodObject<{
146
+ createdAt: z.ZodDate;
147
+ id: z.ZodString;
148
+ completedAt: z.ZodDate;
149
+ }, z.core.$strip>;
150
+ failure: z.ZodNull;
151
+ status: z.ZodLiteral<"cancelled">;
152
+ }, z.core.$strip>;
153
+ export declare const AUTOMATE_DEPLOYMENT_FAILED_EVENT_SCHEMA: z.ZodObject<{
154
+ organization: z.ZodObject<{
155
+ id: z.ZodString;
156
+ name: z.ZodString;
157
+ }, z.core.$strip>;
158
+ previousStatus: z.ZodNullable<z.ZodEnum<{
159
+ planning: "planning";
160
+ awaiting_authorization: "awaiting_authorization";
161
+ configuring: "configuring";
162
+ publishing: "publishing";
163
+ succeeded: "succeeded";
164
+ failed: "failed";
165
+ cancelled: "cancelled";
166
+ }>>;
167
+ project: z.ZodObject<{
168
+ id: z.ZodString;
169
+ name: z.ZodString;
170
+ }, z.core.$strip>;
171
+ transitionedAt: z.ZodDate;
172
+ deployment: z.ZodObject<{
173
+ createdAt: z.ZodDate;
174
+ id: z.ZodString;
175
+ completedAt: z.ZodDate;
176
+ }, z.core.$strip>;
177
+ failure: z.ZodObject<{
178
+ message: z.ZodString;
179
+ }, z.core.$strip>;
180
+ status: z.ZodLiteral<"failed">;
181
+ }, z.core.$strip>;
182
+ export declare const AUTOMATE_DEPLOYMENT_SUCCEEDED_EVENT_SCHEMA: z.ZodObject<{
183
+ organization: z.ZodObject<{
184
+ id: z.ZodString;
185
+ name: z.ZodString;
186
+ }, z.core.$strip>;
187
+ previousStatus: z.ZodNullable<z.ZodEnum<{
188
+ planning: "planning";
189
+ awaiting_authorization: "awaiting_authorization";
190
+ configuring: "configuring";
191
+ publishing: "publishing";
192
+ succeeded: "succeeded";
193
+ failed: "failed";
194
+ cancelled: "cancelled";
195
+ }>>;
196
+ project: z.ZodObject<{
197
+ id: z.ZodString;
198
+ name: z.ZodString;
199
+ }, z.core.$strip>;
200
+ transitionedAt: z.ZodDate;
201
+ deployment: z.ZodObject<{
202
+ createdAt: z.ZodDate;
203
+ id: z.ZodString;
204
+ completedAt: z.ZodDate;
205
+ }, z.core.$strip>;
206
+ failure: z.ZodNull;
207
+ status: z.ZodLiteral<"succeeded">;
208
+ }, z.core.$strip>;
209
+ export declare const automateTriggerContracts: {
210
+ readonly "automate.automation.disabled": {
211
+ readonly configSchema: z.ZodObject<{
212
+ automationId: z.ZodString;
213
+ }, z.core.$strip>;
214
+ readonly eventSchema: z.ZodObject<{
215
+ automation: z.ZodObject<{
216
+ description: z.ZodString;
217
+ id: z.ZodString;
218
+ identityKey: z.ZodString;
219
+ }, z.core.$strip>;
220
+ organization: z.ZodObject<{
221
+ id: z.ZodString;
222
+ name: z.ZodString;
223
+ }, z.core.$strip>;
224
+ project: z.ZodObject<{
225
+ id: z.ZodString;
226
+ name: z.ZodString;
227
+ }, z.core.$strip>;
228
+ transitionedAt: z.ZodDate;
229
+ enabled: z.ZodLiteral<false>;
230
+ previousEnabled: z.ZodLiteral<true>;
231
+ }, z.core.$strip>;
232
+ };
233
+ readonly "automate.automation.enabled": {
234
+ readonly configSchema: z.ZodObject<{
235
+ automationId: z.ZodString;
236
+ }, z.core.$strip>;
237
+ readonly eventSchema: z.ZodObject<{
238
+ automation: z.ZodObject<{
239
+ description: z.ZodString;
240
+ id: z.ZodString;
241
+ identityKey: z.ZodString;
242
+ }, z.core.$strip>;
243
+ organization: z.ZodObject<{
244
+ id: z.ZodString;
245
+ name: z.ZodString;
246
+ }, z.core.$strip>;
247
+ project: z.ZodObject<{
248
+ id: z.ZodString;
249
+ name: z.ZodString;
250
+ }, z.core.$strip>;
251
+ transitionedAt: z.ZodDate;
252
+ enabled: z.ZodLiteral<true>;
253
+ previousEnabled: z.ZodLiteral<false>;
254
+ }, z.core.$strip>;
255
+ };
256
+ readonly "automate.automation.stateChanged": {
257
+ readonly configSchema: z.ZodObject<{
258
+ automationId: z.ZodString;
259
+ }, z.core.$strip>;
260
+ readonly eventSchema: z.ZodObject<{
261
+ automation: z.ZodObject<{
262
+ description: z.ZodString;
263
+ id: z.ZodString;
264
+ identityKey: z.ZodString;
265
+ }, z.core.$strip>;
266
+ enabled: z.ZodBoolean;
267
+ organization: z.ZodObject<{
268
+ id: z.ZodString;
269
+ name: z.ZodString;
270
+ }, z.core.$strip>;
271
+ previousEnabled: z.ZodBoolean;
272
+ project: z.ZodObject<{
273
+ id: z.ZodString;
274
+ name: z.ZodString;
275
+ }, z.core.$strip>;
276
+ transitionedAt: z.ZodDate;
277
+ }, z.core.$strip>;
278
+ };
279
+ readonly "automate.deployment.awaitingAuthorization": {
280
+ readonly configSchema: z.ZodObject<{
281
+ projectId: z.ZodString;
282
+ }, z.core.$strip>;
283
+ readonly eventSchema: z.ZodObject<{
284
+ deployment: z.ZodObject<{
285
+ completedAt: z.ZodNullable<z.ZodDate>;
286
+ createdAt: z.ZodDate;
287
+ id: z.ZodString;
288
+ }, z.core.$strip>;
289
+ organization: z.ZodObject<{
290
+ id: z.ZodString;
291
+ name: z.ZodString;
292
+ }, z.core.$strip>;
293
+ previousStatus: z.ZodNullable<z.ZodEnum<{
294
+ planning: "planning";
295
+ awaiting_authorization: "awaiting_authorization";
296
+ configuring: "configuring";
297
+ publishing: "publishing";
298
+ succeeded: "succeeded";
299
+ failed: "failed";
300
+ cancelled: "cancelled";
301
+ }>>;
302
+ project: z.ZodObject<{
303
+ id: z.ZodString;
304
+ name: z.ZodString;
305
+ }, z.core.$strip>;
306
+ transitionedAt: z.ZodDate;
307
+ failure: z.ZodNull;
308
+ status: z.ZodLiteral<"awaiting_authorization">;
309
+ }, z.core.$strip>;
310
+ };
311
+ readonly "automate.deployment.cancelled": {
312
+ readonly configSchema: z.ZodObject<{
313
+ projectId: z.ZodString;
314
+ }, z.core.$strip>;
315
+ readonly eventSchema: z.ZodObject<{
316
+ organization: z.ZodObject<{
317
+ id: z.ZodString;
318
+ name: z.ZodString;
319
+ }, z.core.$strip>;
320
+ previousStatus: z.ZodNullable<z.ZodEnum<{
321
+ planning: "planning";
322
+ awaiting_authorization: "awaiting_authorization";
323
+ configuring: "configuring";
324
+ publishing: "publishing";
325
+ succeeded: "succeeded";
326
+ failed: "failed";
327
+ cancelled: "cancelled";
328
+ }>>;
329
+ project: z.ZodObject<{
330
+ id: z.ZodString;
331
+ name: z.ZodString;
332
+ }, z.core.$strip>;
333
+ transitionedAt: z.ZodDate;
334
+ deployment: z.ZodObject<{
335
+ createdAt: z.ZodDate;
336
+ id: z.ZodString;
337
+ completedAt: z.ZodDate;
338
+ }, z.core.$strip>;
339
+ failure: z.ZodNull;
340
+ status: z.ZodLiteral<"cancelled">;
341
+ }, z.core.$strip>;
342
+ };
343
+ readonly "automate.deployment.event": {
344
+ readonly configSchema: z.ZodObject<{
345
+ projectId: z.ZodString;
346
+ }, z.core.$strip>;
347
+ readonly eventSchema: z.ZodObject<{
348
+ deployment: z.ZodObject<{
349
+ completedAt: z.ZodNullable<z.ZodDate>;
350
+ createdAt: z.ZodDate;
351
+ id: z.ZodString;
352
+ }, z.core.$strip>;
353
+ failure: z.ZodNullable<z.ZodObject<{
354
+ message: z.ZodString;
355
+ }, z.core.$strip>>;
356
+ organization: z.ZodObject<{
357
+ id: z.ZodString;
358
+ name: z.ZodString;
359
+ }, z.core.$strip>;
360
+ previousStatus: z.ZodNullable<z.ZodEnum<{
361
+ planning: "planning";
362
+ awaiting_authorization: "awaiting_authorization";
363
+ configuring: "configuring";
364
+ publishing: "publishing";
365
+ succeeded: "succeeded";
366
+ failed: "failed";
367
+ cancelled: "cancelled";
368
+ }>>;
369
+ project: z.ZodObject<{
370
+ id: z.ZodString;
371
+ name: z.ZodString;
372
+ }, z.core.$strip>;
373
+ status: z.ZodEnum<{
374
+ planning: "planning";
375
+ awaiting_authorization: "awaiting_authorization";
376
+ configuring: "configuring";
377
+ publishing: "publishing";
378
+ succeeded: "succeeded";
379
+ failed: "failed";
380
+ cancelled: "cancelled";
381
+ }>;
382
+ transitionedAt: z.ZodDate;
383
+ }, z.core.$strip>;
384
+ };
385
+ readonly "automate.deployment.failed": {
386
+ readonly configSchema: z.ZodObject<{
387
+ projectId: z.ZodString;
388
+ }, z.core.$strip>;
389
+ readonly eventSchema: z.ZodObject<{
390
+ organization: z.ZodObject<{
391
+ id: z.ZodString;
392
+ name: z.ZodString;
393
+ }, z.core.$strip>;
394
+ previousStatus: z.ZodNullable<z.ZodEnum<{
395
+ planning: "planning";
396
+ awaiting_authorization: "awaiting_authorization";
397
+ configuring: "configuring";
398
+ publishing: "publishing";
399
+ succeeded: "succeeded";
400
+ failed: "failed";
401
+ cancelled: "cancelled";
402
+ }>>;
403
+ project: z.ZodObject<{
404
+ id: z.ZodString;
405
+ name: z.ZodString;
406
+ }, z.core.$strip>;
407
+ transitionedAt: z.ZodDate;
408
+ deployment: z.ZodObject<{
409
+ createdAt: z.ZodDate;
410
+ id: z.ZodString;
411
+ completedAt: z.ZodDate;
412
+ }, z.core.$strip>;
413
+ failure: z.ZodObject<{
414
+ message: z.ZodString;
415
+ }, z.core.$strip>;
416
+ status: z.ZodLiteral<"failed">;
417
+ }, z.core.$strip>;
418
+ };
419
+ readonly "automate.deployment.succeeded": {
420
+ readonly configSchema: z.ZodObject<{
421
+ projectId: z.ZodString;
422
+ }, z.core.$strip>;
423
+ readonly eventSchema: z.ZodObject<{
424
+ organization: z.ZodObject<{
425
+ id: z.ZodString;
426
+ name: z.ZodString;
427
+ }, z.core.$strip>;
428
+ previousStatus: z.ZodNullable<z.ZodEnum<{
429
+ planning: "planning";
430
+ awaiting_authorization: "awaiting_authorization";
431
+ configuring: "configuring";
432
+ publishing: "publishing";
433
+ succeeded: "succeeded";
434
+ failed: "failed";
435
+ cancelled: "cancelled";
436
+ }>>;
437
+ project: z.ZodObject<{
438
+ id: z.ZodString;
439
+ name: z.ZodString;
440
+ }, z.core.$strip>;
441
+ transitionedAt: z.ZodDate;
442
+ deployment: z.ZodObject<{
443
+ createdAt: z.ZodDate;
444
+ id: z.ZodString;
445
+ completedAt: z.ZodDate;
446
+ }, z.core.$strip>;
447
+ failure: z.ZodNull;
448
+ status: z.ZodLiteral<"succeeded">;
449
+ }, z.core.$strip>;
450
+ };
451
+ };
@@ -0,0 +1,108 @@
1
+ import * as z from "zod";
2
+ const AUTOMATE_DEPLOYMENT_STATUS_SCHEMA = z.enum([
3
+ "planning",
4
+ "awaiting_authorization",
5
+ "configuring",
6
+ "publishing",
7
+ "succeeded",
8
+ "failed",
9
+ "cancelled",
10
+ ]);
11
+ const RESOURCE_REFERENCE_SCHEMA = z.object({
12
+ id: z.string().min(1),
13
+ name: z.string().min(1),
14
+ });
15
+ export const AUTOMATE_AUTOMATION_TRIGGER_CONFIG_SCHEMA = z.object({
16
+ automationId: z.string().min(1),
17
+ });
18
+ export const AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA = z.object({
19
+ projectId: z.string().min(1),
20
+ });
21
+ export const AUTOMATE_AUTOMATION_STATE_EVENT_SCHEMA = z.object({
22
+ automation: z.object({
23
+ description: z.string(),
24
+ id: z.string().min(1),
25
+ identityKey: z.string().min(1),
26
+ }),
27
+ enabled: z.boolean(),
28
+ organization: RESOURCE_REFERENCE_SCHEMA,
29
+ previousEnabled: z.boolean(),
30
+ project: RESOURCE_REFERENCE_SCHEMA,
31
+ transitionedAt: z.date(),
32
+ });
33
+ export const AUTOMATE_AUTOMATION_ENABLED_EVENT_SCHEMA = AUTOMATE_AUTOMATION_STATE_EVENT_SCHEMA.extend({
34
+ enabled: z.literal(true),
35
+ previousEnabled: z.literal(false),
36
+ });
37
+ export const AUTOMATE_AUTOMATION_DISABLED_EVENT_SCHEMA = AUTOMATE_AUTOMATION_STATE_EVENT_SCHEMA.extend({
38
+ enabled: z.literal(false),
39
+ previousEnabled: z.literal(true),
40
+ });
41
+ export const AUTOMATE_DEPLOYMENT_EVENT_SCHEMA = z.object({
42
+ deployment: z.object({
43
+ completedAt: z.date().nullable(),
44
+ createdAt: z.date(),
45
+ id: z.string().min(1),
46
+ }),
47
+ failure: z.object({ message: z.string() }).nullable(),
48
+ organization: RESOURCE_REFERENCE_SCHEMA,
49
+ previousStatus: AUTOMATE_DEPLOYMENT_STATUS_SCHEMA.nullable(),
50
+ project: RESOURCE_REFERENCE_SCHEMA,
51
+ status: AUTOMATE_DEPLOYMENT_STATUS_SCHEMA,
52
+ transitionedAt: z.date(),
53
+ });
54
+ const AUTOMATE_TERMINAL_DEPLOYMENT_EVENT_SCHEMA = AUTOMATE_DEPLOYMENT_EVENT_SCHEMA.extend({
55
+ deployment: AUTOMATE_DEPLOYMENT_EVENT_SCHEMA.shape.deployment.extend({
56
+ completedAt: z.date(),
57
+ }),
58
+ });
59
+ export const AUTOMATE_DEPLOYMENT_AWAITING_AUTHORIZATION_EVENT_SCHEMA = AUTOMATE_DEPLOYMENT_EVENT_SCHEMA.extend({
60
+ failure: z.null(),
61
+ status: z.literal("awaiting_authorization"),
62
+ });
63
+ export const AUTOMATE_DEPLOYMENT_CANCELLED_EVENT_SCHEMA = AUTOMATE_TERMINAL_DEPLOYMENT_EVENT_SCHEMA.extend({
64
+ failure: z.null(),
65
+ status: z.literal("cancelled"),
66
+ });
67
+ export const AUTOMATE_DEPLOYMENT_FAILED_EVENT_SCHEMA = AUTOMATE_TERMINAL_DEPLOYMENT_EVENT_SCHEMA.extend({
68
+ failure: z.object({ message: z.string() }),
69
+ status: z.literal("failed"),
70
+ });
71
+ export const AUTOMATE_DEPLOYMENT_SUCCEEDED_EVENT_SCHEMA = AUTOMATE_TERMINAL_DEPLOYMENT_EVENT_SCHEMA.extend({
72
+ failure: z.null(),
73
+ status: z.literal("succeeded"),
74
+ });
75
+ export const automateTriggerContracts = {
76
+ "automate.automation.disabled": {
77
+ configSchema: AUTOMATE_AUTOMATION_TRIGGER_CONFIG_SCHEMA,
78
+ eventSchema: AUTOMATE_AUTOMATION_DISABLED_EVENT_SCHEMA,
79
+ },
80
+ "automate.automation.enabled": {
81
+ configSchema: AUTOMATE_AUTOMATION_TRIGGER_CONFIG_SCHEMA,
82
+ eventSchema: AUTOMATE_AUTOMATION_ENABLED_EVENT_SCHEMA,
83
+ },
84
+ "automate.automation.stateChanged": {
85
+ configSchema: AUTOMATE_AUTOMATION_TRIGGER_CONFIG_SCHEMA,
86
+ eventSchema: AUTOMATE_AUTOMATION_STATE_EVENT_SCHEMA,
87
+ },
88
+ "automate.deployment.awaitingAuthorization": {
89
+ configSchema: AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA,
90
+ eventSchema: AUTOMATE_DEPLOYMENT_AWAITING_AUTHORIZATION_EVENT_SCHEMA,
91
+ },
92
+ "automate.deployment.cancelled": {
93
+ configSchema: AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA,
94
+ eventSchema: AUTOMATE_DEPLOYMENT_CANCELLED_EVENT_SCHEMA,
95
+ },
96
+ "automate.deployment.event": {
97
+ configSchema: AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA,
98
+ eventSchema: AUTOMATE_DEPLOYMENT_EVENT_SCHEMA,
99
+ },
100
+ "automate.deployment.failed": {
101
+ configSchema: AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA,
102
+ eventSchema: AUTOMATE_DEPLOYMENT_FAILED_EVENT_SCHEMA,
103
+ },
104
+ "automate.deployment.succeeded": {
105
+ configSchema: AUTOMATE_DEPLOYMENT_TRIGGER_CONFIG_SCHEMA,
106
+ eventSchema: AUTOMATE_DEPLOYMENT_SUCCEEDED_EVENT_SCHEMA,
107
+ },
108
+ };
@@ -112,11 +112,11 @@ export declare const closeTriggerContracts: {
112
112
  External: "External";
113
113
  }>>;
114
114
  status: z.ZodOptional<z.ZodEnum<{
115
+ failed: "failed";
115
116
  completed: "completed";
116
117
  created: "created";
117
118
  busy: "busy";
118
119
  cancel: "cancel";
119
- failed: "failed";
120
120
  "in-progress": "in-progress";
121
121
  "no-answer": "no-answer";
122
122
  timeout: "timeout";
@@ -185,11 +185,11 @@ export declare const closeTriggerContracts: {
185
185
  External: "External";
186
186
  }>>;
187
187
  status: z.ZodOptional<z.ZodEnum<{
188
+ failed: "failed";
188
189
  completed: "completed";
189
190
  created: "created";
190
191
  busy: "busy";
191
192
  cancel: "cancel";
192
- failed: "failed";
193
193
  "in-progress": "in-progress";
194
194
  "no-answer": "no-answer";
195
195
  timeout: "timeout";
@@ -283,7 +283,6 @@ export declare const closeTriggerContracts: {
283
283
  userId: z.ZodNullable<z.ZodString>;
284
284
  action: z.ZodLiteral<"updated">;
285
285
  data: z.ZodObject<{
286
- body: z.ZodOptional<z.ZodString>;
287
286
  createdAt: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodString]>, z.ZodTransform<Date, string | Date>>>;
288
287
  createdBy: z.ZodOptional<z.ZodString>;
289
288
  id: z.ZodOptional<z.ZodString>;
@@ -295,6 +294,7 @@ export declare const closeTriggerContracts: {
295
294
  threadId: z.ZodOptional<z.ZodString>;
296
295
  updatedAt: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodString]>, z.ZodTransform<Date, string | Date>>>;
297
296
  updatedBy: z.ZodOptional<z.ZodString>;
297
+ body: z.ZodOptional<z.ZodNullable<z.ZodString>>;
298
298
  }, z.core.$strip>;
299
299
  objectType: z.ZodLiteral<"comment">;
300
300
  }, z.core.$strip>;
@@ -213,6 +213,9 @@ export const CLOSE_TRIGGER_CONFIG_SCHEMA = z.object({});
213
213
  // resource. Close's documented opportunity-won webhook is one such payload.
214
214
  const CLOSE_CALL_EVENT_DATA_SCHEMA = CLOSE_CALL_SCHEMA.partial();
215
215
  const CLOSE_COMMENT_EVENT_DATA_SCHEMA = CLOSE_COMMENT_SCHEMA.partial();
216
+ const CLOSE_COMMENT_UPDATED_EVENT_DATA_SCHEMA = CLOSE_COMMENT_EVENT_DATA_SCHEMA.extend({
217
+ body: z.string().nullable().optional(),
218
+ });
216
219
  const CLOSE_CONTACT_EVENT_DATA_SCHEMA = CLOSE_CONTACT_SCHEMA.partial();
217
220
  const CLOSE_EMAIL_EVENT_DATA_SCHEMA = CLOSE_EMAIL_SCHEMA.partial();
218
221
  const CLOSE_LEAD_EVENT_DATA_SCHEMA = CLOSE_LEAD_SCHEMA.partial();
@@ -258,7 +261,7 @@ const SEMANTIC_EVENTS = {
258
261
  "close.comment.updated": [
259
262
  "comment",
260
263
  "updated",
261
- CLOSE_COMMENT_EVENT_DATA_SCHEMA,
264
+ CLOSE_COMMENT_UPDATED_EVENT_DATA_SCHEMA,
262
265
  ],
263
266
  "close.contact.created": [
264
267
  "contact",
@@ -421,7 +424,7 @@ export const closeTriggerContracts = {
421
424
  "close.call.completed": semanticContract("activity.call", "completed", CLOSE_CALL_EVENT_DATA_SCHEMA),
422
425
  "close.comment.created": semanticContract("comment", "created", CLOSE_COMMENT_EVENT_DATA_SCHEMA),
423
426
  "close.comment.deleted": semanticContract("comment", "deleted", CLOSE_DELETED_EVENT_DATA_SCHEMA),
424
- "close.comment.updated": semanticContract("comment", "updated", CLOSE_COMMENT_EVENT_DATA_SCHEMA),
427
+ "close.comment.updated": semanticContract("comment", "updated", CLOSE_COMMENT_UPDATED_EVENT_DATA_SCHEMA),
425
428
  "close.contact.created": semanticContract("contact", "created", CLOSE_CONTACT_EVENT_DATA_SCHEMA),
426
429
  "close.contact.deleted": semanticContract("contact", "deleted", CLOSE_DELETED_EVENT_DATA_SCHEMA),
427
430
  "close.contact.updated": semanticContract("contact", "updated", CLOSE_CONTACT_EVENT_DATA_SCHEMA),
@@ -776,11 +776,11 @@ export declare const CLOSE_CALL_SCHEMA: z.ZodObject<{
776
776
  External: "External";
777
777
  }>;
778
778
  status: z.ZodEnum<{
779
+ failed: "failed";
779
780
  completed: "completed";
780
781
  created: "created";
781
782
  busy: "busy";
782
783
  cancel: "cancel";
783
- failed: "failed";
784
784
  "in-progress": "in-progress";
785
785
  "no-answer": "no-answer";
786
786
  timeout: "timeout";
@@ -1006,11 +1006,11 @@ export declare const CLOSE_ACTIVITY_SCHEMA: z.ZodDiscriminatedUnion<[z.ZodObject
1006
1006
  External: "External";
1007
1007
  }>;
1008
1008
  status: z.ZodEnum<{
1009
+ failed: "failed";
1009
1010
  completed: "completed";
1010
1011
  created: "created";
1011
1012
  busy: "busy";
1012
1013
  cancel: "cancel";
1013
- failed: "failed";
1014
1014
  "in-progress": "in-progress";
1015
1015
  "no-answer": "no-answer";
1016
1016
  timeout: "timeout";
@@ -1475,8 +1475,8 @@ export declare const CLOSE_ACTIVITY_SCHEMA: z.ZodDiscriminatedUnion<[z.ZodObject
1475
1475
  generatedAt: z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodDate, z.ZodString]>, z.ZodTransform<Date, string | Date>>>;
1476
1476
  status: z.ZodEnum<{
1477
1477
  success: "success";
1478
- pending: "pending";
1479
1478
  failure: "failure";
1479
+ pending: "pending";
1480
1480
  expired: "expired";
1481
1481
  }>;
1482
1482
  summaryHtml: z.ZodNullable<z.ZodString>;
@@ -31,8 +31,8 @@ export declare const GOOGLE_CALENDAR_EVENT_DELETED_SCHEMA: z.ZodObject<{
31
31
  conferenceId: z.ZodOptional<z.ZodString>;
32
32
  creationStatus: z.ZodOptional<z.ZodEnum<{
33
33
  success: "success";
34
- pending: "pending";
35
34
  failure: "failure";
35
+ pending: "pending";
36
36
  }>>;
37
37
  entryPoints: z.ZodArray<z.ZodObject<{
38
38
  label: z.ZodOptional<z.ZodString>;
@@ -95,9 +95,9 @@ export declare const GOOGLE_CALENDAR_EVENT_DELETED_SCHEMA: z.ZodObject<{
95
95
  timeZone: z.ZodOptional<z.ZodString>;
96
96
  }, z.core.$strip>>;
97
97
  status: z.ZodEnum<{
98
+ cancelled: "cancelled";
98
99
  confirmed: "confirmed";
99
100
  tentative: "tentative";
100
- cancelled: "cancelled";
101
101
  }>;
102
102
  summary: z.ZodString;
103
103
  transparency: z.ZodEnum<{