@tangle-network/agent-interface 5.10.16 → 5.10.17

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.
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Lifecycle bounds a caller may place on one environment create (#309).
3
+ *
4
+ * Both are whole seconds — a millisecond value that is not a whole second is
5
+ * refused, so a caller never believes a sub-second bound was honored. A
6
+ * provider that cannot enforce a requested bound fails the create rather than
7
+ * dropping the field; one whose platform caps the value honors the shorter.
8
+ */
9
+ export interface AgentEnvironmentLifetime {
10
+ /** Hard wall-clock lifetime the environment cannot outlive, counted from the create. */
11
+ maxLifetimeMs?: number;
12
+ /** After this long with no caller activity the platform may suspend or stop the environment. */
13
+ idleTimeoutMs?: number;
14
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -1,6 +1,7 @@
1
1
  import { z } from "zod";
2
2
  import { type ProxySecretBinding, type ProxySecretCapabilities, type ProxySecretReceipt, type ProxySecretParents } from "./proxy-secrets.js";
3
3
  import type { AgentRuntimeAttachments } from "./runtime-attachments.js";
4
+ import type { AgentEnvironmentLifetime } from "./environment-lifetime.js";
4
5
  export { AgentRuntimeAttachmentsSchema, type AgentRuntimeAttachments } from "./runtime-attachments.js";
5
6
  import type { AgentCandidateArtifactPort, Sha256Digest } from "./agent-candidate.js";
6
7
  import type { AgentProfile, AgentProfileCapabilities, AgentProfileValidationResult } from "./agent-profile.js";
@@ -1756,7 +1757,7 @@ export declare const AgentEnvironmentCapabilitiesSchema: z.ZodObject<{
1756
1757
  stop: z.ZodBoolean;
1757
1758
  }, z.core.$strict>>;
1758
1759
  }, z.core.$strict>;
1759
- export interface CreateAgentEnvironmentInput {
1760
+ export interface CreateAgentEnvironmentInput extends AgentEnvironmentLifetime {
1760
1761
  profile: AgentProfileRef;
1761
1762
  /**
1762
1763
  * Runtime-owned execution inputs, separate from authored profile identity.
@@ -1813,7 +1814,6 @@ export interface CreateAgentEnvironmentInput {
1813
1814
  * When present, the provider must use this key as one idempotent operation:
1814
1815
  * the same key with canonically equal create input must return or reconstruct
1815
1816
  * the same environment, while a different input must be rejected.
1816
- * `signal` controls one attempt and is not part of create identity.
1817
1817
  */
1818
1818
  idempotencyKey?: string;
1819
1819
  signal?: AbortSignal;
package/dist/index.d.ts CHANGED
@@ -9,6 +9,7 @@ export * from "./host-services.js";
9
9
  export * from "./mcp.js";
10
10
  export * from "./provider-adapter.js";
11
11
  export type * from "./environment-provider.js";
12
+ export type { AgentEnvironmentLifetime } from "./environment-lifetime.js";
12
13
  export { AgentEnvironmentCapabilitiesSchema, AgentEnvironmentReadOnlyGetOptionsSchema, AgentRuntimeAttachmentsSchema, AgentNativeContextContinuationAdmissionSchema, AgentNativeContextContinuationResultSchema, AgentTurnInputSchema, AgentTurnResultSchema, agentEnvironmentCreateInputDigest, agentNativeContextContinuationAdmissionMatchesRequest, agentNativeContextContinuationResultMatchesRequest, AccountUsageSchema, AgentEnvironmentObservationSchema, AgentEnvironmentStatusSchema, ComputeBillingSchema, EnvironmentLifecycleSchema, ModelUsageSchema, ObservationProvenanceSchema, PlacementDescriptorSchema, ProviderIdentitySchema, ResourceProfileSchema, ResourceUseSampleSchema, SafeEndpointSchema, agentEnvironmentObservationIdentityMatches, observationContainsCredential, observationOf, AgentInteractiveSessionAttachSchema, AgentInteractiveSessionControlClaimAcknowledgementSchema, AgentInteractiveSessionControlClaimRequestSchema, AgentInteractiveSessionControlClaimSchema, AgentInteractiveSessionPromptAcknowledgementSchema, AgentInteractiveSessionPromptCommandSchema, AgentInteractiveSessionRefSchema, AgentInteractiveSessionStartSchema, AgentInteractiveSessionStopAcknowledgementSchema, AgentInteractiveSessionStopCommandSchema, AgentInteractiveSessionStatusSchema, agentInteractiveSessionControlClaimAcknowledgementMatchesRequest, agentInteractiveSessionControlClaimRequestDigest, agentInteractiveSessionControlClaimMatchesRef, agentInteractiveSessionControlClaimIsNewer, agentInteractiveSessionPromptAcknowledgementMatchesCommand, agentInteractiveSessionPromptRequestDigest, agentInteractiveSessionStopAcknowledgementMatchesCommand, agentInteractiveSessionStopRequestDigest, agentInteractiveSessionRefMatchesStart, agentInteractiveSessionRunRef, agentInteractiveSessionStatusMatchesRef, exactAgentInteractiveSessionStart, createAgentEnvironmentWithIdempotency, canonicalWorkspaceCwd, MAX_WORKSPACE_CWD_LENGTH, workspaceCwdSchema, workspaceCwdPathForBase, WorkspaceRequestSchema, ResourceRequestSchema, TerminalAttachRequestSchema, TerminalAttachResultSchema, TerminalDetachAckSchema, TerminalInputSchema, TerminalOutputEventSchema, TerminalReplayWindowSchema, TerminalResizeSchema, TerminalSessionRefSchema, terminalAttachResultMatchesRequest, terminalSessionUsable, } from "./environment-provider.js";
13
14
  export * from "./environment-provider-error.js";
14
15
  export * from "./plan.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tangle-network/agent-interface",
3
- "version": "5.10.16",
3
+ "version": "5.10.17",
4
4
  "type": "module",
5
5
  "sideEffects": false,
6
6
  "license": "MIT",