@trigger.dev/core 0.0.0-prerelease-20251215135620 → 0.0.0-prerelease-20260120115202

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 (117) hide show
  1. package/dist/commonjs/v3/apiClient/index.d.ts +3 -0
  2. package/dist/commonjs/v3/apiClient/index.js +7 -0
  3. package/dist/commonjs/v3/apiClient/index.js.map +1 -1
  4. package/dist/commonjs/v3/idempotency-key-catalog/catalog.d.ts +9 -0
  5. package/dist/commonjs/v3/idempotency-key-catalog/catalog.js +3 -0
  6. package/dist/commonjs/v3/idempotency-key-catalog/catalog.js.map +1 -0
  7. package/dist/commonjs/v3/idempotency-key-catalog/index.d.ts +9 -0
  8. package/dist/commonjs/v3/idempotency-key-catalog/index.js +33 -0
  9. package/dist/commonjs/v3/idempotency-key-catalog/index.js.map +1 -0
  10. package/dist/commonjs/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.d.ts +8 -0
  11. package/dist/commonjs/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.js +35 -0
  12. package/dist/commonjs/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.js.map +1 -0
  13. package/dist/commonjs/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.test.d.ts +1 -0
  14. package/dist/commonjs/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.test.js +161 -0
  15. package/dist/commonjs/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.test.js.map +1 -0
  16. package/dist/commonjs/v3/idempotency-key-catalog-api.d.ts +3 -0
  17. package/dist/commonjs/v3/idempotency-key-catalog-api.js +9 -0
  18. package/dist/commonjs/v3/idempotency-key-catalog-api.js.map +1 -0
  19. package/dist/commonjs/v3/idempotencyKeys.d.ts +54 -2
  20. package/dist/commonjs/v3/idempotencyKeys.js +101 -2
  21. package/dist/commonjs/v3/idempotencyKeys.js.map +1 -1
  22. package/dist/commonjs/v3/imports/superjson-cjs.cjs.map +1 -0
  23. package/dist/commonjs/v3/imports/superjson.d.ts +1 -0
  24. package/dist/commonjs/v3/imports/superjson.js +13 -0
  25. package/dist/commonjs/v3/runEngineWorker/supervisor/http.d.ts +61 -60
  26. package/dist/commonjs/v3/runEngineWorker/supervisor/schemas.d.ts +191 -184
  27. package/dist/commonjs/v3/runEngineWorker/workload/http.d.ts +46 -45
  28. package/dist/commonjs/v3/runEngineWorker/workload/schemas.d.ts +163 -156
  29. package/dist/commonjs/v3/schemas/api.d.ts +449 -56
  30. package/dist/commonjs/v3/schemas/api.js +31 -3
  31. package/dist/commonjs/v3/schemas/api.js.map +1 -1
  32. package/dist/commonjs/v3/schemas/checkpoints.d.ts +66 -66
  33. package/dist/commonjs/v3/schemas/common.d.ts +215 -177
  34. package/dist/commonjs/v3/schemas/common.js +6 -0
  35. package/dist/commonjs/v3/schemas/common.js.map +1 -1
  36. package/dist/commonjs/v3/schemas/messages.d.ts +2149 -2032
  37. package/dist/commonjs/v3/schemas/runEngine.d.ts +158 -150
  38. package/dist/commonjs/v3/schemas/runEngine.js +1 -0
  39. package/dist/commonjs/v3/schemas/runEngine.js.map +1 -1
  40. package/dist/commonjs/v3/schemas/schemas.d.ts +281 -262
  41. package/dist/commonjs/v3/schemas/webhooks.d.ts +68 -68
  42. package/dist/commonjs/v3/serverOnly/idempotencyKeys.d.ts +36 -0
  43. package/dist/commonjs/v3/serverOnly/idempotencyKeys.js +58 -0
  44. package/dist/commonjs/v3/serverOnly/idempotencyKeys.js.map +1 -0
  45. package/dist/commonjs/v3/serverOnly/index.d.ts +1 -0
  46. package/dist/commonjs/v3/serverOnly/index.js +1 -0
  47. package/dist/commonjs/v3/serverOnly/index.js.map +1 -1
  48. package/dist/commonjs/v3/types/tasks.d.ts +49 -0
  49. package/dist/commonjs/v3/utils/flattenAttributes.d.ts +2 -2
  50. package/dist/commonjs/v3/utils/flattenAttributes.js +24 -13
  51. package/dist/commonjs/v3/utils/flattenAttributes.js.map +1 -1
  52. package/dist/commonjs/v3/utils/globals.d.ts +2 -0
  53. package/dist/commonjs/v3/utils/globals.js.map +1 -1
  54. package/dist/commonjs/v3/utils/ioSerialization.js +15 -27
  55. package/dist/commonjs/v3/utils/ioSerialization.js.map +1 -1
  56. package/dist/commonjs/v3/zodSocket.js +1 -1
  57. package/dist/commonjs/v3/zodSocket.js.map +1 -1
  58. package/dist/commonjs/version.js +1 -1
  59. package/dist/esm/v3/apiClient/index.d.ts +3 -0
  60. package/dist/esm/v3/apiClient/index.js +8 -1
  61. package/dist/esm/v3/apiClient/index.js.map +1 -1
  62. package/dist/esm/v3/idempotency-key-catalog/catalog.d.ts +9 -0
  63. package/dist/esm/v3/idempotency-key-catalog/catalog.js +2 -0
  64. package/dist/esm/v3/idempotency-key-catalog/catalog.js.map +1 -0
  65. package/dist/esm/v3/idempotency-key-catalog/index.d.ts +9 -0
  66. package/dist/esm/v3/idempotency-key-catalog/index.js +29 -0
  67. package/dist/esm/v3/idempotency-key-catalog/index.js.map +1 -0
  68. package/dist/esm/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.d.ts +8 -0
  69. package/dist/esm/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.js +31 -0
  70. package/dist/esm/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.js.map +1 -0
  71. package/dist/esm/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.test.d.ts +1 -0
  72. package/dist/esm/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.test.js +159 -0
  73. package/dist/esm/v3/idempotency-key-catalog/lruIdempotencyKeyCatalog.test.js.map +1 -0
  74. package/dist/esm/v3/idempotency-key-catalog-api.d.ts +3 -0
  75. package/dist/esm/v3/idempotency-key-catalog-api.js +6 -0
  76. package/dist/esm/v3/idempotency-key-catalog-api.js.map +1 -0
  77. package/dist/esm/v3/idempotencyKeys.d.ts +54 -2
  78. package/dist/esm/v3/idempotencyKeys.js +99 -2
  79. package/dist/esm/v3/idempotencyKeys.js.map +1 -1
  80. package/dist/esm/v3/imports/superjson.d.ts +2 -0
  81. package/dist/esm/v3/imports/superjson.js +10 -0
  82. package/dist/esm/v3/imports/superjson.js.map +1 -0
  83. package/dist/esm/v3/runEngineWorker/supervisor/http.d.ts +61 -60
  84. package/dist/esm/v3/runEngineWorker/supervisor/schemas.d.ts +191 -184
  85. package/dist/esm/v3/runEngineWorker/workload/http.d.ts +46 -45
  86. package/dist/esm/v3/runEngineWorker/workload/schemas.d.ts +163 -156
  87. package/dist/esm/v3/schemas/api.d.ts +449 -56
  88. package/dist/esm/v3/schemas/api.js +28 -0
  89. package/dist/esm/v3/schemas/api.js.map +1 -1
  90. package/dist/esm/v3/schemas/checkpoints.d.ts +66 -66
  91. package/dist/esm/v3/schemas/common.d.ts +215 -177
  92. package/dist/esm/v3/schemas/common.js +6 -0
  93. package/dist/esm/v3/schemas/common.js.map +1 -1
  94. package/dist/esm/v3/schemas/messages.d.ts +2149 -2032
  95. package/dist/esm/v3/schemas/runEngine.d.ts +158 -150
  96. package/dist/esm/v3/schemas/runEngine.js +1 -0
  97. package/dist/esm/v3/schemas/runEngine.js.map +1 -1
  98. package/dist/esm/v3/schemas/schemas.d.ts +281 -262
  99. package/dist/esm/v3/schemas/webhooks.d.ts +68 -68
  100. package/dist/esm/v3/serverOnly/idempotencyKeys.d.ts +36 -0
  101. package/dist/esm/v3/serverOnly/idempotencyKeys.js +51 -0
  102. package/dist/esm/v3/serverOnly/idempotencyKeys.js.map +1 -0
  103. package/dist/esm/v3/serverOnly/index.d.ts +1 -0
  104. package/dist/esm/v3/serverOnly/index.js +1 -0
  105. package/dist/esm/v3/serverOnly/index.js.map +1 -1
  106. package/dist/esm/v3/types/tasks.d.ts +49 -0
  107. package/dist/esm/v3/utils/flattenAttributes.d.ts +2 -2
  108. package/dist/esm/v3/utils/flattenAttributes.js +24 -13
  109. package/dist/esm/v3/utils/flattenAttributes.js.map +1 -1
  110. package/dist/esm/v3/utils/globals.d.ts +2 -0
  111. package/dist/esm/v3/utils/globals.js.map +1 -1
  112. package/dist/esm/v3/utils/ioSerialization.js +9 -24
  113. package/dist/esm/v3/utils/ioSerialization.js.map +1 -1
  114. package/dist/esm/v3/zodSocket.js +1 -1
  115. package/dist/esm/v3/zodSocket.js.map +1 -1
  116. package/dist/esm/version.js +1 -1
  117. package/package.json +1 -1
