UNPKG

@hyperbrowser/agent

Version:

Hyperbrowsers Web Agent

20 lines (19 loc) 900 B
import { z } from "zod"; import { ActionOutput, AgentActionDefinition } from "../types"; export declare const UserInteractionActionParams: z.ZodObject<{ message: z.ZodString; kind: z.ZodEnum<["password", "text_input", "select", "confirm"]>; choices: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; }, "strip", z.ZodTypeAny, { message: string; kind: "select" | "password" | "text_input" | "confirm"; choices?: string[] | undefined; }, { message: string; kind: "select" | "password" | "text_input" | "confirm"; choices?: string[] | undefined; }>; export type UserInteractionActionParamsType = typeof UserInteractionActionParams; type userInputFn = (params: z.infer<UserInteractionActionParamsType>) => Promise<ActionOutput>; export declare const UserInteractionAction: (userInputFn: userInputFn) => AgentActionDefinition<UserInteractionActionParamsType>; export {};