import { type CreateBotTemplateRequest, type WorkspaceBotTemplate } from "@opengeni/contracts"; export type BotTemplatesState = { /** Undefined until the first read settles. */ templates: WorkspaceBotTemplate[] | undefined; /** False on a server that doesn't keep bot templates. */ supported: boolean; error: Error | null; reload: () => void; /** Shows a change made here without reading the list again. */ replace: (update: (current: WorkspaceBotTemplate[]) => WorkspaceBotTemplate[]) => void; }; /** The bot templates saved in this workspace, read once per mount. */ export declare function useBotTemplates(workspaceId: string, options?: { enabled?: boolean; }): BotTemplatesState; /** A template's file name: its name in lowercase words, then `.bot.json`. */ export declare function botTemplateFileName(template: Pick): string; /** Download a template as a file someone can import into their workspace. */ export declare function downloadBotTemplate(template: WorkspaceBotTemplate): void; /** The create request in an exported template file, or why it isn't one. */ export declare function parseBotTemplateFile(text: string): { ok: true; request: CreateBotTemplateRequest; } | { ok: false; error: string; };