@trigger.dev/core 0.0.0-v3-prerelease-20240923150540 → 0.0.0-v3-prerelease-20241009112547

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 (170) hide show
  1. package/dist/commonjs/schemas/api.d.ts +8 -8
  2. package/dist/commonjs/v3/apiClient/core.js +18 -1
  3. package/dist/commonjs/v3/apiClient/core.js.map +1 -1
  4. package/dist/commonjs/v3/apiClient/index.d.ts +78 -67
  5. package/dist/commonjs/v3/apiClient/index.js +7 -2
  6. package/dist/commonjs/v3/apiClient/index.js.map +1 -1
  7. package/dist/commonjs/v3/apiClientManager/index.d.ts +5 -0
  8. package/dist/commonjs/v3/apiClientManager/index.js +28 -1
  9. package/dist/commonjs/v3/apiClientManager/index.js.map +1 -1
  10. package/dist/commonjs/v3/apps/duration.d.ts +1 -0
  11. package/dist/commonjs/v3/apps/duration.js +51 -0
  12. package/dist/commonjs/v3/apps/duration.js.map +1 -0
  13. package/dist/commonjs/v3/apps/friendlyId.d.ts +1 -0
  14. package/dist/commonjs/v3/apps/friendlyId.js +9 -0
  15. package/dist/commonjs/v3/apps/friendlyId.js.map +1 -0
  16. package/dist/commonjs/v3/apps/index.d.ts +2 -0
  17. package/dist/commonjs/v3/apps/index.js +2 -0
  18. package/dist/commonjs/v3/apps/index.js.map +1 -1
  19. package/dist/commonjs/v3/config.d.ts +8 -0
  20. package/dist/commonjs/v3/errors.d.ts +12 -2
  21. package/dist/commonjs/v3/errors.js +107 -24
  22. package/dist/commonjs/v3/errors.js.map +1 -1
  23. package/dist/commonjs/v3/index.d.ts +3 -0
  24. package/dist/commonjs/v3/index.js +5 -1
  25. package/dist/commonjs/v3/index.js.map +1 -1
  26. package/dist/commonjs/v3/links.d.ts +17 -0
  27. package/dist/commonjs/v3/links.js +21 -0
  28. package/dist/commonjs/v3/links.js.map +1 -0
  29. package/dist/commonjs/v3/run-metadata-api.d.ts +2 -0
  30. package/dist/commonjs/v3/run-metadata-api.js +8 -0
  31. package/dist/commonjs/v3/run-metadata-api.js.map +1 -0
  32. package/dist/commonjs/v3/runMetadata/index.d.ts +15 -0
  33. package/dist/commonjs/v3/runMetadata/index.js +67 -0
  34. package/dist/commonjs/v3/runMetadata/index.js.map +1 -0
  35. package/dist/commonjs/v3/schemas/api.d.ts +387 -290
  36. package/dist/commonjs/v3/schemas/api.js +15 -1
  37. package/dist/commonjs/v3/schemas/api.js.map +1 -1
  38. package/dist/commonjs/v3/schemas/build.d.ts +90 -76
  39. package/dist/commonjs/v3/schemas/common.d.ts +151 -123
  40. package/dist/commonjs/v3/schemas/common.js +16 -1
  41. package/dist/commonjs/v3/schemas/common.js.map +1 -1
  42. package/dist/commonjs/v3/schemas/messages.d.ts +2710 -2442
  43. package/dist/commonjs/v3/schemas/messages.js +1 -0
  44. package/dist/commonjs/v3/schemas/messages.js.map +1 -1
  45. package/dist/commonjs/v3/schemas/resources.d.ts +36 -28
  46. package/dist/commonjs/v3/schemas/resources.js +1 -0
  47. package/dist/commonjs/v3/schemas/resources.js.map +1 -1
  48. package/dist/commonjs/v3/schemas/schemas.d.ts +307 -263
  49. package/dist/commonjs/v3/schemas/schemas.js +1 -0
  50. package/dist/commonjs/v3/schemas/schemas.js.map +1 -1
  51. package/dist/commonjs/v3/timeout/api.d.ts +11 -0
  52. package/dist/commonjs/v3/timeout/api.js +38 -0
  53. package/dist/commonjs/v3/timeout/api.js.map +1 -0
  54. package/dist/commonjs/v3/timeout/types.d.ts +9 -0
  55. package/dist/commonjs/v3/timeout/types.js +15 -0
  56. package/dist/commonjs/v3/timeout/types.js.map +1 -0
  57. package/dist/commonjs/v3/timeout/usageTimeoutManager.d.ts +10 -0
  58. package/dist/commonjs/v3/timeout/usageTimeoutManager.js +32 -0
  59. package/dist/commonjs/v3/timeout/usageTimeoutManager.js.map +1 -0
  60. package/dist/commonjs/v3/timeout-api.d.ts +3 -0
  61. package/dist/commonjs/v3/timeout-api.js +9 -0
  62. package/dist/commonjs/v3/timeout-api.js.map +1 -0
  63. package/dist/commonjs/v3/tracer.d.ts +1 -1
  64. package/dist/commonjs/v3/tracer.js +28 -14
  65. package/dist/commonjs/v3/tracer.js.map +1 -1
  66. package/dist/commonjs/v3/types/index.d.ts +10 -0
  67. package/dist/commonjs/v3/utils/globals.d.ts +4 -0
  68. package/dist/commonjs/v3/utils/globals.js.map +1 -1
  69. package/dist/commonjs/v3/utils/structuredLogger.d.ts +1 -0
  70. package/dist/commonjs/v3/utils/structuredLogger.js +10 -4
  71. package/dist/commonjs/v3/utils/structuredLogger.js.map +1 -1
  72. package/dist/commonjs/v3/workers/index.d.ts +1 -0
  73. package/dist/commonjs/v3/workers/index.js +3 -1
  74. package/dist/commonjs/v3/workers/index.js.map +1 -1
  75. package/dist/commonjs/v3/workers/taskExecutor.d.ts +1 -1
  76. package/dist/commonjs/v3/workers/taskExecutor.js +53 -43
  77. package/dist/commonjs/v3/workers/taskExecutor.js.map +1 -1
  78. package/dist/commonjs/v3/zodNamespace.d.ts +1 -0
  79. package/dist/commonjs/v3/zodNamespace.js +6 -1
  80. package/dist/commonjs/v3/zodNamespace.js.map +1 -1
  81. package/dist/commonjs/v3/zodSocket.d.ts +2 -0
  82. package/dist/commonjs/v3/zodSocket.js +15 -5
  83. package/dist/commonjs/v3/zodSocket.js.map +1 -1
  84. package/dist/commonjs/version.js +1 -1
  85. package/dist/esm/schemas/api.d.ts +8 -8
  86. package/dist/esm/v3/apiClient/core.js +18 -1
  87. package/dist/esm/v3/apiClient/core.js.map +1 -1
  88. package/dist/esm/v3/apiClient/index.d.ts +78 -67
  89. package/dist/esm/v3/apiClient/index.js +8 -3
  90. package/dist/esm/v3/apiClient/index.js.map +1 -1
  91. package/dist/esm/v3/apiClientManager/index.d.ts +5 -0
  92. package/dist/esm/v3/apiClientManager/index.js +26 -0
  93. package/dist/esm/v3/apiClientManager/index.js.map +1 -1
  94. package/dist/esm/v3/apps/duration.d.ts +1 -0
  95. package/dist/esm/v3/apps/duration.js +48 -0
  96. package/dist/esm/v3/apps/duration.js.map +1 -0
  97. package/dist/esm/v3/apps/friendlyId.d.ts +1 -0
  98. package/dist/esm/v3/apps/friendlyId.js +6 -0
  99. package/dist/esm/v3/apps/friendlyId.js.map +1 -0
  100. package/dist/esm/v3/apps/index.d.ts +2 -0
  101. package/dist/esm/v3/apps/index.js +2 -0
  102. package/dist/esm/v3/apps/index.js.map +1 -1
  103. package/dist/esm/v3/config.d.ts +8 -0
  104. package/dist/esm/v3/errors.d.ts +12 -2
  105. package/dist/esm/v3/errors.js +104 -23
  106. package/dist/esm/v3/errors.js.map +1 -1
  107. package/dist/esm/v3/index.d.ts +3 -0
  108. package/dist/esm/v3/index.js +3 -0
  109. package/dist/esm/v3/index.js.map +1 -1
  110. package/dist/esm/v3/links.d.ts +17 -0
  111. package/dist/esm/v3/links.js +18 -0
  112. package/dist/esm/v3/links.js.map +1 -0
  113. package/dist/esm/v3/run-metadata-api.d.ts +2 -0
  114. package/dist/esm/v3/run-metadata-api.js +5 -0
  115. package/dist/esm/v3/run-metadata-api.js.map +1 -0
  116. package/dist/esm/v3/runMetadata/index.d.ts +15 -0
  117. package/dist/esm/v3/runMetadata/index.js +63 -0
  118. package/dist/esm/v3/runMetadata/index.js.map +1 -0
  119. package/dist/esm/v3/schemas/api.d.ts +317 -220
  120. package/dist/esm/v3/schemas/api.js +14 -0
  121. package/dist/esm/v3/schemas/api.js.map +1 -1
  122. package/dist/esm/v3/schemas/build.d.ts +160 -146
  123. package/dist/esm/v3/schemas/common.d.ts +151 -123
  124. package/dist/esm/v3/schemas/common.js +16 -1
  125. package/dist/esm/v3/schemas/common.js.map +1 -1
  126. package/dist/esm/v3/schemas/fetch.d.ts +14 -14
  127. package/dist/esm/v3/schemas/messages.d.ts +2909 -2641
  128. package/dist/esm/v3/schemas/messages.js +2 -1
  129. package/dist/esm/v3/schemas/messages.js.map +1 -1
  130. package/dist/esm/v3/schemas/resources.d.ts +30 -22
  131. package/dist/esm/v3/schemas/resources.js +1 -0
  132. package/dist/esm/v3/schemas/resources.js.map +1 -1
  133. package/dist/esm/v3/schemas/schemas.d.ts +387 -343
  134. package/dist/esm/v3/schemas/schemas.js +1 -0
  135. package/dist/esm/v3/schemas/schemas.js.map +1 -1
  136. package/dist/esm/v3/timeout/api.d.ts +11 -0
  137. package/dist/esm/v3/timeout/api.js +34 -0
  138. package/dist/esm/v3/timeout/api.js.map +1 -0
  139. package/dist/esm/v3/timeout/types.d.ts +9 -0
  140. package/dist/esm/v3/timeout/types.js +11 -0
  141. package/dist/esm/v3/timeout/types.js.map +1 -0
  142. package/dist/esm/v3/timeout/usageTimeoutManager.d.ts +10 -0
  143. package/dist/esm/v3/timeout/usageTimeoutManager.js +28 -0
  144. package/dist/esm/v3/timeout/usageTimeoutManager.js.map +1 -0
  145. package/dist/esm/v3/timeout-api.d.ts +3 -0
  146. package/dist/esm/v3/timeout-api.js +6 -0
  147. package/dist/esm/v3/timeout-api.js.map +1 -0
  148. package/dist/esm/v3/tracer.d.ts +1 -1
  149. package/dist/esm/v3/tracer.js +28 -14
  150. package/dist/esm/v3/tracer.js.map +1 -1
  151. package/dist/esm/v3/types/index.d.ts +10 -0
  152. package/dist/esm/v3/utils/globals.d.ts +4 -0
  153. package/dist/esm/v3/utils/globals.js.map +1 -1
  154. package/dist/esm/v3/utils/structuredLogger.d.ts +1 -0
  155. package/dist/esm/v3/utils/structuredLogger.js +10 -4
  156. package/dist/esm/v3/utils/structuredLogger.js.map +1 -1
  157. package/dist/esm/v3/workers/index.d.ts +1 -0
  158. package/dist/esm/v3/workers/index.js +1 -0
  159. package/dist/esm/v3/workers/index.js.map +1 -1
  160. package/dist/esm/v3/workers/taskExecutor.d.ts +1 -1
  161. package/dist/esm/v3/workers/taskExecutor.js +45 -35
  162. package/dist/esm/v3/workers/taskExecutor.js.map +1 -1
  163. package/dist/esm/v3/zodNamespace.d.ts +1 -0
  164. package/dist/esm/v3/zodNamespace.js +6 -1
  165. package/dist/esm/v3/zodNamespace.js.map +1 -1
  166. package/dist/esm/v3/zodSocket.d.ts +2 -0
  167. package/dist/esm/v3/zodSocket.js +15 -5
  168. package/dist/esm/v3/zodSocket.js.map +1 -1
  169. package/dist/esm/version.js +1 -1
  170. package/package.json +2 -1