@@ -740,6 +740,18 @@ export declare const CreateBackgroundWorkerResponse: z.ZodObject<{
740
740
  export type CreateBackgroundWorkerResponse = z.infer<typeof CreateBackgroundWorkerResponse>;
741
741
  export declare const RunTags: z.ZodUnion<[z.ZodString, z.ZodArray<z.ZodString, "many">]>;
742
742
  export type RunTags = z.infer<typeof RunTags>;
743
+ /** Stores the original user-provided idempotency key and scope */
744
+ export declare const IdempotencyKeyOptionsSchema: z.ZodObject<{
745
+ key: z.ZodString;
746
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
747
+ }, "strip", z.ZodTypeAny, {
748
+ key: string;
749
+ scope: "run" | "attempt" | "global";
750
+ }, {
751
+ key: string;
752
+ scope: "run" | "attempt" | "global";
753
+ }>;
754
+ export type IdempotencyKeyOptionsSchema = z.infer<typeof IdempotencyKeyOptionsSchema>;
743
755
  export declare const TriggerTaskRequestBody: z.ZodObject<{
744
756
  payload: z.ZodAny;
745
757
  context: z.ZodAny;
@@ -783,6 +795,17 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
783
795
  delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
784
796
  idempotencyKey: z.ZodOptional<z.ZodString>;
785
797
  idempotencyKeyTTL: z.ZodOptional<z.ZodString>;
798
+ /** The original user-provided idempotency key and scope */
799
+ idempotencyKeyOptions: z.ZodOptional<z.ZodObject<{
800
+ key: z.ZodString;
801
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
802
+ }, "strip", z.ZodTypeAny, {
803
+ key: string;
804
+ scope: "run" | "attempt" | "global";
805
+ }, {
806
+ key: string;
807
+ scope: "run" | "attempt" | "global";
808
+ }>>;
786
809
  machine: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
787
810
  maxAttempts: z.ZodOptional<z.ZodNumber>;
788
811
  maxDuration: z.ZodOptional<z.ZodNumber>;
@@ -795,6 +818,19 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
795
818
  priority: z.ZodOptional<z.ZodNumber>;
796
819
  bulkActionId: z.ZodOptional<z.ZodString>;
797
820
  region: z.ZodOptional<z.ZodString>;
821
+ debounce: z.ZodOptional<z.ZodObject<{
822
+ key: z.ZodString;
823
+ delay: z.ZodString;
824
+ mode: z.ZodOptional<z.ZodEnum<["leading", "trailing"]>>;
825
+ }, "strip", z.ZodTypeAny, {
826
+ key: string;
827
+ delay: string;
828
+ mode?: "leading" | "trailing" | undefined;
829
+ }, {
830
+ key: string;
831
+ delay: string;
832
+ mode?: "leading" | "trailing" | undefined;
833
+ }>>;
798
834
  }, "strip", z.ZodTypeAny, {
799
835
  metadata?: any;
800
836
  payloadType?: string | undefined;
@@ -813,6 +849,11 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
813
849
  idempotencyKeyTTL?: string | undefined;
814
850
  concurrencyKey?: string | undefined;
815
851
  ttl?: string | number | undefined;
852
+ debounce?: {
853
+ key: string;
854
+ delay: string;
855
+ mode?: "leading" | "trailing" | undefined;
856
+ } | undefined;
816
857
  dependentAttempt?: string | undefined;
817
858
  parentAttempt?: string | undefined;
818
859
  dependentBatch?: string | undefined;
@@ -820,6 +861,10 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
820
861
  parentRunId?: string | undefined;
821
862
  resumeParentOnCompletion?: boolean | undefined;
822
863
  lockToVersion?: string | undefined;
864
+ idempotencyKeyOptions?: {
865
+ key: string;
866
+ scope: "run" | "attempt" | "global";
867
+ } | undefined;
823
868
  metadataType?: string | undefined;
824
869
  test?: boolean | undefined;
825
870
  bulkActionId?: string | undefined;
@@ -841,6 +886,11 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
841
886
  idempotencyKeyTTL?: string | undefined;
842
887
  concurrencyKey?: string | undefined;
843
888
  ttl?: string | number | undefined;
889
+ debounce?: {
890
+ key: string;
891
+ delay: string;
892
+ mode?: "leading" | "trailing" | undefined;
893
+ } | undefined;
844
894
  dependentAttempt?: string | undefined;
845
895
  parentAttempt?: string | undefined;
846
896
  dependentBatch?: string | undefined;
@@ -848,6 +898,10 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
848
898
  parentRunId?: string | undefined;
849
899
  resumeParentOnCompletion?: boolean | undefined;
850
900
  lockToVersion?: string | undefined;
901
+ idempotencyKeyOptions?: {
902
+ key: string;
903
+ scope: "run" | "attempt" | "global";
904
+ } | undefined;
851
905
  metadataType?: string | undefined;
852
906
  test?: boolean | undefined;
853
907
  bulkActionId?: string | undefined;
@@ -871,6 +925,11 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
871
925
  idempotencyKeyTTL?: string | undefined;
872
926
  concurrencyKey?: string | undefined;
873
927
  ttl?: string | number | undefined;
928
+ debounce?: {
929
+ key: string;
930
+ delay: string;
931
+ mode?: "leading" | "trailing" | undefined;
932
+ } | undefined;
874
933
  dependentAttempt?: string | undefined;
875
934
  parentAttempt?: string | undefined;
876
935
  dependentBatch?: string | undefined;
@@ -878,6 +937,10 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
878
937
  parentRunId?: string | undefined;
879
938
  resumeParentOnCompletion?: boolean | undefined;
880
939
  lockToVersion?: string | undefined;
940
+ idempotencyKeyOptions?: {
941
+ key: string;
942
+ scope: "run" | "attempt" | "global";
943
+ } | undefined;
881
944
  metadataType?: string | undefined;
882
945
  test?: boolean | undefined;
883
946
  bulkActionId?: string | undefined;
@@ -903,6 +966,11 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
903
966
  idempotencyKeyTTL?: string | undefined;
904
967
  concurrencyKey?: string | undefined;
905
968
  ttl?: string | number | undefined;
969
+ debounce?: {
970
+ key: string;
971
+ delay: string;
972
+ mode?: "leading" | "trailing" | undefined;
973
+ } | undefined;
906
974
  dependentAttempt?: string | undefined;
907
975
  parentAttempt?: string | undefined;
908
976
  dependentBatch?: string | undefined;
@@ -910,6 +978,10 @@ export declare const TriggerTaskRequestBody: z.ZodObject<{
910
978
  parentRunId?: string | undefined;
911
979
  resumeParentOnCompletion?: boolean | undefined;
912
980
  lockToVersion?: string | undefined;
981
+ idempotencyKeyOptions?: {
982
+ key: string;
983
+ scope: "run" | "attempt" | "global";
984
+ } | undefined;
913
985
  metadataType?: string | undefined;
914
986
  test?: boolean | undefined;
915
987
  bulkActionId?: string | undefined;
@@ -973,6 +1045,17 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
973
1045
  delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
974
1046
  idempotencyKey: z.ZodOptional<z.ZodString>;
975
1047
  idempotencyKeyTTL: z.ZodOptional<z.ZodString>;
1048
+ /** The original user-provided idempotency key and scope */
1049
+ idempotencyKeyOptions: z.ZodOptional<z.ZodObject<{
1050
+ key: z.ZodString;
1051
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
1052
+ }, "strip", z.ZodTypeAny, {
1053
+ key: string;
1054
+ scope: "run" | "attempt" | "global";
1055
+ }, {
1056
+ key: string;
1057
+ scope: "run" | "attempt" | "global";
1058
+ }>>;
976
1059
  machine: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
977
1060
  maxAttempts: z.ZodOptional<z.ZodNumber>;
978
1061
  maxDuration: z.ZodOptional<z.ZodNumber>;
@@ -985,6 +1068,19 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
985
1068
  priority: z.ZodOptional<z.ZodNumber>;
986
1069
  bulkActionId: z.ZodOptional<z.ZodString>;
987
1070
  region: z.ZodOptional<z.ZodString>;
1071
+ debounce: z.ZodOptional<z.ZodObject<{
1072
+ key: z.ZodString;
1073
+ delay: z.ZodString;
1074
+ mode: z.ZodOptional<z.ZodEnum<["leading", "trailing"]>>;
1075
+ }, "strip", z.ZodTypeAny, {
1076
+ key: string;
1077
+ delay: string;
1078
+ mode?: "leading" | "trailing" | undefined;
1079
+ }, {
1080
+ key: string;
1081
+ delay: string;
1082
+ mode?: "leading" | "trailing" | undefined;
1083
+ }>>;
988
1084
  }, "strip", z.ZodTypeAny, {
989
1085
  metadata?: any;
990
1086
  payloadType?: string | undefined;
@@ -1003,6 +1099,11 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1003
1099
  idempotencyKeyTTL?: string | undefined;
1004
1100
  concurrencyKey?: string | undefined;
1005
1101
  ttl?: string | number | undefined;
1102
+ debounce?: {
1103
+ key: string;
1104
+ delay: string;
1105
+ mode?: "leading" | "trailing" | undefined;
1106
+ } | undefined;
1006
1107
  dependentAttempt?: string | undefined;
1007
1108
  parentAttempt?: string | undefined;
1008
1109
  dependentBatch?: string | undefined;
@@ -1010,6 +1111,10 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1010
1111
  parentRunId?: string | undefined;
1011
1112
  resumeParentOnCompletion?: boolean | undefined;
1012
1113
  lockToVersion?: string | undefined;
1114
+ idempotencyKeyOptions?: {
1115
+ key: string;
1116
+ scope: "run" | "attempt" | "global";
1117
+ } | undefined;
1013
1118
  metadataType?: string | undefined;
1014
1119
  test?: boolean | undefined;
1015
1120
  bulkActionId?: string | undefined;
@@ -1031,6 +1136,11 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1031
1136
  idempotencyKeyTTL?: string | undefined;
1032
1137
  concurrencyKey?: string | undefined;
1033
1138
  ttl?: string | number | undefined;
1139
+ debounce?: {
1140
+ key: string;
1141
+ delay: string;
1142
+ mode?: "leading" | "trailing" | undefined;
1143
+ } | undefined;
1034
1144
  dependentAttempt?: string | undefined;
1035
1145
  parentAttempt?: string | undefined;
1036
1146
  dependentBatch?: string | undefined;
@@ -1038,6 +1148,10 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1038
1148
  parentRunId?: string | undefined;
1039
1149
  resumeParentOnCompletion?: boolean | undefined;
1040
1150
  lockToVersion?: string | undefined;
1151
+ idempotencyKeyOptions?: {
1152
+ key: string;
1153
+ scope: "run" | "attempt" | "global";
1154
+ } | undefined;
1041
1155
  metadataType?: string | undefined;
1042
1156
  test?: boolean | undefined;
1043
1157
  bulkActionId?: string | undefined;
@@ -1061,6 +1175,11 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1061
1175
  idempotencyKeyTTL?: string | undefined;
1062
1176
  concurrencyKey?: string | undefined;
1063
1177
  ttl?: string | number | undefined;
1178
+ debounce?: {
1179
+ key: string;
1180
+ delay: string;
1181
+ mode?: "leading" | "trailing" | undefined;
1182
+ } | undefined;
1064
1183
  dependentAttempt?: string | undefined;
1065
1184
  parentAttempt?: string | undefined;
1066
1185
  dependentBatch?: string | undefined;
@@ -1068,6 +1187,10 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1068
1187
  parentRunId?: string | undefined;
1069
1188
  resumeParentOnCompletion?: boolean | undefined;
1070
1189
  lockToVersion?: string | undefined;
1190
+ idempotencyKeyOptions?: {
1191
+ key: string;
1192
+ scope: "run" | "attempt" | "global";
1193
+ } | undefined;
1071
1194
  metadataType?: string | undefined;
1072
1195
  test?: boolean | undefined;
1073
1196
  bulkActionId?: string | undefined;
@@ -1093,6 +1216,11 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1093
1216
  idempotencyKeyTTL?: string | undefined;
1094
1217
  concurrencyKey?: string | undefined;
1095
1218
  ttl?: string | number | undefined;
1219
+ debounce?: {
1220
+ key: string;
1221
+ delay: string;
1222
+ mode?: "leading" | "trailing" | undefined;
1223
+ } | undefined;
1096
1224
  dependentAttempt?: string | undefined;
1097
1225
  parentAttempt?: string | undefined;
1098
1226
  dependentBatch?: string | undefined;
@@ -1100,6 +1228,10 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1100
1228
  parentRunId?: string | undefined;
1101
1229
  resumeParentOnCompletion?: boolean | undefined;
1102
1230
  lockToVersion?: string | undefined;
1231
+ idempotencyKeyOptions?: {
1232
+ key: string;
1233
+ scope: "run" | "attempt" | "global";
1234
+ } | undefined;
1103
1235
  metadataType?: string | undefined;
1104
1236
  test?: boolean | undefined;
1105
1237
  bulkActionId?: string | undefined;
@@ -1128,6 +1260,11 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1128
1260
  idempotencyKeyTTL?: string | undefined;
1129
1261
  concurrencyKey?: string | undefined;
1130
1262
  ttl?: string | number | undefined;
1263
+ debounce?: {
1264
+ key: string;
1265
+ delay: string;
1266
+ mode?: "leading" | "trailing" | undefined;
1267
+ } | undefined;
1131
1268
  dependentAttempt?: string | undefined;
1132
1269
  parentAttempt?: string | undefined;
1133
1270
  dependentBatch?: string | undefined;
@@ -1135,6 +1272,10 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1135
1272
  parentRunId?: string | undefined;
1136
1273
  resumeParentOnCompletion?: boolean | undefined;
1137
1274
  lockToVersion?: string | undefined;
1275
+ idempotencyKeyOptions?: {
1276
+ key: string;
1277
+ scope: "run" | "attempt" | "global";
1278
+ } | undefined;
1138
1279
  metadataType?: string | undefined;
1139
1280
  test?: boolean | undefined;
1140
1281
  bulkActionId?: string | undefined;
@@ -1163,6 +1304,11 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1163
1304
  idempotencyKeyTTL?: string | undefined;
1164
1305
  concurrencyKey?: string | undefined;
1165
1306
  ttl?: string | number | undefined;
1307
+ debounce?: {
1308
+ key: string;
1309
+ delay: string;
1310
+ mode?: "leading" | "trailing" | undefined;
1311
+ } | undefined;
1166
1312
  dependentAttempt?: string | undefined;
1167
1313
  parentAttempt?: string | undefined;
1168
1314
  dependentBatch?: string | undefined;
@@ -1170,6 +1316,10 @@ export declare const BatchTriggerTaskRequestBody: z.ZodObject<{
1170
1316
  parentRunId?: string | undefined;
1171
1317
  resumeParentOnCompletion?: boolean | undefined;
1172
1318
  lockToVersion?: string | undefined;
1319
+ idempotencyKeyOptions?: {
1320
+ key: string;
1321
+ scope: "run" | "attempt" | "global";
1322
+ } | undefined;
1173
1323
  metadataType?: string | undefined;
1174
1324
  test?: boolean | undefined;
1175
1325
  bulkActionId?: string | undefined;
@@ -1189,6 +1339,17 @@ export declare const BatchTriggerTaskItem: z.ZodObject<{
1189
1339
  delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
1190
1340
  idempotencyKey: z.ZodOptional<z.ZodString>;
1191
1341
  idempotencyKeyTTL: z.ZodOptional<z.ZodString>;
1342
+ /** The original user-provided idempotency key and scope */
1343
+ idempotencyKeyOptions: z.ZodOptional<z.ZodObject<{
1344
+ key: z.ZodString;
1345
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
1346
+ }, "strip", z.ZodTypeAny, {
1347
+ key: string;
1348
+ scope: "run" | "attempt" | "global";
1349
+ }, {
1350
+ key: string;
1351
+ scope: "run" | "attempt" | "global";
1352
+ }>>;
1192
1353
  lockToVersion: z.ZodOptional<z.ZodString>;
1193
1354
  machine: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
1194
1355
  maxAttempts: z.ZodOptional<z.ZodNumber>;
@@ -1209,6 +1370,19 @@ export declare const BatchTriggerTaskItem: z.ZodObject<{
1209
1370
  ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
1210
1371
  priority: z.ZodOptional<z.ZodNumber>;
1211
1372
  region: z.ZodOptional<z.ZodString>;
1373
+ debounce: z.ZodOptional<z.ZodObject<{
1374
+ key: z.ZodString;
1375
+ delay: z.ZodString;
1376
+ mode: z.ZodOptional<z.ZodEnum<["leading", "trailing"]>>;
1377
+ }, "strip", z.ZodTypeAny, {
1378
+ key: string;
1379
+ delay: string;
1380
+ mode?: "leading" | "trailing" | undefined;
1381
+ }, {
1382
+ key: string;
1383
+ delay: string;
1384
+ mode?: "leading" | "trailing" | undefined;
1385
+ }>>;
1212
1386
  }, "strip", z.ZodTypeAny, {
1213
1387
  metadata?: any;
1214
1388
  payloadType?: string | undefined;
@@ -1226,8 +1400,17 @@ export declare const BatchTriggerTaskItem: z.ZodObject<{
1226
1400
  idempotencyKeyTTL?: string | undefined;
1227
1401
  concurrencyKey?: string | undefined;
1228
1402
  ttl?: string | number | undefined;
1403
+ debounce?: {
1404
+ key: string;
1405
+ delay: string;
1406
+ mode?: "leading" | "trailing" | undefined;
1407
+ } | undefined;
1229
1408
  parentAttempt?: string | undefined;
1230
1409
  lockToVersion?: string | undefined;
1410
+ idempotencyKeyOptions?: {
1411
+ key: string;
1412
+ scope: "run" | "attempt" | "global";
1413
+ } | undefined;
1231
1414
  metadataType?: string | undefined;
1232
1415
  test?: boolean | undefined;
1233
1416
  }, {
@@ -1247,8 +1430,17 @@ export declare const BatchTriggerTaskItem: z.ZodObject<{
1247
1430
  idempotencyKeyTTL?: string | undefined;
1248
1431
  concurrencyKey?: string | undefined;
1249
1432
  ttl?: string | number | undefined;
1433
+ debounce?: {
1434
+ key: string;
1435
+ delay: string;
1436
+ mode?: "leading" | "trailing" | undefined;
1437
+ } | undefined;
1250
1438
  parentAttempt?: string | undefined;
1251
1439
  lockToVersion?: string | undefined;
1440
+ idempotencyKeyOptions?: {
1441
+ key: string;
1442
+ scope: "run" | "attempt" | "global";
1443
+ } | undefined;
1252
1444
  metadataType?: string | undefined;
1253
1445
  test?: boolean | undefined;
1254
1446
  }>>;
@@ -1271,8 +1463,17 @@ export declare const BatchTriggerTaskItem: z.ZodObject<{
1271
1463
  idempotencyKeyTTL?: string | undefined;
1272
1464
  concurrencyKey?: string | undefined;
1273
1465
  ttl?: string | number | undefined;
1466
+ debounce?: {
1467
+ key: string;
1468
+ delay: string;
1469
+ mode?: "leading" | "trailing" | undefined;
1470
+ } | undefined;
1274
1471
  parentAttempt?: string | undefined;
1275
1472
  lockToVersion?: string | undefined;
1473
+ idempotencyKeyOptions?: {
1474
+ key: string;
1475
+ scope: "run" | "attempt" | "global";
1476
+ } | undefined;
1276
1477
  metadataType?: string | undefined;
1277
1478
  test?: boolean | undefined;
1278
1479
  } | undefined;
@@ -1297,8 +1498,17 @@ export declare const BatchTriggerTaskItem: z.ZodObject<{
1297
1498
  idempotencyKeyTTL?: string | undefined;
1298
1499
  concurrencyKey?: string | undefined;
1299
1500
  ttl?: string | number | undefined;
1501
+ debounce?: {
1502
+ key: string;
1503
+ delay: string;
1504
+ mode?: "leading" | "trailing" | undefined;
1505
+ } | undefined;
1300
1506
  parentAttempt?: string | undefined;
1301
1507
  lockToVersion?: string | undefined;
1508
+ idempotencyKeyOptions?: {
1509
+ key: string;
1510
+ scope: "run" | "attempt" | "global";
1511
+ } | undefined;
1302
1512
  metadataType?: string | undefined;
1303
1513
  test?: boolean | undefined;
1304
1514
  } | undefined;
@@ -1316,6 +1526,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1316
1526
  delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
1317
1527
  idempotencyKey: z.ZodOptional<z.ZodString>;
1318
1528
  idempotencyKeyTTL: z.ZodOptional<z.ZodString>;
1529
+ /** The original user-provided idempotency key and scope */
1530
+ idempotencyKeyOptions: z.ZodOptional<z.ZodObject<{
1531
+ key: z.ZodString;
1532
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
1533
+ }, "strip", z.ZodTypeAny, {
1534
+ key: string;
1535
+ scope: "run" | "attempt" | "global";
1536
+ }, {
1537
+ key: string;
1538
+ scope: "run" | "attempt" | "global";
1539
+ }>>;
1319
1540
  lockToVersion: z.ZodOptional<z.ZodString>;
1320
1541
  machine: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
1321
1542
  maxAttempts: z.ZodOptional<z.ZodNumber>;
@@ -1336,6 +1557,19 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1336
1557
  ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
1337
1558
  priority: z.ZodOptional<z.ZodNumber>;
1338
1559
  region: z.ZodOptional<z.ZodString>;
1560
+ debounce: z.ZodOptional<z.ZodObject<{
1561
+ key: z.ZodString;
1562
+ delay: z.ZodString;
1563
+ mode: z.ZodOptional<z.ZodEnum<["leading", "trailing"]>>;
1564
+ }, "strip", z.ZodTypeAny, {
1565
+ key: string;
1566
+ delay: string;
1567
+ mode?: "leading" | "trailing" | undefined;
1568
+ }, {
1569
+ key: string;
1570
+ delay: string;
1571
+ mode?: "leading" | "trailing" | undefined;
1572
+ }>>;
1339
1573
  }, "strip", z.ZodTypeAny, {
1340
1574
  metadata?: any;
1341
1575
  payloadType?: string | undefined;
@@ -1353,8 +1587,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1353
1587
  idempotencyKeyTTL?: string | undefined;
1354
1588
  concurrencyKey?: string | undefined;
1355
1589
  ttl?: string | number | undefined;
1590
+ debounce?: {
1591
+ key: string;
1592
+ delay: string;
1593
+ mode?: "leading" | "trailing" | undefined;
1594
+ } | undefined;
1356
1595
  parentAttempt?: string | undefined;
1357
1596
  lockToVersion?: string | undefined;
1597
+ idempotencyKeyOptions?: {
1598
+ key: string;
1599
+ scope: "run" | "attempt" | "global";
1600
+ } | undefined;
1358
1601
  metadataType?: string | undefined;
1359
1602
  test?: boolean | undefined;
1360
1603
  }, {
@@ -1374,8 +1617,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1374
1617
  idempotencyKeyTTL?: string | undefined;
1375
1618
  concurrencyKey?: string | undefined;
1376
1619
  ttl?: string | number | undefined;
1620
+ debounce?: {
1621
+ key: string;
1622
+ delay: string;
1623
+ mode?: "leading" | "trailing" | undefined;
1624
+ } | undefined;
1377
1625
  parentAttempt?: string | undefined;
1378
1626
  lockToVersion?: string | undefined;
1627
+ idempotencyKeyOptions?: {
1628
+ key: string;
1629
+ scope: "run" | "attempt" | "global";
1630
+ } | undefined;
1379
1631
  metadataType?: string | undefined;
1380
1632
  test?: boolean | undefined;
1381
1633
  }>>;
@@ -1398,8 +1650,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1398
1650
  idempotencyKeyTTL?: string | undefined;
1399
1651
  concurrencyKey?: string | undefined;
1400
1652
  ttl?: string | number | undefined;
1653
+ debounce?: {
1654
+ key: string;
1655
+ delay: string;
1656
+ mode?: "leading" | "trailing" | undefined;
1657
+ } | undefined;
1401
1658
  parentAttempt?: string | undefined;
1402
1659
  lockToVersion?: string | undefined;
1660
+ idempotencyKeyOptions?: {
1661
+ key: string;
1662
+ scope: "run" | "attempt" | "global";
1663
+ } | undefined;
1403
1664
  metadataType?: string | undefined;
1404
1665
  test?: boolean | undefined;
1405
1666
  } | undefined;
@@ -1424,8 +1685,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1424
1685
  idempotencyKeyTTL?: string | undefined;
1425
1686
  concurrencyKey?: string | undefined;
1426
1687
  ttl?: string | number | undefined;
1688
+ debounce?: {
1689
+ key: string;
1690
+ delay: string;
1691
+ mode?: "leading" | "trailing" | undefined;
1692
+ } | undefined;
1427
1693
  parentAttempt?: string | undefined;
1428
1694
  lockToVersion?: string | undefined;
1695
+ idempotencyKeyOptions?: {
1696
+ key: string;
1697
+ scope: "run" | "attempt" | "global";
1698
+ } | undefined;
1429
1699
  metadataType?: string | undefined;
1430
1700
  test?: boolean | undefined;
1431
1701
  } | undefined;
@@ -1464,8 +1734,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1464
1734
  idempotencyKeyTTL?: string | undefined;
1465
1735
  concurrencyKey?: string | undefined;
1466
1736
  ttl?: string | number | undefined;
1737
+ debounce?: {
1738
+ key: string;
1739
+ delay: string;
1740
+ mode?: "leading" | "trailing" | undefined;
1741
+ } | undefined;
1467
1742
  parentAttempt?: string | undefined;
1468
1743
  lockToVersion?: string | undefined;
1744
+ idempotencyKeyOptions?: {
1745
+ key: string;
1746
+ scope: "run" | "attempt" | "global";
1747
+ } | undefined;
1469
1748
  metadataType?: string | undefined;
1470
1749
  test?: boolean | undefined;
1471
1750
  } | undefined;
@@ -1495,8 +1774,17 @@ export declare const BatchTriggerTaskV2RequestBody: z.ZodObject<{
1495
1774
  idempotencyKeyTTL?: string | undefined;
1496
1775
  concurrencyKey?: string | undefined;
1497
1776
  ttl?: string | number | undefined;
1777
+ debounce?: {
1778
+ key: string;
1779
+ delay: string;
1780
+ mode?: "leading" | "trailing" | undefined;
1781
+ } | undefined;
1498
1782
  parentAttempt?: string | undefined;
1499
1783
  lockToVersion?: string | undefined;
1784
+ idempotencyKeyOptions?: {
1785
+ key: string;
1786
+ scope: "run" | "attempt" | "global";
1787
+ } | undefined;
1500
1788
  metadataType?: string | undefined;
1501
1789
  test?: boolean | undefined;
1502
1790
  } | undefined;
@@ -1560,6 +1848,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1560
1848
  delay: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodDate]>>;
1561
1849
  idempotencyKey: z.ZodOptional<z.ZodString>;
1562
1850
  idempotencyKeyTTL: z.ZodOptional<z.ZodString>;
1851
+ /** The original user-provided idempotency key and scope */
1852
+ idempotencyKeyOptions: z.ZodOptional<z.ZodObject<{
1853
+ key: z.ZodString;
1854
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
1855
+ }, "strip", z.ZodTypeAny, {
1856
+ key: string;
1857
+ scope: "run" | "attempt" | "global";
1858
+ }, {
1859
+ key: string;
1860
+ scope: "run" | "attempt" | "global";
1861
+ }>>;
1563
1862
  lockToVersion: z.ZodOptional<z.ZodString>;
1564
1863
  machine: z.ZodOptional<z.ZodEnum<["micro", "small-1x", "small-2x", "medium-1x", "medium-2x", "large-1x", "large-2x"]>>;
1565
1864
  maxAttempts: z.ZodOptional<z.ZodNumber>;
@@ -1580,6 +1879,19 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1580
1879
  ttl: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
1581
1880
  priority: z.ZodOptional<z.ZodNumber>;
1582
1881
  region: z.ZodOptional<z.ZodString>;
1882
+ debounce: z.ZodOptional<z.ZodObject<{
1883
+ key: z.ZodString;
1884
+ delay: z.ZodString;
1885
+ mode: z.ZodOptional<z.ZodEnum<["leading", "trailing"]>>;
1886
+ }, "strip", z.ZodTypeAny, {
1887
+ key: string;
1888
+ delay: string;
1889
+ mode?: "leading" | "trailing" | undefined;
1890
+ }, {
1891
+ key: string;
1892
+ delay: string;
1893
+ mode?: "leading" | "trailing" | undefined;
1894
+ }>>;
1583
1895
  }, "strip", z.ZodTypeAny, {
1584
1896
  metadata?: any;
1585
1897
  payloadType?: string | undefined;
@@ -1597,8 +1909,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1597
1909
  idempotencyKeyTTL?: string | undefined;
1598
1910
  concurrencyKey?: string | undefined;
1599
1911
  ttl?: string | number | undefined;
1912
+ debounce?: {
1913
+ key: string;
1914
+ delay: string;
1915
+ mode?: "leading" | "trailing" | undefined;
1916
+ } | undefined;
1600
1917
  parentAttempt?: string | undefined;
1601
1918
  lockToVersion?: string | undefined;
1919
+ idempotencyKeyOptions?: {
1920
+ key: string;
1921
+ scope: "run" | "attempt" | "global";
1922
+ } | undefined;
1602
1923
  metadataType?: string | undefined;
1603
1924
  test?: boolean | undefined;
1604
1925
  }, {
@@ -1618,8 +1939,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1618
1939
  idempotencyKeyTTL?: string | undefined;
1619
1940
  concurrencyKey?: string | undefined;
1620
1941
  ttl?: string | number | undefined;
1942
+ debounce?: {
1943
+ key: string;
1944
+ delay: string;
1945
+ mode?: "leading" | "trailing" | undefined;
1946
+ } | undefined;
1621
1947
  parentAttempt?: string | undefined;
1622
1948
  lockToVersion?: string | undefined;
1949
+ idempotencyKeyOptions?: {
1950
+ key: string;
1951
+ scope: "run" | "attempt" | "global";
1952
+ } | undefined;
1623
1953
  metadataType?: string | undefined;
1624
1954
  test?: boolean | undefined;
1625
1955
  }>>;
@@ -1642,8 +1972,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1642
1972
  idempotencyKeyTTL?: string | undefined;
1643
1973
  concurrencyKey?: string | undefined;
1644
1974
  ttl?: string | number | undefined;
1975
+ debounce?: {
1976
+ key: string;
1977
+ delay: string;
1978
+ mode?: "leading" | "trailing" | undefined;
1979
+ } | undefined;
1645
1980
  parentAttempt?: string | undefined;
1646
1981
  lockToVersion?: string | undefined;
1982
+ idempotencyKeyOptions?: {
1983
+ key: string;
1984
+ scope: "run" | "attempt" | "global";
1985
+ } | undefined;
1647
1986
  metadataType?: string | undefined;
1648
1987
  test?: boolean | undefined;
1649
1988
  } | undefined;
