import type { ModelMessage } from 'ai';
import type { AgentLayerToolOutput } from '../messages';
import { type DoneResult, type PostToolUseResult } from './results';
import type { HookChainStateResult, HookStateAccess, ToolInfo } from './shared';
export interface PostToolUseHookContext extends HookStateAccess {
    toolName: string;
    toolCallId: string;
    input: Record<string, unknown>;
    output: AgentLayerToolOutput;
    rawOutput: unknown;
    tool: ToolInfo;
    getContextWindow: () => ReadonlyArray<ModelMessage>;
    done(mutatedResult?: string): DoneResult;
}
export type PostToolUseHook = (ctx: PostToolUseHookContext) => PostToolUseResult | Promise<PostToolUseResult>;
interface PostToolUseChainInput {
    toolName: string;
    toolCallId: string;
    input: Record<string, unknown>;
    output: AgentLayerToolOutput;
    rawOutput: unknown;
    tool: ToolInfo;
    getContextWindow: () => ReadonlyArray<ModelMessage>;
    state?: Record<string, unknown>;
}
export declare function runPostToolUseHooks(hooks: PostToolUseHook[], baseCtx: PostToolUseChainInput): Promise<HookChainStateResult<PostToolUseResult>>;
export {};
//# sourceMappingURL=post-tool-use.d.ts.map