@@ -54,14 +54,16 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
54
54
  costInCents: z.ZodDefault<z.ZodNumber>;
55
55
  baseCostInCents: z.ZodDefault<z.ZodNumber>;
56
56
  version: z.ZodOptional<z.ZodString>;
57
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<import("../../index.js").DeserializedJson, z.ZodTypeDef, import("../../index.js").DeserializedJson>>>;
58
+ maxDuration: z.ZodOptional<z.ZodNumber>;
57
59
  }, "strip", z.ZodTypeAny, {
58
- payload: string;
59
60
  id: string;
60
- startedAt: Date;
61
+ payload: string;
61
62
  payloadType: string;
63
+ tags: string[];
62
64
  isTest: boolean;
63
65
  createdAt: Date;
64
- tags: string[];
66
+ startedAt: Date;
65
67
  durationMs: number;
66
68
  costInCents: number;
67
69
  baseCostInCents: number;
@@ -69,12 +71,14 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
69
71
  idempotencyKey?: string | undefined;
70
72
  maxAttempts?: number | undefined;
71
73
  version?: string | undefined;
74
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
75
+ maxDuration?: number | undefined;
72
76
  }, {
73
- payload: string;
74
77
  id: string;
78
+ payload: string;
75
79
  payloadType: string;
76
- createdAt: Date;
77
80
  tags: string[];
81
+ createdAt: Date;
78
82
  context?: any;
79
83
  isTest?: boolean | undefined;
80
84
  startedAt?: Date | undefined;
@@ -84,6 +88,8 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
84
88
  costInCents?: number | undefined;
85
89
  baseCostInCents?: number | undefined;
86
90
  version?: string | undefined;
91
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
92
+ maxDuration?: number | undefined;
87
93
  }>;
