/** * UserPromptSubmit hook event. * * Fires when the user submits a prompt, before Claude processes it. A * handler can block the prompt entirely (erasing it from context), * inject additional context, or rename the session. Does not support * a matcher. See https://code.claude.com/docs/en/hooks#userpromptsubmit. * * @since 0.1.0 */ import * as Effect from 'effect/Effect'; import * as Schema from 'effect/Schema'; import type { HookContext } from '../Context.js'; import type { HookDefinition } from '../Runner.js'; declare const Input_base: Schema.Class; readonly prompt: Schema.String; readonly session_id: Schema.String; readonly transcript_path: Schema.String; readonly cwd: Schema.String; readonly permission_mode: Schema.optionalKey; readonly effort: Schema.optionalKey; readonly agent_id: Schema.optionalKey; readonly agent_type: Schema.optionalKey; }>, {}>; export declare class Input extends Input_base { } declare const HookSpecificOutput_base: Schema.Class; readonly additionalContext: Schema.optional; readonly sessionTitle: Schema.optional; }>, {}>; export declare class HookSpecificOutput extends HookSpecificOutput_base { } declare const Output_base: Schema.Class>; readonly reason: Schema.optional; readonly suppressOriginalPrompt: Schema.optional; readonly continue: Schema.optional; readonly stopReason: Schema.optional; readonly suppressOutput: Schema.optional; readonly systemMessage: Schema.optional; readonly terminalSequence: Schema.optional; readonly hookSpecificOutput: Schema.optional; }>, {}>; export declare class Output extends Output_base { } /** * Allow the prompt to proceed without modification. * * @category Decisions * @since 0.1.0 */ export declare const allow: () => Output; /** * Block the prompt. It is erased from context and the reason is shown * to the user. * * @category Decisions * @since 0.1.0 */ export declare const block: (reason: string, options?: { readonly suppressOriginalPrompt?: boolean; }) => Output; /** * Allow the prompt and inject additional context Claude will see. * * @category Decisions * @since 0.1.0 */ export declare const addContext: (additionalContext: string) => Output; /** * Rename the session title. Often paired with `addContext`. * * @category Decisions * @since 0.1.0 */ export declare const renameSession: (sessionTitle: string, additionalContext?: string) => Output; export declare const define: (config: { readonly handler: (input: Input) => Effect.Effect; }) => HookDefinition; export {}; //# sourceMappingURL=UserPromptSubmit.d.ts.map