@adea-ai/runtime-sdk 1.21.1 → 1.22.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.
@@ -215,6 +215,26 @@ export declare const PiDurableLeadCancelRequestSchema: z.ZodObject<{
215
215
  dispatchId: z.ZodString;
216
216
  }, z.core.$strict>;
217
217
  }, z.core.$strict>;
218
+ export declare const PiDurableLeadChildCancelRequestSchema: z.ZodObject<{
219
+ contractVersion: z.ZodObject<{
220
+ major: z.ZodNumber;
221
+ minor: z.ZodNumber;
222
+ }, z.core.$strict>;
223
+ requestId: z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"request ID">, string>>;
224
+ workspaceId: z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"workspace ID">, string>>;
225
+ projectId: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"project ID">, string>>>;
226
+ commandId: z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"command ID">, string>>;
227
+ idempotencyKey: z.ZodString;
228
+ payloadHash: z.ZodString;
229
+ issuedAt: z.ZodISODateTime;
230
+ caller: typeof Caller;
231
+ correlation: typeof Correlation;
232
+ operation: z.ZodLiteral<"pi-durable.lead.child-cancel">;
233
+ payload: z.ZodObject<{
234
+ dispatchId: typeof DispatchId;
235
+ delegationId: typeof IdentifierSchemas.delegationId;
236
+ }, z.core.$strict>;
237
+ }, z.core.$strict>;
218
238
  export declare const PiDurableLeadReceiptResponseSchema: z.ZodObject<{
219
239
  schemaVersion: z.ZodLiteral<"pi-lead-dispatch/v1">;
220
240
  dispatchId: typeof DispatchId;
@@ -506,6 +526,30 @@ export declare const PiDurableLeadChildrenResponseSchema: z.ZodObject<{
506
526
  next: z.ZodOptional<typeof PiDurableLeadChildrenCursorSchema>;
507
527
  }, z.core.$strict>;
508
528
  }, z.core.$strict>;
529
+ export declare const PiDurableLeadChildCancelResponseSchema: z.ZodObject<{
530
+ contractVersion: z.ZodObject<{
531
+ major: z.ZodNumber;
532
+ minor: z.ZodNumber;
533
+ }, z.core.$strict>;
534
+ requestId: z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"request ID">, string>>;
535
+ correlation: z.ZodObject<{
536
+ traceId: z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"trace ID">, string>>;
537
+ causationCommandId: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"command ID">, string>>>;
538
+ parentEventId: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"event ID">, string>>>;
539
+ }, z.core.$strict>;
540
+ data: z.ZodObject<{
541
+ schemaVersion: z.ZodLiteral<"pi-lead-dispatch/v1">;
542
+ dispatchId: typeof DispatchId;
543
+ intentId: typeof IntentId;
544
+ executionId: typeof IdentifierSchemas.executionId;
545
+ attemptId: typeof IdentifierSchemas.attemptId;
546
+ runtimeSessionId: z.ZodPipe<z.ZodString, z.ZodTransform<import("@adea-ai/contracts").OpaqueIdentifier<"external-session ID">, string>>;
547
+ requestedTarget: z.ZodOptional<typeof PiDurableLeadRequestedTargetSchema>;
548
+ observedTarget: z.ZodOptional<typeof PiDurableLeadObservedTargetSchema>;
549
+ child: typeof PiDurableLeadChildSchema;
550
+ attributed: z.ZodBoolean;
551
+ }, z.core.$strict>;
552
+ }, z.core.$strict>;
509
553
  export declare const PiDurableLeadChildTargetSchema: z.ZodObject<{
510
554
  source: z.ZodLiteral<"control_plane_reported">;
511
555
  runtimeConnectionId: typeof IdentifierSchemas.runtimeConnectionId;
@@ -650,6 +694,13 @@ export declare const PiDurableLeadHttpContract: Readonly<{
650
694
  requestSchema: typeof PiDurableLeadCancelRequestSchema;
651
695
  responseSchema: typeof PiDurableLeadCancelResponseSchema;
652
696
  }>;
697
+ childCancel: Readonly<{
698
+ route: "child-cancel";
699
+ operation: "pi-durable.lead.child-cancel";
700
+ scope: "execution:cancel";
701
+ requestSchema: typeof PiDurableLeadChildCancelRequestSchema;
702
+ responseSchema: typeof PiDurableLeadChildCancelResponseSchema;
703
+ }>;
653
704
  }>;
