A11 TypeScript API - v0.7.26
    Preparing search index...

    Interface A11FlowRunnerBridge

    Stable worker bridge consumed by the SDK's native graph conveniences.

    interface A11FlowRunnerBridge {
        action(
            name: string,
            id?: string,
            sessionId?: string,
            streamId?: string,
            settings?: ActionSettings,
            schema?: Record<string, unknown>,
        ): ActionBinding;
        actionRegistryHas(name: string): Promise<boolean>;
        actionRegistryMessage(
            name: string,
            actionId?: string,
        ): Promise<Record<string, unknown>>;
        actionRegistryNames(): Promise<string[]>;
        actionRegistrySchema(name: string): Promise<Record<string, unknown>>;
        createChannelStream(
            channel: BinaryChannel,
            id: string,
            role: ChannelEndpointRole,
            options: WireStreamOptions,
            framing: ChannelFramingOptions,
        ): Promise<ChannelHandle>;
        discardNode(id: string): Promise<boolean>;
        dispose(): void | Promise<void>;
        flushPersistence?(): Promise<void>;
        hasNode(id: string): Promise<boolean>;
        node(id: string): NodeBinding;
        nodeMapIds(): Promise<string[]>;
        nodeMapSize(): Promise<number>;
        registerRunnableAction(
            schema: Record<string, unknown>,
            handler: (
                action: ActionBinding,
                context: { signal?: AbortSignal },
            ) => Promise<void | Status>,
        ): Promise<() => Promise<void>>;
        registerSchema(
            schema: Record<string, unknown>,
        ): Promise<() => Promise<void>>;
        resolveNode(reference: Record<string, unknown>): Promise<{ id: string }>;
        runFlow(
            request: Record<string, unknown>,
            options?: {
                onOutput?: (port: string, chunk: Record<string, unknown>) => void;
                signal?: AbortSignal;
            },
        ): Promise<Record<string, unknown>>;
        session(
            id?: string,
            options?: Record<string, unknown>,
            callbacks?: {
                onDone?: (stream: WireStream) => Promise<void | Status>;
                onMessage?: (
                    message: Record<string, unknown> | null,
                    stream: WireStream,
                ) => Promise<void | Status>;
            },
        ): SessionBinding;
        store(id: string): WorkerStoreHandle;
        unregisterRegisteredAction(name: string): Promise<void>;
    }

    Hierarchy (View Summary)

    • FlowRunnerBridge
    • GraphBinding
    • ChannelBridge
      • A11FlowRunnerBridge
    Index
    • Parameters

      • schema: Record<string, unknown>
      • handler: (
            action: ActionBinding,
            context: { signal?: AbortSignal },
        ) => Promise<void | Status>

      Returns Promise<() => Promise<void>>

    • Parameters

      • request: Record<string, unknown>
      • Optionaloptions: {
            onOutput?: (port: string, chunk: Record<string, unknown>) => void;
            signal?: AbortSignal;
        }

      Returns Promise<Record<string, unknown>>

    • Parameters

      • Optionalid: string
      • Optionaloptions: Record<string, unknown>
      • Optionalcallbacks: {
            onDone?: (stream: WireStream) => Promise<void | Status>;
            onMessage?: (
                message: Record<string, unknown> | null,
                stream: WireStream,
            ) => Promise<void | Status>;
        }

      Returns SessionBinding