Skip to content

wire

@fungi.computer/whistle


@fungi.computer/whistle / wire

const WhistleAvailabilitySchema: ZodDiscriminatedUnion<[ZodObject<{ status: ZodLiteral<"available">>; }, $strict>>, ZodObject<{ status: ZodLiteral<"unavailable">>; reason: ZodString; }, $strict>>], "status">>

Host-owned availability carried by every discovered agent row.


const WhistleJsonValueSchema: ZodType<WhistleJsonValue, unknown, $ZodTypeInternals<WhistleJsonValue, unknown>>>>

The JSON value grammar shared by Whistle transports and App adapters.


const WhistleJsonObjectSchema: ZodType<WhistleJsonObject, unknown, $ZodTypeInternals<WhistleJsonObject, unknown>>>>

One JSON object, used for action schemas and custom presentation data.


const WhistleFailureSchema: ZodType<Readonly<{ code: string; message: string; details?: WhistleJsonValue; }>, unknown, $ZodTypeInternals<Readonly<{ code: string; message: string; details?: WhistleJsonValue; }>, unknown>>>>

General portable failure data for adapters that cross a transport.


const WhistleActionSchemaSchema: z.ZodType<WhistleActionSchema> > = WhistleJsonObjectSchema

The JSON object shape used by Whistle action schemas.


const WhistleAgentProjectionSchema: z.ZodType<WhistleAgentProjection>>

One neutral agent row emitted by Whistle’s snapshot.agent projection.


const WhistleAgentProjectionsSchema: z.ZodType<readonly WhistleAgentProjection[]>

A neutral Whistle agent projection collection.


const interactionTextLimit: 8192 = 8192

Longest prompt answer or message an interaction carries.

parseJsonValue(value): WhistleJsonValue

Parse copied JSON data at an untrusted transport boundary.

unknown

WhistleJsonValue


parseJsonObject(value): WhistleJsonObject

Parse a copied JSON object at an untrusted transport boundary.

unknown

WhistleJsonObject


parseFailure(value): WhistleFailure

Parse failure data without carrying an Error or stack across the wire.

unknown

WhistleFailure


parseAction(value): WhistleAction

Parse action metadata once before an adapter constructs a Whistle command.

unknown

WhistleAction


parseProjections(value): WhistleCommandProjections

Parse the Whistle-owned projection metadata supplied by an App.

unknown

WhistleCommandProjections


parseAvailability(value): WhistleAvailability

Parse an availability fact while preserving its reason.

unknown

WhistleAvailability


parseCommandDefinition(value): WhistleCommandDefinition

Parse one data-only command definition before an adapter creates a command.

unknown

WhistleCommandDefinition


parse(value): readonly WhistleAgentProjection[]

Decode an untrusted agent projection collection at the wire boundary.

unknown

readonly WhistleAgentProjection[]


parsePrompt(value): WhistlePrompt

Parse one interaction prompt at the boundary where a client renders it.

unknown

WhistlePrompt


parseNotice(value): WhistleNotice

Parse one interaction notice at the boundary where a client renders it.

unknown

WhistleNotice


parsePromptAnswer(prompt, value): string | boolean

Parse the answer a human gave to one prompt before the command sees it.

WhistlePrompt

unknown

string | boolean