@@ -1668,8 +2007,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1668
2007
  idempotencyKeyTTL?: string | undefined;
1669
2008
  concurrencyKey?: string | undefined;
1670
2009
  ttl?: string | number | undefined;
2010
+ debounce?: {
2011
+ key: string;
2012
+ delay: string;
2013
+ mode?: "leading" | "trailing" | undefined;
2014
+ } | undefined;
1671
2015
  parentAttempt?: string | undefined;
1672
2016
  lockToVersion?: string | undefined;
2017
+ idempotencyKeyOptions?: {
2018
+ key: string;
2019
+ scope: "run" | "attempt" | "global";
2020
+ } | undefined;
1673
2021
  metadataType?: string | undefined;
1674
2022
  test?: boolean | undefined;
1675
2023
  } | undefined;
@@ -1706,8 +2054,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1706
2054
  idempotencyKeyTTL?: string | undefined;
1707
2055
  concurrencyKey?: string | undefined;
1708
2056
  ttl?: string | number | undefined;
2057
+ debounce?: {
2058
+ key: string;
2059
+ delay: string;
2060
+ mode?: "leading" | "trailing" | undefined;
2061
+ } | undefined;
1709
2062
  parentAttempt?: string | undefined;
1710
2063
  lockToVersion?: string | undefined;
