@codesoul-co/hypha-core / contracts/runtime-human-task-schemas
- Package index:
@codesoul-co/hypha-core - Source:
packages/core/src/contracts/runtime-human-task-schemas.ts - Exports: 15
Using this module
Use the Runtime human task schemas module for declaring and runtime-validating contracts. It exports 12 constants, 3 functions.
Import from the package entrypoint
import {
runtimeHumanTaskContractDefinitions,
runtimeHumanTaskContractJsonSchemas,
runtimeHumanTaskDecisionCommandDefinition,
runtimeHumanTaskDecisionCommandExample,
runtimeHumanTaskDecisionCommandJsonSchema,
runtimeHumanTaskDecisionCommandSchema,
runtimeHumanTaskDefinition,
runtimeHumanTaskExample,
} from '@codesoul-co/hypha-core';
// The complete export list is documented below.Usage patterns
- The module exposes 3 functions as direct operation entrypoints. Every overload, required/optional parameter, and return type is documented below.
- The 12 constant/enum exports provide stable values, schemas, definitions, or defaults. Reuse these exports instead of copying internal values into an application.
Runtime validation example
import { runtimeHumanTaskDecisionCommandSchema } from '@codesoul-co/hypha-core';
declare function loadExternalInput(): unknown;
const input: unknown = loadExternalInput();
const parsed = runtimeHumanTaskDecisionCommandSchema.parse(input);Parse untrusted configuration, network, or persisted input with the runtime schema before passing it to functions or classes that expect a validated contract.
Public exports
| Symbol | Kind | Signature | Description |
|---|---|---|---|
runtimeHumanTaskContractDefinitions | constant | const runtimeHumanTaskContractDefinitions: readonly [SpecSchemaDefinition<RuntimeHumanTask>, SpecSchemaDefinition<RuntimeHumanTaskDecisionCommand>] | Runtime Human Task Contract Definitions constant exported by the contracts/runtime-human-task-schemas module. |
runtimeHumanTaskContractJsonSchemas | constant | const runtimeHumanTaskContractJsonSchemas: Record<string, JsonSchema> | Runtime Human Task Contract JSON Schemas constant exported by the contracts/runtime-human-task-schemas module. |
runtimeHumanTaskDecisionCommandDefinition | constant | const runtimeHumanTaskDecisionCommandDefinition: SpecSchemaDefinition<RuntimeHumanTaskDecisionCommand> | Runtime Human Task Decision Command Definition constant exported by the contracts/runtime-human-task-schemas module. |
runtimeHumanTaskDecisionCommandExample | constant | const runtimeHumanTaskDecisionCommandExample: RuntimeHumanTaskDecisionCommand | Valid example value for Runtime Human Task Decision Command. |
runtimeHumanTaskDecisionCommandJsonSchema | constant | const runtimeHumanTaskDecisionCommandJsonSchema: JsonSchema | JSON Schema for Runtime Human Task Decision Command. |
runtimeHumanTaskDecisionCommandSchema | constant | const runtimeHumanTaskDecisionCommandSchema: z.ZodEffects<z.ZodObject<{ commandId: z.ZodString; scope: z.ZodObject<{ tenantId: z.ZodOptional<z.ZodString>; userId: z.ZodString; workspaceId: z.ZodOptional<z.ZodString>; sessionId: z.ZodString; runId: z.ZodString; agentId: z.ZodOptional<z.ZodString>; }, "strict", z.ZodTypeAny, { userId: string; sessionId: string; runId: string; tenantId?: string | undefined; workspace... | Runtime schema for Runtime Human Task Decision Command. |
runtimeHumanTaskDefinition | constant | const runtimeHumanTaskDefinition: SpecSchemaDefinition<RuntimeHumanTask> | Runtime Human Task Definition constant exported by the contracts/runtime-human-task-schemas module. |
runtimeHumanTaskExample | constant | const runtimeHumanTaskExample: RuntimeHumanTask | Valid example value for Runtime Human Task. |
runtimeHumanTaskJsonSchema | constant | const runtimeHumanTaskJsonSchema: JsonSchema | JSON Schema for Runtime Human Task. |
runtimeHumanTaskRequestJsonSchema | constant | const runtimeHumanTaskRequestJsonSchema: JsonSchema | JSON Schema for Runtime Human Task Request. |
runtimeHumanTaskRequestSchema | constant | const runtimeHumanTaskRequestSchema: z.ZodEffects<z.ZodObject<{ taskId: z.ZodString; kind: z.ZodEnum<["tool", "skill", "prompt", "memory", "execution", "mcp", "policy"]>; subjectRef: z.ZodString; subjectHash: z.ZodString; requestedBy: z.ZodString; allowedDecisionScopes: z.ZodArray<z.ZodString, "many">; requestedAt: z.ZodString; expiresAt: z.ZodOptional<z.ZodString>; checkpointRef: z.ZodOptional<z.ZodString>; polic... | Runtime schema for Runtime Human Task Request. |
runtimeHumanTaskSchema | constant | const runtimeHumanTaskSchema: z.ZodEffects<z.ZodEffects<z.ZodObject<{ runId: z.ZodString; stateId: z.ZodString; stateAttempt: z.ZodNumber; status: z.ZodEnum<["pending", "approved", "rejected", "expired", "cancelled", "superseded"]>; revision: z.ZodNumber; decisionEventId: z.ZodOptional<z.ZodString>; decisionCommandId: z.ZodOptional<z.ZodString>; decisionIdempotencyKey: z.ZodOptional<z.ZodString>; decidedBy: z.ZodO... | Runtime schema for Runtime Human Task. |
validateRuntimeHumanTask | function | validateRuntimeHumanTask(input: unknown): RuntimeHumanTask | Validate Runtime Human Task function with 1 public call signature; parameters and return types are listed below. |
validateRuntimeHumanTaskDecisionCommand | function | validateRuntimeHumanTaskDecisionCommand(input: unknown): RuntimeHumanTaskDecisionCommand | Validate Runtime Human Task Decision Command function with 1 public call signature; parameters and return types are listed below. |
validateRuntimeHumanTaskRequest | function | validateRuntimeHumanTaskRequest(input: unknown): RuntimeHumanTaskRequest | Validate Runtime Human Task Request function with 1 public call signature; parameters and return types are listed below. |
runtimeHumanTaskContractDefinitions
Runtime Human Task Contract Definitions constant exported by the contracts/runtime-human-task-schemas module.
- Kind: constant
- Import:
import { runtimeHumanTaskContractDefinitions } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskContractDefinitions: readonly [SpecSchemaDefinition<RuntimeHumanTask>, SpecSchemaDefinition<RuntimeHumanTaskDecisionCommand>];runtimeHumanTaskContractJsonSchemas
Runtime Human Task Contract JSON Schemas constant exported by the contracts/runtime-human-task-schemas module.
- Kind: constant
- Import:
import { runtimeHumanTaskContractJsonSchemas } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskContractJsonSchemas: Record<string, JsonSchema>;runtimeHumanTaskDecisionCommandDefinition
Runtime Human Task Decision Command Definition constant exported by the contracts/runtime-human-task-schemas module.
- Kind: constant
- Import:
import { runtimeHumanTaskDecisionCommandDefinition } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskDecisionCommandDefinition: SpecSchemaDefinition<RuntimeHumanTaskDecisionCommand>;runtimeHumanTaskDecisionCommandExample
Valid example value for Runtime Human Task Decision Command.
- Kind: constant
- Import:
import { runtimeHumanTaskDecisionCommandExample } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskDecisionCommandExample: RuntimeHumanTaskDecisionCommand;runtimeHumanTaskDecisionCommandJsonSchema
JSON Schema for Runtime Human Task Decision Command.
- Kind: constant
- Import:
import { runtimeHumanTaskDecisionCommandJsonSchema } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskDecisionCommandJsonSchema: JsonSchema;runtimeHumanTaskDecisionCommandSchema
Runtime schema for Runtime Human Task Decision Command.
- Kind: constant
- Import:
import { runtimeHumanTaskDecisionCommandSchema } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
// Exact type resolved from the package entrypoint; see source for the compiler expansion.
export declare const runtimeHumanTaskDecisionCommandSchema: (typeof import('@codesoul-co/hypha-core'))['runtimeHumanTaskDecisionCommandSchema'];This compiler-expanded constant type is compacted. Its public name, top-level type, and source location remain here; use the module’s exported interfaces, types, or runtime schema for input/output fields.
runtimeHumanTaskDefinition
Runtime Human Task Definition constant exported by the contracts/runtime-human-task-schemas module.
- Kind: constant
- Import:
import { runtimeHumanTaskDefinition } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskDefinition: SpecSchemaDefinition<RuntimeHumanTask>;runtimeHumanTaskExample
Valid example value for Runtime Human Task.
- Kind: constant
- Import:
import { runtimeHumanTaskExample } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskExample: RuntimeHumanTask;runtimeHumanTaskJsonSchema
JSON Schema for Runtime Human Task.
- Kind: constant
- Import:
import { runtimeHumanTaskJsonSchema } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskJsonSchema: JsonSchema;runtimeHumanTaskRequestJsonSchema
JSON Schema for Runtime Human Task Request.
- Kind: constant
- Import:
import { runtimeHumanTaskRequestJsonSchema } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskRequestJsonSchema: JsonSchema;runtimeHumanTaskRequestSchema
Runtime schema for Runtime Human Task Request.
- Kind: constant
- Import:
import { runtimeHumanTaskRequestSchema } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare const runtimeHumanTaskRequestSchema: z.ZodEffects<z.ZodObject<{ taskId: z.ZodString; kind: z.ZodEnum<["tool", "skill", "prompt", "memory", "execution", "mcp", "policy"]>; subjectRef: z.ZodString; subjectHash: z.ZodString; requestedBy: z.ZodString; allowedDecisionScopes: z.ZodArray<z.ZodString, "many">; requestedAt: z.ZodString; expiresAt: z.ZodOptional<z.ZodString>; checkpointRef: z.ZodOptional<z.ZodString>; policyRef: z.ZodOptional<z.ZodString>; providerRevision: z.ZodOptional<z.ZodString>; activityDescriptorRef: z.ZodOptional<z.ZodString>; activityDescriptorHash: z.ZodOptional<z.ZodString>; reason: z.ZodOptional<z.ZodString>; metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>; }, "strict", z.ZodTypeAny, { kind: "tool" | "memory" | "execution" | "policy" | "skill" | "prompt" | "mcp"; requestedAt: string; taskId: string; subjectHash: string; subjectRef: string; requestedBy: string; allowedDecisionScopes: string[]; metadata?: Record<string, unknown> | undefined; policyRef?: string | undefined; expiresAt?: string | undefined; reason?: string | undefined; activityDescriptorRef?: string | undefined; activityDescriptorHash?: string | undefined; providerRevision?: string | undefined; checkpointRef?: string | undefined; }, { kind: "tool" | "memory" | "execution" | "policy" | "skill" | "prompt" | "mcp"; requestedAt: string; taskId: string; subjectHash: string; subjectRef: string; requestedBy: string; allowedDecisionScopes: string[]; metadata?: Record<string, unknown> | undefined; policyRef?: string | undefined; expiresAt?: string | undefined; reason?: string | undefined; activityDescriptorRef?: string | undefined; activityDescriptorHash?: string | undefined; providerRevision?: string | undefined; checkpointRef?: string | undefined; }>, { kind: "tool" | "memory" | "execution" | "policy" | "skill" | "prompt" | "mcp"; requestedAt: string; taskId: string; subjectHash: string; subjectRef: string; requestedBy: string; allowedDecisionScopes: string[]; metadata?: Record<string, unknown> | undefined; policyRef?: string | undefined; expiresAt?: string | undefined; reason?: string | undefined; activityDescriptorRef?: string | undefined; activityDescriptorHash?: string | undefined; providerRevision?: string | undefined; checkpointRef?: string | undefined; }, { kind: "tool" | "memory" | "execution" | "policy" | "skill" | "prompt" | "mcp"; requestedAt: string; taskId: string; subjectHash: string; subjectRef: string; requestedBy: string; allowedDecisionScopes: string[]; metadata?: Record<string, unknown> | undefined; policyRef?: string | undefined; expiresAt?: string | undefined; reason?: string | undefined; activityDescriptorRef?: string | undefined; activityDescriptorHash?: string | undefined; providerRevision?: string | undefined; checkpointRef?: string | undefined; }>;runtimeHumanTaskSchema
Runtime schema for Runtime Human Task.
- Kind: constant
- Import:
import { runtimeHumanTaskSchema } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
// Exact type resolved from the package entrypoint; see source for the compiler expansion.
export declare const runtimeHumanTaskSchema: (typeof import('@codesoul-co/hypha-core'))['runtimeHumanTaskSchema'];This compiler-expanded constant type is compacted. Its public name, top-level type, and source location remain here; use the module’s exported interfaces, types, or runtime schema for input/output fields.
validateRuntimeHumanTask
Validate Runtime Human Task function with 1 public call signature; parameters and return types are listed below.
- Kind: function
- Import:
import { validateRuntimeHumanTask } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare function validateRuntimeHumanTask(input: unknown): RuntimeHumanTask;Call signature
validateRuntimeHumanTask(input: unknown): RuntimeHumanTaskParameters
| Parameter | Type | Required | Description |
|---|---|---|---|
input | unknown | Yes | Required parameter; accepted values are defined by the type column. |
Returns
- Type:
RuntimeHumanTask - Description: The return contract is defined by the type shown above.
validateRuntimeHumanTaskDecisionCommand
Validate Runtime Human Task Decision Command function with 1 public call signature; parameters and return types are listed below.
- Kind: function
- Import:
import { validateRuntimeHumanTaskDecisionCommand } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare function validateRuntimeHumanTaskDecisionCommand(input: unknown): RuntimeHumanTaskDecisionCommand;Call signature
validateRuntimeHumanTaskDecisionCommand(input: unknown): RuntimeHumanTaskDecisionCommandParameters
| Parameter | Type | Required | Description |
|---|---|---|---|
input | unknown | Yes | Required parameter; accepted values are defined by the type column. |
Returns
- Type:
RuntimeHumanTaskDecisionCommand - Description: The return contract is defined by the type shown above.
validateRuntimeHumanTaskRequest
Validate Runtime Human Task Request function with 1 public call signature; parameters and return types are listed below.
- Kind: function
- Import:
import { validateRuntimeHumanTaskRequest } from '@codesoul-co/hypha-core'; - Source module:
contracts/runtime-human-task-schemas
Declaration
export declare function validateRuntimeHumanTaskRequest(input: unknown): RuntimeHumanTaskRequest;Call signature
validateRuntimeHumanTaskRequest(input: unknown): RuntimeHumanTaskRequestParameters
| Parameter | Type | Required | Description |
|---|---|---|---|
input | unknown | Yes | Required parameter; accepted values are defined by the type column. |
Returns
- Type:
RuntimeHumanTaskRequest - Description: The return contract is defined by the type shown above.
