import { type Static } from "../core/utils";
import * as tbbox from "@sinclair/typebox";
export declare const TASKS: {
    readonly fetch: {
        readonly cls: typeof import("../flows").FetchTask;
    };
    readonly log: {
        readonly cls: typeof import("../flows").LogTask;
    };
    readonly render: {
        readonly cls: typeof import("../flows").RenderTask;
    };
    readonly subflow: {
        readonly cls: typeof import("../flows").SubFlowTask;
    };
};
export declare const TRIGGERS: {
    readonly manual: {
        readonly cls: typeof import("../flows").Trigger;
    };
    readonly event: {
        readonly cls: typeof import("../flows").EventTrigger;
    };
    readonly http: {
        readonly cls: typeof import("../flows").HttpTrigger;
    };
};
declare const taskSchema: tbbox.TUnion<tbbox.TObject<{
    type: tbbox.TLiteral<"log" | "fetch" | "render" | "subflow">;
    params: tbbox.TObject<{
        url: tbbox.TString;
        method: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
            title: string;
        } & tbbox.TUnsafe<string>, tbbox.TString]>, string>>;
        headers: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
            title: string;
        } & tbbox.TArray<tbbox.TObject<{
            key: tbbox.TString;
            value: tbbox.TString;
        }>>, tbbox.TString]>, {
            key: string;
            value: string;
        }[]>>;
        body: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
            title: string;
        } & tbbox.TString, tbbox.TString]>, string>>;
        normal: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
            title: string;
        } & tbbox.TNumber, tbbox.TString]>, number>>;
    }> | tbbox.TObject<{
        delay: tbbox.TNumber;
    }> | tbbox.TObject<{
        render: tbbox.TString;
    }> | tbbox.TObject<{
        flow: tbbox.TAny;
        input: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
            title: string;
        } & tbbox.TAny, tbbox.TString]>, any>>;
        loop: tbbox.TOptional<tbbox.TBoolean>;
    }>;
}>[]>;
export type TAppFlowTaskSchema = Static<typeof taskSchema>;
export declare const flowSchema: tbbox.TObject<{
    trigger: tbbox.TUnion<tbbox.TObject<{
        type: tbbox.TLiteral<"manual" | "event" | "http">;
        config: tbbox.TObject<{
            mode: tbbox.TUnsafe<"sync" | "async">;
        }> | tbbox.TObject<{
            mode: tbbox.TUnsafe<"sync" | "async">;
            event: tbbox.TString;
        }> | tbbox.TObject<{
            mode: tbbox.TUnsafe<"sync" | "async">;
            path: tbbox.TString;
            method: tbbox.TUnsafe<"GET" | "POST" | "PATCH" | "PUT" | "DELETE">;
            response_type: tbbox.TUnsafe<"json" | "text" | "html">;
        }>;
    }>[]>;
    tasks: tbbox.TOptional<tbbox.TRecord<tbbox.TString, tbbox.TUnion<tbbox.TObject<{
        type: tbbox.TLiteral<"log" | "fetch" | "render" | "subflow">;
        params: tbbox.TObject<{
            url: tbbox.TString;
            method: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                title: string;
            } & tbbox.TUnsafe<string>, tbbox.TString]>, string>>;
            headers: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                title: string;
            } & tbbox.TArray<tbbox.TObject<{
                key: tbbox.TString;
                value: tbbox.TString;
            }>>, tbbox.TString]>, {
                key: string;
                value: string;
            }[]>>;
            body: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                title: string;
            } & tbbox.TString, tbbox.TString]>, string>>;
            normal: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                title: string;
            } & tbbox.TNumber, tbbox.TString]>, number>>;
        }> | tbbox.TObject<{
            delay: tbbox.TNumber;
        }> | tbbox.TObject<{
            render: tbbox.TString;
        }> | tbbox.TObject<{
            flow: tbbox.TAny;
            input: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                title: string;
            } & tbbox.TAny, tbbox.TString]>, any>>;
            loop: tbbox.TOptional<tbbox.TBoolean>;
        }>;
    }>[]>>>;
    connections: tbbox.TOptional<tbbox.TRecord<tbbox.TString, tbbox.TObject<{
        source: tbbox.TString;
        target: tbbox.TString;
        config: tbbox.TObject<{
            condition: tbbox.TOptional<tbbox.TUnion<[tbbox.TObject<{
                type: tbbox.TLiteral<"success">;
            }>, tbbox.TObject<{
                type: tbbox.TLiteral<"error">;
            }>, tbbox.TObject<{
                type: tbbox.TLiteral<"matches">;
                path: tbbox.TString;
                value: tbbox.TString;
            }>]>>;
            max_retries: tbbox.TOptional<tbbox.TNumber>;
        }>;
    }>>>;
    start_task: tbbox.TOptional<tbbox.TString>;
    responding_task: tbbox.TOptional<tbbox.TString>;
}>;
export type TAppFlowSchema = Static<typeof flowSchema>;
export declare const flowsConfigSchema: tbbox.TObject<{
    basepath: tbbox.TString;
    flows: tbbox.TRecord<tbbox.TString, tbbox.TObject<{
        trigger: tbbox.TUnion<tbbox.TObject<{
            type: tbbox.TLiteral<"manual" | "event" | "http">;
            config: tbbox.TObject<{
                mode: tbbox.TUnsafe<"sync" | "async">;
            }> | tbbox.TObject<{
                mode: tbbox.TUnsafe<"sync" | "async">;
                event: tbbox.TString;
            }> | tbbox.TObject<{
                mode: tbbox.TUnsafe<"sync" | "async">;
                path: tbbox.TString;
                method: tbbox.TUnsafe<"GET" | "POST" | "PATCH" | "PUT" | "DELETE">;
                response_type: tbbox.TUnsafe<"json" | "text" | "html">;
            }>;
        }>[]>;
        tasks: tbbox.TOptional<tbbox.TRecord<tbbox.TString, tbbox.TUnion<tbbox.TObject<{
            type: tbbox.TLiteral<"log" | "fetch" | "render" | "subflow">;
            params: tbbox.TObject<{
                url: tbbox.TString;
                method: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                    title: string;
                } & tbbox.TUnsafe<string>, tbbox.TString]>, string>>;
                headers: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                    title: string;
                } & tbbox.TArray<tbbox.TObject<{
                    key: tbbox.TString;
                    value: tbbox.TString;
                }>>, tbbox.TString]>, {
                    key: string;
                    value: string;
                }[]>>;
                body: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                    title: string;
                } & tbbox.TString, tbbox.TString]>, string>>;
                normal: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                    title: string;
                } & tbbox.TNumber, tbbox.TString]>, number>>;
            }> | tbbox.TObject<{
                delay: tbbox.TNumber;
            }> | tbbox.TObject<{
                render: tbbox.TString;
            }> | tbbox.TObject<{
                flow: tbbox.TAny;
                input: tbbox.TOptional<tbbox.TTransform<tbbox.TUnion<[{
                    title: string;
                } & tbbox.TAny, tbbox.TString]>, any>>;
                loop: tbbox.TOptional<tbbox.TBoolean>;
            }>;
        }>[]>>>;
        connections: tbbox.TOptional<tbbox.TRecord<tbbox.TString, tbbox.TObject<{
            source: tbbox.TString;
            target: tbbox.TString;
            config: tbbox.TObject<{
                condition: tbbox.TOptional<tbbox.TUnion<[tbbox.TObject<{
                    type: tbbox.TLiteral<"success">;
                }>, tbbox.TObject<{
                    type: tbbox.TLiteral<"error">;
                }>, tbbox.TObject<{
                    type: tbbox.TLiteral<"matches">;
                    path: tbbox.TString;
                    value: tbbox.TString;
                }>]>>;
                max_retries: tbbox.TOptional<tbbox.TNumber>;
            }>;
        }>>>;
        start_task: tbbox.TOptional<tbbox.TString>;
        responding_task: tbbox.TOptional<tbbox.TString>;
    }>>;
}>;
export {};