2064
+ idempotencyKeyOptions?: {
2065
+ key: string;
2066
+ scope: "run" | "attempt" | "global";
2067
+ } | undefined;
1711
2068
  metadataType?: string | undefined;
1712
2069
  test?: boolean | undefined;
1713
2070
  } | undefined;
@@ -1736,8 +2093,17 @@ export declare const BatchTriggerTaskV3RequestBody: z.ZodObject<{
1736
2093
  idempotencyKeyTTL?: string | undefined;
1737
2094
  concurrencyKey?: string | undefined;
1738
2095
  ttl?: string | number | undefined;
2096
+ debounce?: {
2097
+ key: string;
2098
+ delay: string;
2099
+ mode?: "leading" | "trailing" | undefined;
2100
+ } | undefined;
1739
2101
  parentAttempt?: string | undefined;
1740
2102
  lockToVersion?: string | undefined;
2103
+ idempotencyKeyOptions?: {
2104
+ key: string;
2105
+ scope: "run" | "attempt" | "global";
2106
+ } | undefined;
1741
2107
  metadataType?: string | undefined;
1742
2108
  test?: boolean | undefined;
1743
2109
  } | undefined;
@@ -1772,16 +2138,35 @@ export declare const CreateBatchRequestBody: z.ZodObject<{
1772
2138
  resumeParentOnCompletion: z.ZodOptional<z.ZodBoolean>;
1773
2139
  /** Idempotency key for the batch */
1774
2140
  idempotencyKey: z.ZodOptional<z.ZodString>;
2141
+ /** The original user-provided idempotency key and scope */
2142
+ idempotencyKeyOptions: z.ZodOptional<z.ZodObject<{
2143
+ key: z.ZodString;
2144
+ scope: z.ZodEnum<["run", "attempt", "global"]>;
2145
+ }, "strip", z.ZodTypeAny, {
2146
+ key: string;
2147
+ scope: "run" | "attempt" | "global";
2148
+ }, {
2149
+ key: string;
2150
+ scope: "run" | "attempt" | "global";
2151
+ }>>;
1775
2152
  }, "strip", z.ZodTypeAny, {
1776
2153
  runCount: number;
1777
2154
  idempotencyKey?: string | undefined;
1778
2155
  parentRunId?: string | undefined;
1779
2156
  resumeParentOnCompletion?: boolean | undefined;
2157
+ idempotencyKeyOptions?: {
2158
+ key: string;
2159
+ scope: "run" | "attempt" | "global";
2160
+ } | undefined;
1780
2161
  }, {
1781
2162
  runCount: number;
1782
2163
  idempotencyKey?: string | undefined;
1783
2164
  parentRunId?: string | undefined;
1784
2165
  resumeParentOnCompletion?: boolean | undefined;
2166
+ idempotencyKeyOptions?: {
2167
+ key: string;
2168
+ scope: "run" | "attempt" | "global";
2169
+ } | undefined;
1785
2170
  }>;
