@trigger.dev/core 3.0.0-beta.49 → 3.0.0-beta.50

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 (39) hide show
  1. package/dist/{catalog-U7_q4XsM.d.mts → catalog-H7yFiZ60.d.mts} +1 -1
  2. package/dist/{catalog-bSnBE19I.d.ts → catalog-h79CG5Wy.d.ts} +1 -1
  3. package/dist/{messages-I-h-zZN9.d.mts → messages-JvHJ83wv.d.mts} +172 -0
  4. package/dist/{messages-I-h-zZN9.d.ts → messages-JvHJ83wv.d.ts} +172 -0
  5. package/dist/{schemas-WHkFakb3.d.mts → schemas-C9ssfehv.d.mts} +47 -1
  6. package/dist/{schemas-WHkFakb3.d.ts → schemas-C9ssfehv.d.ts} +47 -1
  7. package/dist/v3/index.d.mts +15 -7
  8. package/dist/v3/index.d.ts +15 -7
  9. package/dist/v3/index.js +24 -3
  10. package/dist/v3/index.js.map +1 -1
  11. package/dist/v3/index.mjs +23 -4
  12. package/dist/v3/index.mjs.map +1 -1
  13. package/dist/v3/otel/index.js +1 -1
  14. package/dist/v3/otel/index.js.map +1 -1
  15. package/dist/v3/otel/index.mjs +1 -1
  16. package/dist/v3/otel/index.mjs.map +1 -1
  17. package/dist/v3/prod/index.d.mts +1 -1
  18. package/dist/v3/prod/index.d.ts +1 -1
  19. package/dist/v3/schemas/index.d.mts +100 -4
  20. package/dist/v3/schemas/index.d.ts +100 -4
  21. package/dist/v3/schemas/index.js +23 -2
  22. package/dist/v3/schemas/index.js.map +1 -1
  23. package/dist/v3/schemas/index.mjs +22 -3
  24. package/dist/v3/schemas/index.mjs.map +1 -1
  25. package/dist/v3/utils/ioSerialization.js +22 -3
  26. package/dist/v3/utils/ioSerialization.js.map +1 -1
  27. package/dist/v3/utils/ioSerialization.mjs +22 -3
  28. package/dist/v3/utils/ioSerialization.mjs.map +1 -1
  29. package/dist/v3/utils/retries.d.mts +1 -1
  30. package/dist/v3/utils/retries.d.ts +1 -1
  31. package/dist/v3/workers/index.d.mts +4 -4
  32. package/dist/v3/workers/index.d.ts +4 -4
  33. package/dist/v3/workers/index.js +22 -3
  34. package/dist/v3/workers/index.js.map +1 -1
  35. package/dist/v3/workers/index.mjs +22 -3
  36. package/dist/v3/workers/index.mjs.map +1 -1
  37. package/dist/v3/zodfetch.d.mts +1 -1
  38. package/dist/v3/zodfetch.d.ts +1 -1
  39. package/package.json +1 -1
@@ -175,7 +175,7 @@ function isRecord(value) {
175
175
  __name(isRecord, "isRecord");
176
176
 
177
177
  // package.json
178
- var version = "3.0.0-beta.49";
178
+ var version = "3.0.0-beta.50";
179
179
  var MachineCpu = zod.z.union([
180
180
  zod.z.literal(0.25),
181
181
  zod.z.literal(0.5),
@@ -489,13 +489,18 @@ var QueueOptions = zod.z.object({
489
489
  /** @deprecated This feature is coming soon */
490
490
  rateLimit: RateLimitOptions.optional()
491
491
  });
492
+ var ScheduleMetadata = zod.z.object({
493
+ cron: zod.z.string(),
494
+ timezone: zod.z.string()
495
+ });
492
496
  zod.z.object({
493
497
  id: zod.z.string(),
494
498
  packageVersion: zod.z.string(),
495
499
  queue: QueueOptions.optional(),
496
500
  retry: RetryOptions.optional(),
497
501
  machine: MachineConfig.optional(),
498
- triggerSource: zod.z.string().optional()
502
+ triggerSource: zod.z.string().optional(),
503
+ schedule: ScheduleMetadata.optional()
499
504
  });
500
505
  zod.z.object({
501
506
  filePath: zod.z.string(),
@@ -508,6 +513,7 @@ zod.z.object({
508
513
  retry: RetryOptions.optional(),
509
514
  machine: MachineConfig.optional(),
510
515
  triggerSource: zod.z.string().optional(),
516
+ schedule: ScheduleMetadata.optional(),
511
517
  filePath: zod.z.string(),
512
518
  exportName: zod.z.string()
513
519
  });
@@ -569,7 +575,8 @@ var TaskResource = zod.z.object({
569
575
  queue: QueueOptions.optional(),
570
576
  retry: RetryOptions.optional(),
571
577
  machine: MachineConfig.optional(),
572
- triggerSource: zod.z.string().optional()
578
+ triggerSource: zod.z.string().optional(),
579
+ schedule: ScheduleMetadata.optional()
573
580
  });
574
581
  var BackgroundWorkerMetadata = zod.z.object({
575
582
  packageVersion: zod.z.string(),
@@ -737,10 +744,21 @@ var ReplayRunResponse = zod.z.object({
737
744
  var CanceledRunResponse = zod.z.object({
738
745
  id: zod.z.string()
739
746
  });
747
+ var ScheduleType = zod.z.union([
748
+ zod.z.literal("DECLARATIVE"),
749
+ zod.z.literal("IMPERATIVE")
750
+ ]);
740
751
  zod.z.object({
741
752
  /** The schedule id associated with this run (you can have many schedules for the same task).
742
753
  You can use this to remove the schedule, update it, etc */
743
754
  scheduleId: zod.z.string(),
755
+ /** The type of schedule – `"DECLARATIVE"` or `"IMPERATIVE"`.
756
+ *
757
+ * **DECLARATIVE** – defined inline on your `schedules.task` using the `cron` property. They can only be created, updated or deleted by modifying the `cron` property on your task.
758
+ *
759
+ * **IMPERATIVE** – created using the `schedules.create` functions or in the dashboard.
760
+ */
761
+ type: ScheduleType,
744
762
  /** When the task was scheduled to run.
745
763
  * Note this will be slightly different from `new Date()` because it takes a few ms to run the task.
746
764
  *
@@ -816,6 +834,7 @@ var ScheduleGenerator = zod.z.object({
816
834
  });
817
835
  var ScheduleObject = zod.z.object({
818
836
  id: zod.z.string(),
837
+ type: ScheduleType,
819
838
  task: zod.z.string(),
820
839
  active: zod.z.boolean(),
821
840
  deduplicationKey: zod.z.string().nullish(),