@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
@@ -173,7 +173,7 @@ function isRecord(value) {
173
173
  __name(isRecord, "isRecord");
174
174
 
175
175
  // package.json
176
- var version = "3.0.0-beta.49";
176
+ var version = "3.0.0-beta.50";
177
177
  var MachineCpu = z.union([
178
178
  z.literal(0.25),
179
179
  z.literal(0.5),
@@ -487,13 +487,18 @@ var QueueOptions = z.object({
487
487
  /** @deprecated This feature is coming soon */
488
488
  rateLimit: RateLimitOptions.optional()
489
489
  });
490
+ var ScheduleMetadata = z.object({
491
+ cron: z.string(),
492
+ timezone: z.string()
493
+ });
490
494
  z.object({
491
495
  id: z.string(),
492
496
  packageVersion: z.string(),
493
497
  queue: QueueOptions.optional(),
494
498
  retry: RetryOptions.optional(),
495
499
  machine: MachineConfig.optional(),
496
- triggerSource: z.string().optional()
500
+ triggerSource: z.string().optional(),
501
+ schedule: ScheduleMetadata.optional()
497
502
  });
498
503
  z.object({
499
504
  filePath: z.string(),
@@ -506,6 +511,7 @@ z.object({
506
511
  retry: RetryOptions.optional(),
507
512
  machine: MachineConfig.optional(),
508
513
  triggerSource: z.string().optional(),
514
+ schedule: ScheduleMetadata.optional(),
509
515
  filePath: z.string(),
510
516
  exportName: z.string()
511
517
  });
@@ -567,7 +573,8 @@ var TaskResource = z.object({
567
573
  queue: QueueOptions.optional(),
568
574
  retry: RetryOptions.optional(),
569
575
  machine: MachineConfig.optional(),
570
- triggerSource: z.string().optional()
576
+ triggerSource: z.string().optional(),
577
+ schedule: ScheduleMetadata.optional()
571
578
  });
572
579
  var BackgroundWorkerMetadata = z.object({
573
580
  packageVersion: z.string(),
@@ -735,10 +742,21 @@ var ReplayRunResponse = z.object({
735
742
  var CanceledRunResponse = z.object({
736
743
  id: z.string()
737
744
  });
745
+ var ScheduleType = z.union([
746
+ z.literal("DECLARATIVE"),
747
+ z.literal("IMPERATIVE")
748
+ ]);
738
749
  z.object({
739
750
  /** The schedule id associated with this run (you can have many schedules for the same task).
740
751
  You can use this to remove the schedule, update it, etc */
741
752
  scheduleId: z.string(),
753
+ /** The type of schedule – `"DECLARATIVE"` or `"IMPERATIVE"`.
754
+ *
755
+ * **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.
756
+ *
757
+ * **IMPERATIVE** – created using the `schedules.create` functions or in the dashboard.
758
+ */
759
+ type: ScheduleType,
742
760
  /** When the task was scheduled to run.
743
761
  * Note this will be slightly different from `new Date()` because it takes a few ms to run the task.
744
762
  *
@@ -814,6 +832,7 @@ var ScheduleGenerator = z.object({
814
832
  });
815
833
  var ScheduleObject = z.object({
816
834
  id: z.string(),
835
+ type: ScheduleType,
817
836
  task: z.string(),
818
837
  active: z.boolean(),
819
838
  deduplicationKey: z.string().nullish(),