1786
2171
  export type CreateBatchRequestBody = z.infer<typeof CreateBatchRequestBody>;
1787
2172
  /**
@@ -3320,6 +3705,20 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3320
3705
  values?: string[] | undefined;
3321
3706
  }>, "many">>;
3322
3707
  }, "strip", z.ZodTypeAny, {
3708
+ run: {
3709
+ id: string;
3710
+ isTest: boolean;
3711
+ machine: {
3712
+ cpu: number;
3713
+ memory: number;
3714
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3715
+ centsPerMs: number;
3716
+ };
3717
+ traceContext: Record<string, unknown>;
3718
+ friendlyId: string;
3719
+ attemptNumber: number;
3720
+ masterQueue: string;
3721
+ };
3323
3722
  version: "1";
3324
3723
  environment: {
3325
3724
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -3336,20 +3735,6 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3336
3735
  friendlyId?: string | undefined;
3337
3736
  imagePlatform?: string | undefined;
3338
3737
  };
3339
- run: {
3340
- id: string;
3341
- isTest: boolean;
3342
- machine: {
3343
- cpu: number;
3344
- memory: number;
3345
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3346
- centsPerMs: number;
3347
- };
3348
- traceContext: Record<string, unknown>;
3349
- friendlyId: string;
3350
- attemptNumber: number;
3351
- masterQueue: string;
3352
- };
3353
3738
  snapshot: {
3354
3739
  id: string;
3355
3740
  createdAt: Date;
@@ -3401,6 +3786,20 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3401
3786
  values?: string[] | undefined;
3402
3787
  }[] | undefined;
3403
3788
  }, {
3789
+ run: {
3790
+ id: string;
3791
+ isTest: boolean;
3792
+ machine: {
3793
+ cpu: number;
3794
+ memory: number;
3795
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3796
+ centsPerMs: number;
3797
+ };
3798
+ traceContext: Record<string, unknown>;
3799
+ friendlyId: string;
3800
+ attemptNumber: number;
3801
+ masterQueue: string;
3802
+ };
3404
3803
  version: "1";
3405
3804
  environment: {
3406
3805
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -3417,20 +3816,6 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3417
3816
  friendlyId?: string | undefined;
3418
3817
  imagePlatform?: string | undefined;
3419
3818
  };
3420
- run: {
3421
- id: string;
3422
- isTest: boolean;
3423
- machine: {
3424
- cpu: number;
3425
- memory: number;
3426
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3427
- centsPerMs: number;
3428
- };
3429
- traceContext: Record<string, unknown>;
3430
- friendlyId: string;
3431
- attemptNumber: number;
3432
- masterQueue: string;
3433
- };
3434
3819
  snapshot: {
3435
3820
  id: string;
3436
3821
  createdAt: Date;
@@ -3484,6 +3869,20 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3484
3869
  }>, "many">;
3485
3870
  }, "strip", z.ZodTypeAny, {
3486
3871
  dequeuedMessages: {
3872
+ run: {
3873
+ id: string;
3874
+ isTest: boolean;
3875
+ machine: {
3876
+ cpu: number;
3877
+ memory: number;
3878
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3879
+ centsPerMs: number;
3880
+ };
3881
+ traceContext: Record<string, unknown>;
3882
+ friendlyId: string;
3883
+ attemptNumber: number;
3884
+ masterQueue: string;
3885
+ };
3487
3886
  version: "1";
3488
3887
  environment: {
3489
3888
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -3500,20 +3899,6 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3500
3899
  friendlyId?: string | undefined;
3501
3900
  imagePlatform?: string | undefined;
3502
3901
  };
3503
- run: {
3504
- id: string;
3505
- isTest: boolean;
3506
- machine: {
3507
- cpu: number;
3508
- memory: number;
3509
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3510
- centsPerMs: number;
3511
- };
3512
- traceContext: Record<string, unknown>;
3513
- friendlyId: string;
3514
- attemptNumber: number;
3515
- masterQueue: string;
3516
- };
3517
3902
  snapshot: {
3518
3903
  id: string;
3519
3904
  createdAt: Date;
@@ -3567,6 +3952,20 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3567
3952
  }[];
3568
3953
  }, {
3569
3954
  dequeuedMessages: {
3955
+ run: {
3956
+ id: string;
3957
+ isTest: boolean;
3958
+ machine: {
3959
+ cpu: number;
3960
+ memory: number;
3961
+ name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3962
+ centsPerMs: number;
3963
+ };
3964
+ traceContext: Record<string, unknown>;
3965
+ friendlyId: string;
3966
+ attemptNumber: number;
3967
+ masterQueue: string;
3968
+ };
3570
3969
  version: "1";
3571
3970
  environment: {
3572
3971
  type: "PRODUCTION" | "STAGING" | "DEVELOPMENT" | "PREVIEW";
@@ -3583,20 +3982,6 @@ export declare const DevDequeueResponseBody: z.ZodObject<{
3583
3982
  friendlyId?: string | undefined;
3584
3983
  imagePlatform?: string | undefined;
3585
3984
  };
3586
- run: {
3587
- id: string;
3588
- isTest: boolean;
3589
- machine: {
3590
- cpu: number;
3591
- memory: number;
3592
- name: "micro" | "small-1x" | "small-2x" | "medium-1x" | "medium-2x" | "large-1x" | "large-2x";
3593
- centsPerMs: number;
3594
- };
3595
- traceContext: Record<string, unknown>;
3596
- friendlyId: string;
3597
- attemptNumber: number;
3598
- masterQueue: string;
3599
- };
3600
3985
  snapshot: {
3601
3986
  id: string;
3602
3987
  createdAt: Date;
@@ -3667,6 +4052,14 @@ export declare const CanceledRunResponse: z.ZodObject<{
3667
4052
  id: string;
3668
4053
  }>;
3669
4054
  export type CanceledRunResponse = z.infer<typeof CanceledRunResponse>;
4055
+ export declare const ResetIdempotencyKeyResponse: z.ZodObject<{
4056
+ id: z.ZodString;
4057
+ }, "strip", z.ZodTypeAny, {
4058
+ id: string;
4059
+ }, {
4060
+ id: string;
4061
+ }>;
4062
+ export type ResetIdempotencyKeyResponse = z.infer<typeof ResetIdempotencyKeyResponse>;
3670
4063
  export declare const ScheduleType: z.ZodUnion<[z.ZodLiteral<"DECLARATIVE">, z.ZodLiteral<"IMPERATIVE">]>;
3671
4064
  export declare const ScheduledTaskPayload: z.ZodObject<{
3672
4065
  /** The schedule id associated with this run (you can have many schedules for the same task).