@automate.ax/api-contract 0.135.0 → 0.137.0

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.
@@ -1,5 +1,5 @@
1
1
  import { z } from "zod";
2
- export declare const EXECUTION_DATASET_VERSION = 10;
2
+ export declare const EXECUTION_DATASET_VERSION = 11;
3
3
  export declare const executionDatasetResourceSchema: z.ZodEnum<{
4
4
  automations: "automations";
5
5
  projects: "projects";
@@ -13,8 +13,10 @@ export declare const executionDatasetResourceSchema: z.ZodEnum<{
13
13
  "action-attempts": "action-attempts";
14
14
  "signal-invocations": "signal-invocations";
15
15
  "signal-coordinators": "signal-coordinators";
16
+ "signal-partitions": "signal-partitions";
16
17
  "signal-offers": "signal-offers";
17
18
  "signal-decisions": "signal-decisions";
19
+ "signal-decision-offers": "signal-decision-offers";
18
20
  logs: "logs";
19
21
  }>;
20
22
  export declare const executionDatasetScopeSchema: z.ZodObject<{
@@ -40,13 +42,15 @@ export declare const executionDatasetManifestSchema: z.ZodObject<{
40
42
  "action-attempts": "action-attempts";
41
43
  "signal-invocations": "signal-invocations";
42
44
  "signal-coordinators": "signal-coordinators";
45
+ "signal-partitions": "signal-partitions";
43
46
  "signal-offers": "signal-offers";
44
47
  "signal-decisions": "signal-decisions";
48
+ "signal-decision-offers": "signal-decision-offers";
45
49
  logs: "logs";
46
50
  }>;
47
51
  url: z.ZodURL;
48
52
  }, z.core.$strip>>;
49
- schemaVersion: z.ZodLiteral<10>;
53
+ schemaVersion: z.ZodLiteral<11>;
50
54
  scope: z.ZodObject<{
51
55
  organizationId: z.ZodNullable<z.ZodString>;
52
56
  projectId: z.ZodNullable<z.ZodString>;
@@ -78,13 +82,15 @@ export declare const executionDataContract: {
78
82
  "action-attempts": "action-attempts";
79
83
  "signal-invocations": "signal-invocations";
80
84
  "signal-coordinators": "signal-coordinators";
85
+ "signal-partitions": "signal-partitions";
81
86
  "signal-offers": "signal-offers";
82
87
  "signal-decisions": "signal-decisions";
88
+ "signal-decision-offers": "signal-decision-offers";
83
89
  logs: "logs";
84
90
  }>;
85
91
  url: z.ZodURL;
86
92
  }, z.core.$strip>>;
87
- schemaVersion: z.ZodLiteral<10>;
93
+ schemaVersion: z.ZodLiteral<11>;
88
94
  scope: z.ZodObject<{
89
95
  organizationId: z.ZodNullable<z.ZodString>;
90
96
  projectId: z.ZodNullable<z.ZodString>;
@@ -1,6 +1,6 @@
1
1
  import { oc } from "@orpc/contract";
2
2
  import { z } from "zod";
3
- export const EXECUTION_DATASET_VERSION = 10;
3
+ export const EXECUTION_DATASET_VERSION = 11;
4
4
  export const executionDatasetResourceSchema = z.enum([
5
5
  "projects",
6
6
  "automations",
@@ -13,8 +13,10 @@ export const executionDatasetResourceSchema = z.enum([
13
13
  "action-attempts",
14
14
  "signal-invocations",
15
15
  "signal-coordinators",
16
+ "signal-partitions",
16
17
  "signal-offers",
17
18
  "signal-decisions",
19
+ "signal-decision-offers",
18
20
  "logs",
19
21
  "outputs",
20
22
  ]);
package/dist/index.d.ts CHANGED
@@ -783,13 +783,15 @@ export declare const publicContract: {
783
783
  "action-attempts": "action-attempts";
784
784
  "signal-invocations": "signal-invocations";
785
785
  "signal-coordinators": "signal-coordinators";
786
+ "signal-partitions": "signal-partitions";
786
787
  "signal-offers": "signal-offers";
787
788
  "signal-decisions": "signal-decisions";
789
+ "signal-decision-offers": "signal-decision-offers";
788
790
  logs: "logs";
789
791
  }>;
790
792
  url: import("zod").ZodURL;
791
793
  }, import("zod/v4/core").$strip>>;
792
- schemaVersion: import("zod").ZodLiteral<10>;
794
+ schemaVersion: import("zod").ZodLiteral<11>;
793
795
  scope: import("zod").ZodObject<{
794
796
  organizationId: import("zod").ZodNullable<import("zod").ZodString>;
795
797
  projectId: import("zod").ZodNullable<import("zod").ZodString>;
@@ -2172,13 +2174,15 @@ export declare const firstPartyContract: {
2172
2174
  "action-attempts": "action-attempts";
2173
2175
  "signal-invocations": "signal-invocations";
2174
2176
  "signal-coordinators": "signal-coordinators";
2177
+ "signal-partitions": "signal-partitions";
2175
2178
  "signal-offers": "signal-offers";
2176
2179
  "signal-decisions": "signal-decisions";
2180
+ "signal-decision-offers": "signal-decision-offers";
2177
2181
  logs: "logs";
2178
2182
  }>;
2179
2183
  url: import("zod").ZodURL;
2180
2184
  }, import("zod/v4/core").$strip>>;
2181
- schemaVersion: import("zod").ZodLiteral<10>;
2185
+ schemaVersion: import("zod").ZodLiteral<11>;
2182
2186
  scope: import("zod").ZodObject<{
2183
2187
  organizationId: import("zod").ZodNullable<import("zod").ZodString>;
2184
2188
  projectId: import("zod").ZodNullable<import("zod").ZodString>;
@@ -6098,6 +6102,7 @@ export declare const contract: {
6098
6102
  }, import("zod/v4/core").$strip>>;
6099
6103
  count: import("zod").ZodNumber;
6100
6104
  key: import("zod").ZodCustom<import("@automate.ax/codec/rpc").CodecEnvelope, import("@automate.ax/codec/rpc").CodecEnvelope>;
6105
+ occurrenceTtl: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodString, import("zod").ZodNumber]>>;
6101
6106
  outcomeSeq: import("zod").ZodNumber;
6102
6107
  policy: import("zod").ZodLiteral<"collect">;
6103
6108
  position: import("zod").ZodOptional<import("zod").ZodNumber>;
@@ -6132,6 +6137,7 @@ export declare const contract: {
6132
6137
  roots: import("zod").ZodArray<import("zod").ZodNumber>;
6133
6138
  }, import("zod/v4/core").$strip>>;
6134
6139
  key: import("zod").ZodCustom<import("@automate.ax/codec/rpc").CodecEnvelope, import("@automate.ax/codec/rpc").CodecEnvelope>;
6140
+ occurrenceTtl: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodString, import("zod").ZodNumber]>>;
6135
6141
  ordered: import("zod").ZodBoolean;
6136
6142
  outcomeSeq: import("zod").ZodNumber;
6137
6143
  policy: import("zod").ZodLiteral<"correlate">;
@@ -8348,13 +8354,15 @@ export declare const contract: {
8348
8354
  "action-attempts": "action-attempts";
8349
8355
  "signal-invocations": "signal-invocations";
8350
8356
  "signal-coordinators": "signal-coordinators";
8357
+ "signal-partitions": "signal-partitions";
8351
8358
  "signal-offers": "signal-offers";
8352
8359
  "signal-decisions": "signal-decisions";
8360
+ "signal-decision-offers": "signal-decision-offers";
8353
8361
  logs: "logs";
8354
8362
  }>;
8355
8363
  url: import("zod").ZodURL;
8356
8364
  }, import("zod/v4/core").$strip>>;
8357
- schemaVersion: import("zod").ZodLiteral<10>;
8365
+ schemaVersion: import("zod").ZodLiteral<11>;
8358
8366
  scope: import("zod").ZodObject<{
8359
8367
  organizationId: import("zod").ZodNullable<import("zod").ZodString>;
8360
8368
  projectId: import("zod").ZodNullable<import("zod").ZodString>;
package/dist/runtime.d.ts CHANGED
@@ -107,6 +107,7 @@ declare const COORDINATION_OFFER_SCHEMA: z.ZodUnion<readonly [z.ZodObject<{
107
107
  }, z.core.$strip>>;
108
108
  count: z.ZodNumber;
109
109
  key: z.ZodOptional<z.ZodCustom<import("@automate.ax/codec").Encodable, import("@automate.ax/codec").Encodable>>;
110
+ occurrenceTtl: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
110
111
  outcomeSeq: z.ZodNumber;
111
112
  policy: z.ZodLiteral<"collect">;
112
113
  position: z.ZodOptional<z.ZodNumber>;
@@ -141,6 +142,7 @@ declare const COORDINATION_OFFER_SCHEMA: z.ZodUnion<readonly [z.ZodObject<{
141
142
  roots: z.ZodArray<z.ZodNumber>;
142
143
  }, z.core.$strip>>;
143
144
  key: z.ZodOptional<z.ZodCustom<import("@automate.ax/codec").Encodable, import("@automate.ax/codec").Encodable>>;
145
+ occurrenceTtl: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
144
146
  ordered: z.ZodBoolean;
145
147
  outcomeSeq: z.ZodNumber;
146
148
  policy: z.ZodLiteral<"correlate">;
@@ -1403,6 +1405,7 @@ export declare const runtimeContract: {
1403
1405
  }, z.core.$strip>>;
1404
1406
  count: z.ZodNumber;
1405
1407
  key: z.ZodCustom<import("@automate.ax/codec/rpc").CodecEnvelope, import("@automate.ax/codec/rpc").CodecEnvelope>;
1408
+ occurrenceTtl: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
1406
1409
  outcomeSeq: z.ZodNumber;
1407
1410
  policy: z.ZodLiteral<"collect">;
1408
1411
  position: z.ZodOptional<z.ZodNumber>;
@@ -1437,6 +1440,7 @@ export declare const runtimeContract: {
1437
1440
  roots: z.ZodArray<z.ZodNumber>;
1438
1441
  }, z.core.$strip>>;
1439
1442
  key: z.ZodCustom<import("@automate.ax/codec/rpc").CodecEnvelope, import("@automate.ax/codec/rpc").CodecEnvelope>;
1443
+ occurrenceTtl: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>>;
1440
1444
  ordered: z.ZodBoolean;
1441
1445
  outcomeSeq: z.ZodNumber;
1442
1446
  policy: z.ZodLiteral<"correlate">;
package/dist/runtime.js CHANGED
@@ -231,12 +231,14 @@ const MERGE_INPUT_ORIGINS_SCHEMA = z
231
231
  .min(2);
232
232
  const createCorrelationOfferSchema = (keySchema) => SIGNAL_INVOCATION_DEPENDENCIES_SCHEMA.extend({
233
233
  key: keySchema,
234
+ occurrenceTtl: COORDINATION_DURATION_SCHEMA.optional(),
234
235
  ordered: z.boolean(),
235
236
  outcomeSeq: OUTCOME_SEQUENCE_SCHEMA,
236
237
  policy: z.literal("correlate"),
237
238
  streamIndex: z.number().int().nonnegative(),
238
239
  streamOrigins: CORRELATION_STREAM_ORIGINS_SCHEMA,
239
- ttl: z.union([z.string().min(1), z.number().nonnegative()]).optional(),
240
+ /** @deprecated Retained for deployed bundles that sourced TTL from keyBy. */
241
+ ttl: COORDINATION_DURATION_SCHEMA.optional(),
240
242
  }).superRefine((entry, context) => {
241
243
  if (entry.streamIndex >= entry.streamOrigins.length) {
242
244
  context.addIssue({
@@ -266,11 +268,13 @@ const createSerializationOfferSchema = (keySchema) => SIGNAL_INVOCATION_DEPENDEN
266
268
  const createCollectionOfferSchema = (keySchema) => SIGNAL_INVOCATION_DEPENDENCIES_SCHEMA.extend({
267
269
  count: z.number().int().positive(),
268
270
  key: keySchema,
271
+ occurrenceTtl: COORDINATION_DURATION_SCHEMA.optional(),
269
272
  outcomeSeq: OUTCOME_SEQUENCE_SCHEMA,
270
273
  policy: z.literal("collect"),
271
274
  position: z.number().int().nonnegative().optional(),
272
275
  primaryPosition: COORDINATION_PRIMARY_POSITION_SCHEMA,
273
- ttl: z.union([z.string().min(1), z.number().nonnegative()]).optional(),
276
+ /** @deprecated Retained for deployed bundles that sourced TTL from keyBy. */
277
+ ttl: COORDINATION_DURATION_SCHEMA.optional(),
274
278
  });
275
279
  const FANOUT_OFFER_SCHEMA = SIGNAL_INVOCATION_DEPENDENCIES_SCHEMA.extend({
276
280
  count: z.number().int().nonnegative(),
@@ -287,6 +291,7 @@ const createFunnelOfferSchema = (keySchema) => SIGNAL_INVOCATION_DEPENDENCIES_SC
287
291
  primaryPosition: COORDINATION_PRIMARY_POSITION_SCHEMA,
288
292
  selection: z.enum(["all", "first", "last"]),
289
293
  triggerAt: z.enum(["start", "end", "both"]),
294
+ /** @deprecated Retained for deployed bundles that sourced TTL from keyBy. */
290
295
  ttl: COORDINATION_DURATION_SCHEMA.optional(),
291
296
  until: z.date().optional(),
292
297
  }).superRefine((offer, context) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@automate.ax/api-contract",
3
- "version": "0.135.0",
3
+ "version": "0.137.0",
4
4
  "description": "Public oRPC contract for the Automate.ax API.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -31,8 +31,8 @@
31
31
  },
32
32
  "dependencies": {
33
33
  "@ai-sdk/gateway": "4.0.46",
34
- "@automate.ax/codec": "0.135.0",
35
- "@automate.ax/integration-contracts": "0.135.0",
34
+ "@automate.ax/codec": "0.137.0",
35
+ "@automate.ax/integration-contracts": "0.137.0",
36
36
  "@orpc/contract": "1.15.0",
37
37
  "fast-json-stable-stringify": "^2.1.0",
38
38
  "zod": "^4.3.6"
@@ -1,7 +1,7 @@
1
1
  import { oc } from "@orpc/contract"
2
2
  import { z } from "zod"
3
3
 
4
- export const EXECUTION_DATASET_VERSION = 10
4
+ export const EXECUTION_DATASET_VERSION = 11
5
5
 
6
6
  export const executionDatasetResourceSchema = z.enum([
7
7
  "projects",
@@ -15,8 +15,10 @@ export const executionDatasetResourceSchema = z.enum([
15
15
  "action-attempts",
16
16
  "signal-invocations",
17
17
  "signal-coordinators",
18
+ "signal-partitions",
18
19
  "signal-offers",
19
20
  "signal-decisions",
21
+ "signal-decision-offers",
20
22
  "logs",
21
23
  "outputs",
22
24
  ])
package/src/runtime.ts CHANGED
@@ -287,12 +287,15 @@ const createCorrelationOfferSchema = <TKeySchema extends z.ZodType>(
287
287
  ) =>
288
288
  SIGNAL_INVOCATION_DEPENDENCIES_SCHEMA.extend({
289
289
  key: keySchema,
290
+ occurrenceTtl: COORDINATION_DURATION_SCHEMA.optional(),
290
291
  ordered: z.boolean(),
291
292
  outcomeSeq: OUTCOME_SEQUENCE_SCHEMA,
292
293
  policy: z.literal("correlate"),
293
294
  streamIndex: z.number().int().nonnegative(),
294
295
  streamOrigins: CORRELATION_STREAM_ORIGINS_SCHEMA,
295
- ttl: z.union([z.string().min(1), z.number().nonnegative()]).optional(),
296
+
297
+ /** @deprecated Retained for deployed bundles that sourced TTL from keyBy. */
298
+ ttl: COORDINATION_DURATION_SCHEMA.optional(),
296
299
  }).superRefine((entry, context) => {
297
300
  if (entry.streamIndex >= entry.streamOrigins.length) {
298
301
  context.addIssue({
@@ -331,11 +334,14 @@ const createCollectionOfferSchema = <TKeySchema extends z.ZodType>(
331
334
  SIGNAL_INVOCATION_DEPENDENCIES_SCHEMA.extend({
332
335
  count: z.number().int().positive(),
333
336
  key: keySchema,
337
+ occurrenceTtl: COORDINATION_DURATION_SCHEMA.optional(),
334
338
  outcomeSeq: OUTCOME_SEQUENCE_SCHEMA,
335
339
  policy: z.literal("collect"),
336
340
  position: z.number().int().nonnegative().optional(),
337
341
  primaryPosition: COORDINATION_PRIMARY_POSITION_SCHEMA,
338
- ttl: z.union([z.string().min(1), z.number().nonnegative()]).optional(),
342
+
343
+ /** @deprecated Retained for deployed bundles that sourced TTL from keyBy. */
344
+ ttl: COORDINATION_DURATION_SCHEMA.optional(),
339
345
  })
340
346
 
341
347
  const FANOUT_OFFER_SCHEMA = SIGNAL_INVOCATION_DEPENDENCIES_SCHEMA.extend({
@@ -357,6 +363,8 @@ const createFunnelOfferSchema = <TKeySchema extends z.ZodType>(
357
363
  primaryPosition: COORDINATION_PRIMARY_POSITION_SCHEMA,
358
364
  selection: z.enum(["all", "first", "last"]),
359
365
  triggerAt: z.enum(["start", "end", "both"]),
366
+
367
+ /** @deprecated Retained for deployed bundles that sourced TTL from keyBy. */
360
368
  ttl: COORDINATION_DURATION_SCHEMA.optional(),
361
369
  until: z.date().optional(),
362
370
  }).superRefine((offer, context) => {