88
94
  queue: z.ZodObject<{
89
95
  id: z.ZodString;
@@ -150,25 +156,38 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
150
156
  memory: z.ZodNumber;
151
157
  centsPerMs: z.ZodNumber;
152
158
  }, "strip", z.ZodTypeAny, {
153
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
154
159
  cpu: number;
155
160
  memory: number;
161
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
156
162
  centsPerMs: number;
157
163
  }, {
158
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
159
164
  cpu: number;
160
165
  memory: number;
166
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
161
167
  centsPerMs: number;
162
168
  }>>;
163
169
  }, "strip", z.ZodTypeAny, {
164
- run: {
165
- payload: string;
170
+ task: {
171
+ id: string;
172
+ filePath: string;
173
+ exportName: string;
174
+ };
175
+ attempt: {
176
+ number: number;
177
+ status: string;
166
178
  id: string;
167
179
  startedAt: Date;
180
+ backgroundWorkerId: string;
181
+ backgroundWorkerTaskId: string;
182
+ };
183
+ run: {
184
+ id: string;
185
+ payload: string;
168
186
  payloadType: string;
187
+ tags: string[];
169
188
  isTest: boolean;
170
189
  createdAt: Date;
171
- tags: string[];
190
+ startedAt: Date;
172
191
  durationMs: number;
173
192
  costInCents: number;
174
193
  baseCostInCents: number;
@@ -176,6 +195,12 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
176
195
  idempotencyKey?: string | undefined;
177
196
  maxAttempts?: number | undefined;
178
197
  version?: string | undefined;
198
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
199
+ maxDuration?: number | undefined;
200
+ };
201
+ queue: {
202
+ name: string;
203
+ id: string;
179
204
  };
180
205
  environment: {
181
206
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -193,6 +218,16 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
193
218
  slug: string;
194
219
  ref: string;
195
220
  };
221
+ batch?: {
222
+ id: string;
223
+ } | undefined;
224
+ machine?: {
225
+ cpu: number;
226
+ memory: number;
227
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
228
+ centsPerMs: number;
229
+ } | undefined;
230
+ }, {
196
231
  task: {
197
232
  id: string;
198
233
  filePath: string;
@@ -206,26 +241,12 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
206
241
  backgroundWorkerId: string;
207
242
  backgroundWorkerTaskId: string;
208
243
  };
209
- queue: {
210
- name: string;
211
- id: string;
212
- };
213
- batch?: {
214
- id: string;
215
- } | undefined;
216
- machine?: {
217
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
218
- cpu: number;
219
- memory: number;
220
- centsPerMs: number;
221
- } | undefined;
222
- }, {
223
244
  run: {
224
- payload: string;
225
245
  id: string;
246
+ payload: string;
226
247
  payloadType: string;
227
- createdAt: Date;
228
248
  tags: string[];
249
+ createdAt: Date;
229
250
  context?: any;
230
251
  isTest?: boolean | undefined;
231
252
  startedAt?: Date | undefined;
@@ -235,6 +256,12 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
235
256
  costInCents?: number | undefined;
236
257
  baseCostInCents?: number | undefined;
237
258
  version?: string | undefined;
259
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
260
+ maxDuration?: number | undefined;
261
+ };
262
+ queue: {
263
+ name: string;
264
+ id: string;
238
265
  };
239
266
  environment: {
240
267
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -252,45 +279,42 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
252
279
  slug: string;
253
280
  ref: string;
254
281
  };
255
- task: {
256
- id: string;
257
- filePath: string;
258
- exportName: string;
259
- };
260
- attempt: {
261
- number: number;
262
- status: string;
263
- id: string;
264
- startedAt: Date;
265
- backgroundWorkerId: string;
266
- backgroundWorkerTaskId: string;
267
- };
268
- queue: {
269
- name: string;
270
- id: string;
271
- };
272
282
  batch?: {
273
283
  id: string;
274
284
  } | undefined;
275
285
  machine?: {
276
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
277
286
  cpu: number;
278
287
  memory: number;
288
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
279
289
  centsPerMs: number;
280
290
  } | undefined;
281
291
  }>;
282
292
  traceContext: z.ZodRecord<z.ZodString, z.ZodUnknown>;
283
293
  environment: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
284
294
  }, "strip", z.ZodTypeAny, {
295
+ traceContext: Record<string, unknown>;
285
296
  execution: {
286
- run: {
287
- payload: string;
297
+ task: {
298
+ id: string;
299
+ filePath: string;
300
+ exportName: string;
301
+ };
302
+ attempt: {
303
+ number: number;
304
+ status: string;
288
305
  id: string;
289
306
  startedAt: Date;
307
+ backgroundWorkerId: string;
308
+ backgroundWorkerTaskId: string;
309
+ };
310
+ run: {
311
+ id: string;
312
+ payload: string;
290
313
  payloadType: string;
314
+ tags: string[];
291
315
  isTest: boolean;
292
316
  createdAt: Date;
293
- tags: string[];
317
+ startedAt: Date;
294
318
  durationMs: number;
295
319
  costInCents: number;
296
320
  baseCostInCents: number;
@@ -298,6 +322,12 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
298
322
  idempotencyKey?: string | undefined;
299
323
  maxAttempts?: number | undefined;
300
324
  version?: string | undefined;
325
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
326
+ maxDuration?: number | undefined;
327
+ };
328
+ queue: {
329
+ name: string;
330
+ id: string;
301
331
  };
302
332
  environment: {
303
333
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -315,6 +345,20 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
315
345
  slug: string;
316
346
  ref: string;
317
347
  };
348
+ batch?: {
349
+ id: string;
350
+ } | undefined;
351
+ machine?: {
352
+ cpu: number;
353
+ memory: number;
354
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
355
+ centsPerMs: number;
356
+ } | undefined;
357
+ };
358
+ environment?: Record<string, string> | undefined;
359
+ }, {
360
+ traceContext: Record<string, unknown>;
361
+ execution: {
318
362
  task: {
319
363
  id: string;
320
364
  filePath: string;
@@ -328,30 +372,12 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
328
372
  backgroundWorkerId: string;
329
373
  backgroundWorkerTaskId: string;
330
374
  };
331
- queue: {
332
- name: string;
333
- id: string;
334
- };
335
- batch?: {
336
- id: string;
337
- } | undefined;
338
- machine?: {
339
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
340
- cpu: number;
341
- memory: number;
342
- centsPerMs: number;
343
- } | undefined;
344
- };
345
- traceContext: Record<string, unknown>;
346
- environment?: Record<string, string> | undefined;
347
- }, {
348
- execution: {
349
375
  run: {
350
- payload: string;
351
376
  id: string;
377
+ payload: string;
352
378
  payloadType: string;
353
- createdAt: Date;
354
379
  tags: string[];
380
+ createdAt: Date;
355
381
  context?: any;
356
382
  isTest?: boolean | undefined;
357
383
  startedAt?: Date | undefined;
@@ -361,6 +387,12 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
361
387
  costInCents?: number | undefined;
362
388
  baseCostInCents?: number | undefined;
363
389
  version?: string | undefined;
390
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
391
+ maxDuration?: number | undefined;
392
+ };
393
+ queue: {
394
+ name: string;
395
+ id: string;
364
396
  };
365
397
  environment: {
366
398
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -378,38 +410,55 @@ export declare const TaskRunExecutionPayload: z.ZodObject<{
378
410
  slug: string;
379
411
  ref: string;
380
412
  };
381
- task: {
382
- id: string;
383
- filePath: string;
384
- exportName: string;
385
- };
386
- attempt: {
387
- number: number;
388
- status: string;
389
- id: string;
390
- startedAt: Date;
391
- backgroundWorkerId: string;
392
- backgroundWorkerTaskId: string;
393
- };
394
- queue: {
395
- name: string;
396
- id: string;
397
- };
398
413
  batch?: {
399
414
  id: string;
400
415
  } | undefined;
401
416
  machine?: {
402
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
403
417
  cpu: number;
404
418
  memory: number;
419
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
405
420
  centsPerMs: number;
406
421
  } | undefined;
407
422
  };
408
- traceContext: Record<string, unknown>;
409
423
  environment?: Record<string, string> | undefined;
410
424
  }>;
411
425
  export type TaskRunExecutionPayload = z.infer<typeof TaskRunExecutionPayload>;
412
426
  export declare const ProdTaskRunExecution: z.ZodObject<{
427
+ task: z.ZodObject<{
428
+ id: z.ZodString;
429
+ filePath: z.ZodString;
430
+ exportName: z.ZodString;
431
+ }, "strip", z.ZodTypeAny, {
432
+ id: string;
433
+ filePath: string;
434
+ exportName: string;
435
+ }, {
436
+ id: string;
437
+ filePath: string;
438
+ exportName: string;
439
+ }>;
440
+ attempt: z.ZodObject<{
441
+ id: z.ZodString;
442
+ number: z.ZodNumber;
443
+ startedAt: z.ZodDate;
444
+ backgroundWorkerId: z.ZodString;
445
+ backgroundWorkerTaskId: z.ZodString;
446
+ status: z.ZodString;
447
+ }, "strip", z.ZodTypeAny, {
448
+ number: number;
449
+ status: string;
450
+ id: string;
451
+ startedAt: Date;
452
+ backgroundWorkerId: string;
453
+ backgroundWorkerTaskId: string;
454
+ }, {
455
+ number: number;
456
+ status: string;
457
+ id: string;
458
+ startedAt: Date;
459
+ backgroundWorkerId: string;
460
+ backgroundWorkerTaskId: string;
461
+ }>;
413
462
  run: z.ZodObject<{
414
463
  id: z.ZodString;
415
464
  payload: z.ZodString;
@@ -425,14 +474,16 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
425
474
  costInCents: z.ZodDefault<z.ZodNumber>;
426
475
  baseCostInCents: z.ZodDefault<z.ZodNumber>;
427
476
  version: z.ZodOptional<z.ZodString>;
477
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<import("../../index.js").DeserializedJson, z.ZodTypeDef, import("../../index.js").DeserializedJson>>>;
478
+ maxDuration: z.ZodOptional<z.ZodNumber>;
428
479
  }, "strip", z.ZodTypeAny, {
429
- payload: string;
430
480
  id: string;
431
- startedAt: Date;
481
+ payload: string;
432
482
  payloadType: string;
483
+ tags: string[];
433
484
  isTest: boolean;
434
485
  createdAt: Date;
435
- tags: string[];
486
+ startedAt: Date;
436
487
  durationMs: number;
437
488
  costInCents: number;
438
489
  baseCostInCents: number;
@@ -440,12 +491,14 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
440
491
  idempotencyKey?: string | undefined;
441
492
  maxAttempts?: number | undefined;
442
493
  version?: string | undefined;
494
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
495
+ maxDuration?: number | undefined;
443
496
  }, {
444
- payload: string;
445
497
  id: string;
498
+ payload: string;
446
499
  payloadType: string;
447
- createdAt: Date;
448
500
  tags: string[];
501
+ createdAt: Date;
449
502
  context?: any;
450
503
  isTest?: boolean | undefined;
451
504
  startedAt?: Date | undefined;
@@ -455,6 +508,18 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
455
508
  costInCents?: number | undefined;
456
509
  baseCostInCents?: number | undefined;
457
510
  version?: string | undefined;
511
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
512
+ maxDuration?: number | undefined;
513
+ }>;
514
+ queue: z.ZodObject<{
515
+ id: z.ZodString;
516
+ name: z.ZodString;
517
+ }, "strip", z.ZodTypeAny, {
518
+ name: string;
519
+ id: string;
520
+ }, {
521
+ name: string;
522
+ id: string;
458
523
  }>;
459
524
  environment: z.ZodObject<{
460
525
  id: z.ZodString;
@@ -498,51 +563,6 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
498
563
  slug: string;
499
564
  ref: string;
500
565
  }>;
501
- task: z.ZodObject<{
502
- id: z.ZodString;
503
- filePath: z.ZodString;
504
- exportName: z.ZodString;
505
- }, "strip", z.ZodTypeAny, {
506
- id: string;
507
- filePath: string;
508
- exportName: string;
509
- }, {
510
- id: string;
511
- filePath: string;
512
- exportName: string;
513
- }>;
514
- attempt: z.ZodObject<{
515
- id: z.ZodString;
516
- number: z.ZodNumber;
517
- startedAt: z.ZodDate;
518
- backgroundWorkerId: z.ZodString;
519
- backgroundWorkerTaskId: z.ZodString;
520
- status: z.ZodString;
521
- }, "strip", z.ZodTypeAny, {
522
- number: number;
523
- status: string;
524
- id: string;
525
- startedAt: Date;
526
- backgroundWorkerId: string;
527
- backgroundWorkerTaskId: string;
528
- }, {
529
- number: number;
530
- status: string;
531
- id: string;
532
- startedAt: Date;
533
- backgroundWorkerId: string;
534
- backgroundWorkerTaskId: string;
535
- }>;
536
- queue: z.ZodObject<{
537
- id: z.ZodString;
538
- name: z.ZodString;
539
- }, "strip", z.ZodTypeAny, {
540
- name: string;
541
- id: string;
542
- }, {
543
- name: string;
544
- id: string;
545
- }>;
546
566
  batch: z.ZodOptional<z.ZodObject<{
547
567
  id: z.ZodString;
548
568
  }, "strip", z.ZodTypeAny, {
@@ -555,12 +575,12 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
555
575
  contentHash: z.ZodString;
556
576
  version: z.ZodString;
557
577
  }, "strip", z.ZodTypeAny, {
558
- version: string;
559
578
  id: string;
579
+ version: string;
560
580
  contentHash: string;
561
581
  }, {
562
- version: string;
563
582
  id: string;
583
+ version: string;
564
584
  contentHash: string;
565
585
  }>;
566
586
  machine: z.ZodDefault<z.ZodObject<{
@@ -569,25 +589,38 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
569
589
  memory: z.ZodNumber;
570
590
  centsPerMs: z.ZodNumber;
571
591
  }, "strip", z.ZodTypeAny, {
572
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
573
592
  cpu: number;
574
593
  memory: number;
594
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
575
595
  centsPerMs: number;
576
596
  }, {
577
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
578
597
  cpu: number;
579
598
  memory: number;
599
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
580
600
  centsPerMs: number;
581
601
  }>>;
582
602
  }, "strip", z.ZodTypeAny, {
583
- run: {
584
- payload: string;
603
+ task: {
604
+ id: string;
605
+ filePath: string;
606
+ exportName: string;
607
+ };
608
+ attempt: {
609
+ number: number;
610
+ status: string;
585
611
  id: string;
586
612
  startedAt: Date;
613
+ backgroundWorkerId: string;
614
+ backgroundWorkerTaskId: string;
615
+ };
616
+ run: {
617
+ id: string;
618
+ payload: string;
587
619
  payloadType: string;
620
+ tags: string[];
588
621
  isTest: boolean;
589
622
  createdAt: Date;
590
- tags: string[];
623
+ startedAt: Date;
591
624
  durationMs: number;
592
625
  costInCents: number;
593
626
  baseCostInCents: number;
@@ -595,6 +628,12 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
595
628
  idempotencyKey?: string | undefined;
596
629
  maxAttempts?: number | undefined;
597
630
  version?: string | undefined;
631
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
632
+ maxDuration?: number | undefined;
633
+ };
634
+ queue: {
635
+ name: string;
636
+ id: string;
598
637
  };
599
638
  environment: {
600
639
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -612,44 +651,40 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
612
651
  slug: string;
613
652
  ref: string;
614
653
  };
615
- task: {
616
- id: string;
617
- filePath: string;
618
- exportName: string;
619
- };
620
- attempt: {
621
- number: number;
622
- status: string;
623
- id: string;
624
- startedAt: Date;
625
- backgroundWorkerId: string;
626
- backgroundWorkerTaskId: string;
627
- };
628
- queue: {
629
- name: string;
630
- id: string;
631
- };
632
654
  machine: {
633
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
634
655
  cpu: number;
635
656
  memory: number;
657
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
636
658
  centsPerMs: number;
637
659
  };
638
660
  worker: {
639
- version: string;
640
661
  id: string;
662
+ version: string;
641
663
  contentHash: string;
642
664
  };
643
665
  batch?: {
644
666
  id: string;
645
667
  } | undefined;
646
668
  }, {
669
+ task: {
670
+ id: string;
671
+ filePath: string;
672
+ exportName: string;
673
+ };
674
+ attempt: {
675
+ number: number;
676
+ status: string;
677
+ id: string;
678
+ startedAt: Date;
679
+ backgroundWorkerId: string;
680
+ backgroundWorkerTaskId: string;
681
+ };
647
682
  run: {
648
- payload: string;
649
683
  id: string;
684
+ payload: string;
650
685
  payloadType: string;
651
- createdAt: Date;
652
686
  tags: string[];
687
+ createdAt: Date;
653
688
  context?: any;
654
689
  isTest?: boolean | undefined;
655
690
  startedAt?: Date | undefined;
@@ -659,6 +694,12 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
659
694
  costInCents?: number | undefined;
660
695
  baseCostInCents?: number | undefined;
661
696
  version?: string | undefined;
697
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
698
+ maxDuration?: number | undefined;
699
+ };
700
+ queue: {
701
+ name: string;
702
+ id: string;
662
703
  };
663
704
  environment: {
664
705
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -676,41 +717,59 @@ export declare const ProdTaskRunExecution: z.ZodObject<{
676
717
  slug: string;
677
718
  ref: string;
678
719
  };
679
- task: {
680
- id: string;
681
- filePath: string;
682
- exportName: string;
683
- };
684
- attempt: {
685
- number: number;
686
- status: string;
687
- id: string;
688
- startedAt: Date;
689
- backgroundWorkerId: string;
690
- backgroundWorkerTaskId: string;
691
- };
692
- queue: {
693
- name: string;
694
- id: string;
695
- };
696
720
  worker: {
697
- version: string;
698
721
  id: string;
722
+ version: string;
699
723
  contentHash: string;
700
724
  };
701
725
  batch?: {
702
726
  id: string;
703
727
  } | undefined;
704
728
  machine?: {
705
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
706
729
  cpu: number;
707
730
  memory: number;
731
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
708
732
  centsPerMs: number;
709
733
  } | undefined;
710
734
  }>;
711
735
  export type ProdTaskRunExecution = z.infer<typeof ProdTaskRunExecution>;
712
736
  export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
713
737
  execution: z.ZodObject<{
738
+ task: z.ZodObject<{
739
+ id: z.ZodString;
740
+ filePath: z.ZodString;
741
+ exportName: z.ZodString;
742
+ }, "strip", z.ZodTypeAny, {
743
+ id: string;
744
+ filePath: string;
745
+ exportName: string;
746
+ }, {
747
+ id: string;
748
+ filePath: string;
749
+ exportName: string;
750
+ }>;
751
+ attempt: z.ZodObject<{
752
+ id: z.ZodString;
753
+ number: z.ZodNumber;
754
+ startedAt: z.ZodDate;
755
+ backgroundWorkerId: z.ZodString;
756
+ backgroundWorkerTaskId: z.ZodString;
757
+ status: z.ZodString;
758
+ }, "strip", z.ZodTypeAny, {
759
+ number: number;
760
+ status: string;
761
+ id: string;
762
+ startedAt: Date;
763
+ backgroundWorkerId: string;
764
+ backgroundWorkerTaskId: string;
765
+ }, {
766
+ number: number;
767
+ status: string;
768
+ id: string;
769
+ startedAt: Date;
770
+ backgroundWorkerId: string;
771
+ backgroundWorkerTaskId: string;
772
+ }>;
714
773
  run: z.ZodObject<{
715
774
  id: z.ZodString;
716
775
  payload: z.ZodString;
@@ -726,14 +785,16 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
726
785
  costInCents: z.ZodDefault<z.ZodNumber>;
727
786
  baseCostInCents: z.ZodDefault<z.ZodNumber>;
728
787
  version: z.ZodOptional<z.ZodString>;
788
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<import("../../index.js").DeserializedJson, z.ZodTypeDef, import("../../index.js").DeserializedJson>>>;
789
+ maxDuration: z.ZodOptional<z.ZodNumber>;
729
790
  }, "strip", z.ZodTypeAny, {
730
- payload: string;
731
791
  id: string;
732
- startedAt: Date;
792
+ payload: string;
733
793
  payloadType: string;
794
+ tags: string[];
734
795
  isTest: boolean;
735
796
  createdAt: Date;
736
- tags: string[];
797
+ startedAt: Date;
737
798
  durationMs: number;
738
799
  costInCents: number;
739
800
  baseCostInCents: number;
@@ -741,12 +802,14 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
741
802
  idempotencyKey?: string | undefined;
742
803
  maxAttempts?: number | undefined;
743
804
  version?: string | undefined;
805
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
806
+ maxDuration?: number | undefined;
744
807
  }, {
745
- payload: string;
746
808
  id: string;
809
+ payload: string;
747
810
  payloadType: string;
748
- createdAt: Date;
749
811
  tags: string[];
812
+ createdAt: Date;
750
813
  context?: any;
751
814
  isTest?: boolean | undefined;
752
815
  startedAt?: Date | undefined;
@@ -756,6 +819,18 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
756
819
  costInCents?: number | undefined;
757
820
  baseCostInCents?: number | undefined;
758
821
  version?: string | undefined;
822
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
823
+ maxDuration?: number | undefined;
824
+ }>;
825
+ queue: z.ZodObject<{
826
+ id: z.ZodString;
827
+ name: z.ZodString;
828
+ }, "strip", z.ZodTypeAny, {
829
+ name: string;
830
+ id: string;
831
+ }, {
832
+ name: string;
833
+ id: string;
759
834
  }>;
760
835
  environment: z.ZodObject<{
761
836
  id: z.ZodString;
@@ -799,51 +874,6 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
799
874
  slug: string;
800
875
  ref: string;
801
876
  }>;
802
- task: z.ZodObject<{
803
- id: z.ZodString;
804
- filePath: z.ZodString;
805
- exportName: z.ZodString;
806
- }, "strip", z.ZodTypeAny, {
807
- id: string;
808
- filePath: string;
809
- exportName: string;
810
- }, {
811
- id: string;
812
- filePath: string;
813
- exportName: string;
814
- }>;
815
- attempt: z.ZodObject<{
816
- id: z.ZodString;
817
- number: z.ZodNumber;
818
- startedAt: z.ZodDate;
819
- backgroundWorkerId: z.ZodString;
820
- backgroundWorkerTaskId: z.ZodString;
821
- status: z.ZodString;
822
- }, "strip", z.ZodTypeAny, {
823
- number: number;
824
- status: string;
825
- id: string;
826
- startedAt: Date;
827
- backgroundWorkerId: string;
828
- backgroundWorkerTaskId: string;
829
- }, {
830
- number: number;
831
- status: string;
832
- id: string;
833
- startedAt: Date;
834
- backgroundWorkerId: string;
835
- backgroundWorkerTaskId: string;
836
- }>;
837
- queue: z.ZodObject<{
838
- id: z.ZodString;
839
- name: z.ZodString;
840
- }, "strip", z.ZodTypeAny, {
841
- name: string;
842
- id: string;
843
- }, {
844
- name: string;
845
- id: string;
846
- }>;
847
877
  batch: z.ZodOptional<z.ZodObject<{
848
878
  id: z.ZodString;
849
879
  }, "strip", z.ZodTypeAny, {
@@ -856,12 +886,12 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
856
886
  contentHash: z.ZodString;
857
887
  version: z.ZodString;
858
888
  }, "strip", z.ZodTypeAny, {
859
- version: string;
860
889
  id: string;
890
+ version: string;
861
891
  contentHash: string;
862
892
  }, {
863
- version: string;
864
893
  id: string;
894
+ version: string;
865
895
  contentHash: string;
866
896
  }>;
867
897
  machine: z.ZodDefault<z.ZodObject<{
@@ -870,25 +900,38 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
870
900
  memory: z.ZodNumber;
871
901
  centsPerMs: z.ZodNumber;
872
902
  }, "strip", z.ZodTypeAny, {
873
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
874
903
  cpu: number;
875
904
  memory: number;
905
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
876
906
  centsPerMs: number;
877
907
  }, {
878
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
879
908
  cpu: number;
880
909
  memory: number;
910
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
881
911
  centsPerMs: number;
882
912
  }>>;
883
913
  }, "strip", z.ZodTypeAny, {
884
- run: {
885
- payload: string;
914
+ task: {
915
+ id: string;
916
+ filePath: string;
917
+ exportName: string;
918
+ };
919
+ attempt: {
920
+ number: number;
921
+ status: string;
886
922
  id: string;
887
923
  startedAt: Date;
924
+ backgroundWorkerId: string;
925
+ backgroundWorkerTaskId: string;
926
+ };
927
+ run: {
928
+ id: string;
929
+ payload: string;
888
930
  payloadType: string;
931
+ tags: string[];
889
932
  isTest: boolean;
890
933
  createdAt: Date;
891
- tags: string[];
934
+ startedAt: Date;
892
935
  durationMs: number;
893
936
  costInCents: number;
894
937
  baseCostInCents: number;
@@ -896,6 +939,12 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
896
939
  idempotencyKey?: string | undefined;
897
940
  maxAttempts?: number | undefined;
898
941
  version?: string | undefined;
942
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
943
+ maxDuration?: number | undefined;
944
+ };
945
+ queue: {
946
+ name: string;
947
+ id: string;
899
948
  };
900
949
  environment: {
901
950
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -913,44 +962,40 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
913
962
  slug: string;
914
963
  ref: string;
915
964
  };
916
- task: {
917
- id: string;
918
- filePath: string;
919
- exportName: string;
920
- };
921
- attempt: {
922
- number: number;
923
- status: string;
924
- id: string;
925
- startedAt: Date;
926
- backgroundWorkerId: string;
927
- backgroundWorkerTaskId: string;
928
- };
929
- queue: {
930
- name: string;
931
- id: string;
932
- };
933
965
  machine: {
934
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
935
966
  cpu: number;
936
967
  memory: number;
968
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
937
969
  centsPerMs: number;
938
970
  };
939
971
  worker: {
940
- version: string;
941
972
  id: string;
973
+ version: string;
942
974
  contentHash: string;
943
975
  };
944
976
  batch?: {
945
977
  id: string;
946
978
  } | undefined;
947
979
  }, {
980
+ task: {
981
+ id: string;
982
+ filePath: string;
983
+ exportName: string;
984
+ };
985
+ attempt: {
986
+ number: number;
987
+ status: string;
988
+ id: string;
989
+ startedAt: Date;
990
+ backgroundWorkerId: string;
991
+ backgroundWorkerTaskId: string;
992
+ };
948
993
  run: {
949
- payload: string;
950
994
  id: string;
995
+ payload: string;
951
996
  payloadType: string;
952
- createdAt: Date;
953
997
  tags: string[];
998
+ createdAt: Date;
954
999
  context?: any;
955
1000
  isTest?: boolean | undefined;
956
1001
  startedAt?: Date | undefined;
@@ -960,6 +1005,12 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
960
1005
  costInCents?: number | undefined;
961
1006
  baseCostInCents?: number | undefined;
962
1007
  version?: string | undefined;
1008
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
1009
+ maxDuration?: number | undefined;
1010
+ };
1011
+ queue: {
1012
+ name: string;
1013
+ id: string;
963
1014
  };
964
1015
  environment: {
965
1016
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -977,50 +1028,47 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
977
1028
  slug: string;
978
1029
  ref: string;
979
1030
  };
980
- task: {
981
- id: string;
982
- filePath: string;
983
- exportName: string;
984
- };
985
- attempt: {
986
- number: number;
987
- status: string;
988
- id: string;
989
- startedAt: Date;
990
- backgroundWorkerId: string;
991
- backgroundWorkerTaskId: string;
992
- };
993
- queue: {
994
- name: string;
995
- id: string;
996
- };
997
1031
  worker: {
998
- version: string;
999
1032
  id: string;
1033
+ version: string;
1000
1034
  contentHash: string;
1001
1035
  };
1002
1036
  batch?: {
1003
1037
  id: string;
1004
1038
  } | undefined;
1005
1039
  machine?: {
1006
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
1007
1040
  cpu: number;
1008
1041
  memory: number;
1042
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
1009
1043
  centsPerMs: number;
1010
1044
  } | undefined;
1011
1045
  }>;
1012
1046
  traceContext: z.ZodRecord<z.ZodString, z.ZodUnknown>;
1013
1047
  environment: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1014
1048
  }, "strip", z.ZodTypeAny, {
1049
+ traceContext: Record<string, unknown>;
1015
1050
  execution: {
1016
- run: {
1017
- payload: string;
1051
+ task: {
1052
+ id: string;
1053
+ filePath: string;
1054
+ exportName: string;
1055
+ };
1056
+ attempt: {
1057
+ number: number;
1058
+ status: string;
1018
1059
  id: string;
1019
1060
  startedAt: Date;
1061
+ backgroundWorkerId: string;
1062
+ backgroundWorkerTaskId: string;
1063
+ };
1064
+ run: {
1065
+ id: string;
1066
+ payload: string;
1020
1067
  payloadType: string;
1068
+ tags: string[];
1021
1069
  isTest: boolean;
1022
1070
  createdAt: Date;
1023
- tags: string[];
1071
+ startedAt: Date;
1024
1072
  durationMs: number;
1025
1073
  costInCents: number;
1026
1074
  baseCostInCents: number;
@@ -1028,6 +1076,12 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
1028
1076
  idempotencyKey?: string | undefined;
1029
1077
  maxAttempts?: number | undefined;
1030
1078
  version?: string | undefined;
1079
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
1080
+ maxDuration?: number | undefined;
1081
+ };
1082
+ queue: {
1083
+ name: string;
1084
+ id: string;
1031
1085
  };
1032
1086
  environment: {
1033
1087
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -1045,48 +1099,44 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
1045
1099
  slug: string;
1046
1100
  ref: string;
1047
1101
  };
1048
- task: {
1049
- id: string;
1050
- filePath: string;
1051
- exportName: string;
1052
- };
1053
- attempt: {
1054
- number: number;
1055
- status: string;
1056
- id: string;
1057
- startedAt: Date;
1058
- backgroundWorkerId: string;
1059
- backgroundWorkerTaskId: string;
1060
- };
1061
- queue: {
1062
- name: string;
1063
- id: string;
1064
- };
1065
1102
  machine: {
1066
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
1067
1103
  cpu: number;
1068
1104
  memory: number;
1105
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
1069
1106
  centsPerMs: number;
1070
1107
  };
1071
1108
  worker: {
1072
- version: string;
1073
1109
  id: string;
1110
+ version: string;
1074
1111
  contentHash: string;
1075
1112
  };
1076
1113
  batch?: {
1077
1114
  id: string;
1078
1115
  } | undefined;
1079
1116
  };
1080
- traceContext: Record<string, unknown>;
1081
1117
  environment?: Record<string, string> | undefined;
1082
1118
  }, {
1119
+ traceContext: Record<string, unknown>;
1083
1120
  execution: {
1121
+ task: {
1122
+ id: string;
1123
+ filePath: string;
1124
+ exportName: string;
1125
+ };
1126
+ attempt: {
1127
+ number: number;
1128
+ status: string;
1129
+ id: string;
1130
+ startedAt: Date;
1131
+ backgroundWorkerId: string;
1132
+ backgroundWorkerTaskId: string;
1133
+ };
1084
1134
  run: {
1085
- payload: string;
1086
1135
  id: string;
1136
+ payload: string;
1087
1137
  payloadType: string;
1088
- createdAt: Date;
1089
1138
  tags: string[];
1139
+ createdAt: Date;
1090
1140
  context?: any;
1091
1141
  isTest?: boolean | undefined;
1092
1142
  startedAt?: Date | undefined;
@@ -1096,6 +1146,12 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
1096
1146
  costInCents?: number | undefined;
1097
1147
  baseCostInCents?: number | undefined;
1098
1148
  version?: string | undefined;
1149
+ metadata?: Record<string, import("../../index.js").DeserializedJson> | undefined;
1150
+ maxDuration?: number | undefined;
1151
+ };
1152
+ queue: {
1153
+ name: string;
1154
+ id: string;
1099
1155
  };
1100
1156
  environment: {
1101
1157
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -1113,39 +1169,21 @@ export declare const ProdTaskRunExecutionPayload: z.ZodObject<{
1113
1169
  slug: string;
1114
1170
  ref: string;
1115
1171
  };
1116
- task: {
1117
- id: string;
1118
- filePath: string;
1119
- exportName: string;
1120
- };
1121
- attempt: {
1122
- number: number;
1123
- status: string;
1124
- id: string;
1125
- startedAt: Date;
1126
- backgroundWorkerId: string;
1127
- backgroundWorkerTaskId: string;
1128
- };
1129
- queue: {
1130
- name: string;
1131
- id: string;
1132
- };
1133
1172
  worker: {
1134
- version: string;
1135
1173
  id: string;
1174
+ version: string;
1136
1175
  contentHash: string;
1137
1176
  };
1138
1177
  batch?: {
1139
1178
  id: string;
1140
1179
  } | undefined;
1141
1180
  machine?: {
1142
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
1143
1181
  cpu: number;
1144
1182
  memory: number;
1183
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
1145
1184
  centsPerMs: number;
1146
1185
  } | undefined;
1147
1186
  };
1148
- traceContext: Record<string, unknown>;
1149
1187
  environment?: Record<string, string> | undefined;
1150
1188
  }>;
1151
1189
  export type ProdTaskRunExecutionPayload = z.infer<typeof ProdTaskRunExecutionPayload>;
@@ -1888,12 +1926,12 @@ export declare const TaskMetadata: z.ZodObject<{
1888
1926
  memory: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<0.25>, z.ZodLiteral<0.5>, z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<4>, z.ZodLiteral<8>]>>;
1889
1927
  preset: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
1890
1928
  }, "strip", z.ZodTypeAny, {
1891
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
1892
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
1929
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
1930
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
1893
1931
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
1894
1932
  }, {
1895
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
1896
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
1933
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
1934
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
1897
1935
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
1898
1936
  }>>;
1899
1937
  triggerSource: z.ZodOptional<z.ZodString>;
@@ -1907,6 +1945,7 @@ export declare const TaskMetadata: z.ZodObject<{
1907
1945
  cron: string;
1908
1946
  timezone: string;
1909
1947
  }>>;
1948
+ maxDuration: z.ZodOptional<z.ZodNumber>;
1910
1949
  }, "strip", z.ZodTypeAny, {
1911
1950
  id: string;
1912
1951
  queue?: {
@@ -1954,8 +1993,8 @@ export declare const TaskMetadata: z.ZodObject<{
1954
1993
  randomize?: boolean | undefined;
1955
1994
  } | undefined;
1956
1995
  machine?: {
1957
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
1958
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
1996
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
1997
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
1959
1998
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
1960
1999
  } | undefined;
1961
2000
  triggerSource?: string | undefined;
@@ -1963,6 +2002,7 @@ export declare const TaskMetadata: z.ZodObject<{
1963
2002
  cron: string;
1964
2003
  timezone: string;
1965
2004
  } | undefined;
2005
+ maxDuration?: number | undefined;
1966
2006
  }, {
1967
2007
  id: string;
1968
2008
  queue?: {
@@ -2010,8 +2050,8 @@ export declare const TaskMetadata: z.ZodObject<{
2010
2050
  randomize?: boolean | undefined;
2011
2051
  } | undefined;
2012
2052
  machine?: {
2013
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2014
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2053
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
2054
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
2015
2055
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
2016
2056
  } | undefined;
2017
2057
  triggerSource?: string | undefined;
@@ -2019,6 +2059,7 @@ export declare const TaskMetadata: z.ZodObject<{
2019
2059
  cron: string;
2020
2060
  timezone: string;
2021
2061
  } | undefined;
2062
+ maxDuration?: number | undefined;
2022
2063
  }>;
2023
2064
  export type TaskMetadata = z.infer<typeof TaskMetadata>;
2024
2065
  export declare const TaskFile: z.ZodObject<{
@@ -2306,12 +2347,12 @@ export declare const TaskManifest: z.ZodObject<{
2306
2347
  memory: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<0.25>, z.ZodLiteral<0.5>, z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<4>, z.ZodLiteral<8>]>>;
2307
2348
  preset: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
2308
2349
  }, "strip", z.ZodTypeAny, {
2309
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2310
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2350
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
2351
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
2311
2352
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
2312
2353
  }, {
2313
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2314
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2354
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
2355
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
2315
2356
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
2316
2357
  }>>;
2317
2358
  triggerSource: z.ZodOptional<z.ZodString>;
@@ -2325,6 +2366,7 @@ export declare const TaskManifest: z.ZodObject<{
2325
2366
  cron: string;
2326
2367
  timezone: string;
2327
2368
  }>>;
2369
+ maxDuration: z.ZodOptional<z.ZodNumber>;
2328
2370
  }, "strip", z.ZodTypeAny, {
2329
2371
  id: string;
2330
2372
  filePath: string;
@@ -2375,8 +2417,8 @@ export declare const TaskManifest: z.ZodObject<{
2375
2417
  randomize?: boolean | undefined;
2376
2418
  } | undefined;
2377
2419
  machine?: {
2378
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2379
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2420
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
2421
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
2380
2422
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
2381
2423
  } | undefined;
2382
2424
  triggerSource?: string | undefined;
@@ -2384,6 +2426,7 @@ export declare const TaskManifest: z.ZodObject<{
2384
2426
  cron: string;
2385
2427
  timezone: string;
2386
2428
  } | undefined;
2429
+ maxDuration?: number | undefined;
2387
2430
  }, {
2388
2431
  id: string;
2389
2432
  filePath: string;
@@ -2434,8 +2477,8 @@ export declare const TaskManifest: z.ZodObject<{
2434
2477
  randomize?: boolean | undefined;
2435
2478
  } | undefined;
2436
2479
  machine?: {
2437
- cpu?: 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2438
- memory?: 8 | 1 | 2 | 4 | 0.25 | 0.5 | undefined;
2480
+ cpu?: 2 | 1 | 0.25 | 0.5 | 4 | undefined;
2481
+ memory?: 2 | 1 | 0.25 | 0.5 | 4 | 8 | undefined;
2439
2482
  preset?: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x" | undefined;
2440
2483
  } | undefined;
2441
2484
  triggerSource?: string | undefined;
@@ -2443,6 +2486,7 @@ export declare const TaskManifest: z.ZodObject<{
2443
2486
  cron: string;
2444
2487
  timezone: string;
2445
2488
  } | undefined;
2489
+ maxDuration?: number | undefined;
2446
2490
  }>;
2447
2491
  export type TaskManifest = z.infer<typeof TaskManifest>;
2448
2492
  export declare const PostStartCauses: z.ZodEnum<["index", "create", "restore"]>;
@@ -2573,16 +2617,16 @@ export declare const TaskRunExecutionLazyAttemptPayload: z.ZodObject<{
2573
2617
  environment: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
2574
2618
  }, "strip", z.ZodTypeAny, {
2575
2619
  isTest: boolean;
2576
- traceContext: Record<string, unknown>;
2577
2620
  runId: string;
2578
2621
  messageId: string;
2622
+ traceContext: Record<string, unknown>;
2579
2623
  attemptCount?: number | undefined;
2580
2624
  environment?: Record<string, string> | undefined;
2581
2625
  }, {
2582
2626
  isTest: boolean;
2583
- traceContext: Record<string, unknown>;
2584
2627
  runId: string;
2585
2628
  messageId: string;
2629
+ traceContext: Record<string, unknown>;
2586
2630
  attemptCount?: number | undefined;
2587
2631
  environment?: Record<string, string> | undefined;
2588
2632
  }>;