import { Hash } from 'viem';
import { TransactionTask } from '../util/transactionTask';
export type TransactionTaskEntry = {
    id: string;
    request: TransactionTask;
    result?: TaskResult;
    createdAt: Date;
};
type TaskResult = {
    type: 'success';
    hash: Hash;
} | {
    type: 'error';
    error: Error;
};
type TransactionTaskStore = {
    taskEntryById: Record<string, TransactionTaskEntry>;
    createTask: (task: TransactionTask) => void;
    completeTask: (id: string, result: TaskResult) => void;
};
export declare const useTransactionTaskStore: import("zustand").UseBoundStore<Omit<import("zustand").StoreApi<TransactionTaskStore>, "setState"> & {
    setState(nextStateOrUpdater: TransactionTaskStore | Partial<TransactionTaskStore> | ((state: import("immer").WritableDraft<TransactionTaskStore>) => void), shouldReplace?: false): void;
    setState(nextStateOrUpdater: TransactionTaskStore | ((state: import("immer").WritableDraft<TransactionTaskStore>) => void), shouldReplace: true): void;
}>;
export declare const requestTransactionTask: (task: TransactionTask) => Promise<Hash>;
export declare const onNewTask: (task: TransactionTask) => void;
export declare const onTaskSuccess: (id: string, hash: Hash) => void;
export declare const onTaskError: (id: string, error: Error) => void;
export {};
