import { z } from '@botpress/sdk';
import { BotHandlers } from '@botpress/sdk/dist/bot';
import { ZuiType } from '../types';
import { Definitions } from './definition';
import { Defined } from '../utilities/types';
type ActionHandler = Defined<BotHandlers<any>['actionHandlers'][string]>;
type ActionHandlerInput = ActionHandler extends (input: infer I) => Promise<any> ? I : never;
export declare namespace Typings {
    type Props<TInput extends ZuiType = ZuiType, TOutput extends ZuiType = ZuiType> = {
        name: string;
        title?: string;
        description?: string;
        attributes?: Record<string, string>;
        input: TInput;
        output: TOutput;
        cached?: boolean;
        handler: (input: z.infer<TInput>) => Promise<z.infer<TOutput>>;
    };
    const Primitive: "action";
}
export declare class BaseAction<TInput extends ZuiType, TOutput extends ZuiType> implements Definitions.Primitive {
    readonly name: string;
    readonly title?: string;
    readonly description?: string;
    readonly attributes?: Record<string, string>;
    readonly input: TInput;
    readonly output: TOutput;
    readonly cached: boolean;
    readonly handler: (input: z.infer<TInput>) => Promise<z.infer<TOutput>>;
    constructor(props: Typings.Props<TInput, TOutput>);
    /**
     * Execute the action with input validation and output validation
     */
    execute({ input }: ActionHandlerInput): Promise<z.infer<TOutput>>;
}
export {};
//# sourceMappingURL=action.d.ts.map