654
705
  export type PiDurableLeadPrepareRequest = z.output<typeof PiDurableLeadPrepareRequestSchema>;
655
706
  export type PiDurableLeadPrepareResponse = z.output<typeof PiDurableLeadPrepareResponseSchema>;
@@ -668,6 +719,8 @@ export type PiDurableLeadChildrenResponse = z.output<typeof PiDurableLeadChildre
668
719
  export type PiDurableLeadChild = z.output<typeof PiDurableLeadChildSchema>;
669
720
  export type PiDurableLeadCancelRequest = z.output<typeof PiDurableLeadCancelRequestSchema>;
670
721
  export type PiDurableLeadCancelResponse = z.output<typeof PiDurableLeadCancelResponseSchema>;
722
+ export type PiDurableLeadChildCancelRequest = z.output<typeof PiDurableLeadChildCancelRequestSchema>;
723
+ export type PiDurableLeadChildCancelResponse = z.output<typeof PiDurableLeadChildCancelResponseSchema>;
671
724
  export type PiDurableLeadChildTargetRequest = z.output<typeof PiDurableLeadChildTargetRequestSchema>;
672
725
  export type PiDurableLeadChildTargetResponse = z.output<typeof PiDurableLeadChildTargetResponseSchema>;
673
726
  export type PiDurableLeadChildTarget = z.output<typeof PiDurableLeadChildTargetSchema>;
@@ -129,6 +129,15 @@ export const PiDurableLeadCancelRequestSchema = PiDurableLeadCommandEnvelopeSche
129
129
  operation: z.literal('pi-durable.lead.cancel'),
130
130
  payload: z.object({ dispatchId: DispatchId }).strict(),
131
131
  });
132
+ export const PiDurableLeadChildCancelRequestSchema = PiDurableLeadCommandEnvelopeSchema.extend({
133
+ operation: z.literal('pi-durable.lead.child-cancel'),
134
+ payload: z
135
+ .object({
136
+ dispatchId: DispatchId,
137
+ delegationId: IdentifierSchemas.delegationId,
138
+ })
139
+ .strict(),
140
+ });
132
141
  export const PiDurableLeadReceiptResponseSchema = z
133
142
  .object({
134
143
  schemaVersion: z.literal('pi-lead-dispatch/v1'),
@@ -313,6 +322,12 @@ export const PiDurableLeadChildrenResponseSchema = response.extend({
313
322
  });
314
323
  }),
315
324
  });
325
+ export const PiDurableLeadChildCancelResponseSchema = response.extend({
326
+ data: PiDurableLeadReceiptResponseSchema.extend({
327
+ child: PiDurableLeadChildSchema,
328
+ attributed: z.boolean(),
329
+ }),
330
+ });
316
331
  export const PiDurableLeadChildTargetSchema = z.strictObject({
317
332
  source: z.literal('control_plane_reported'),
318
333
  runtimeConnectionId: IdentifierSchemas.runtimeConnectionId,
@@ -464,4 +479,11 @@ export const PiDurableLeadHttpContract = Object.freeze({
464
479
  requestSchema: PiDurableLeadCancelRequestSchema,
465
480
  responseSchema: PiDurableLeadCancelResponseSchema,
466
481
  }),
482
+ childCancel: Object.freeze({
483
+ route: 'child-cancel',
484
+ operation: 'pi-durable.lead.child-cancel',
485
+ scope: 'execution:cancel',
486
+ requestSchema: PiDurableLeadChildCancelRequestSchema,
487
+ responseSchema: PiDurableLeadChildCancelResponseSchema,
488
+ }),
467
489
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adea-ai/runtime-sdk",
3
- "version": "1.21.1",
3
+ "version": "1.22.0",
4
4
  "description": "SDK for building Control Plane runtimes: adapters, capabilities, conformance, discovery, eligibility, health, sessions, transport, and routing.",
5
5
  "keywords": [
6
6
  "adapter",
@@ -43,7 +43,7 @@
43
43
  "test": "bun test src"
44
44
  },
45
45
  "dependencies": {
46
- "@adea-ai/contracts": "^1.26.0",
46
+ "@adea-ai/contracts": "^1.26.1",
47
47
  "zod": "4.6.6"
48
48
  },
49
49
  "engines": {