export type LspApplyCodeActionBoundary = "input" | "contract" | "governance" | "scope" | "environment";
export type LspApplyCodeActionGate = {
    accepted: boolean;
    reason?: string;
};
export type LspCodeActionEditPreview = {
    filesTouched?: readonly string[];
    diagnosticsResolved?: readonly string[];
    summary?: string;
};
export type LspApplyCodeActionRequest = {
    runtimeId?: string;
    sessionId?: string;
    workspaceRoot?: string;
    documentUri?: string;
    actionId?: string;
    actionTitle?: string;
    actionKind?: string;
    editPreview?: LspCodeActionEditPreview;
    requestedScopes?: readonly string[];
    allowedScopes?: readonly string[];
    lspClientReady?: boolean;
    dryRun?: boolean;
    contract?: LspApplyCodeActionGate;
    governance?: LspApplyCodeActionGate;
    auditContext?: Record<string, unknown>;
};
export type LspApplyCodeActionErrorCode = "MISSING_RUNTIME_ID" | "MISSING_SESSION_ID" | "MISSING_WORKSPACE_ROOT" | "MISSING_DOCUMENT_URI" | "MISSING_CODE_ACTION" | "LSP_CLIENT_NOT_READY" | "CONTRACT_REJECTED" | "GOVERNANCE_REJECTED" | "SCOPE_DENIED" | "REAL_SIDE_EFFECT_NOT_ALLOWED";
export type LspApplyCodeActionError = {
    code: LspApplyCodeActionErrorCode;
    message: string;
    boundary: LspApplyCodeActionBoundary;
    safeForRuntimeInspection: true;
    internalDetailExposed: false;
};
export type LspApplyCodeActionPlan = {
    toolId: "code.lsp_applyCodeAction";
    capability: "apply-lsp-code-action";
    runtimeId: string;
    sessionId: string;
    workspaceRoot: string;
    documentUri: string;
    action: {
        id?: string;
        title: string;
        kind?: string;
    };
    permissions: {
        required: readonly ["tool:lsp", "workspace:read", "workspace:write"];
        acceptedScopes: readonly string[];
        approvalRequired: true;
    };
    execution: {
        dryRun: true;
        lspInvoked: false;
        editApplied: false;
        unsafeSideEffects: false;
    };
    audit: {
        event: "basicTool.lsp.applyCodeAction.planned";
        editPreview?: LspCodeActionEditPreview;
        auditContext: Readonly<Record<string, unknown>>;
    };
};
export type LspApplyCodeActionResult = {
    ok: true;
    plan: LspApplyCodeActionPlan;
    events: readonly string[];
} | {
    ok: false;
    error: LspApplyCodeActionError;
    events: readonly string[];
};
export declare const lspApplyCodeActionDescriptor: {
    readonly toolId: "code.lsp_applyCodeAction";
    readonly capability: "apply-lsp-code-action";
    readonly layer: "agent_executionEngine.basic_toolLayer.baseTools.codeBase.lsp";
    readonly purpose: "plan and audit an LSP code action application without applying edits";
    readonly sideEffectPolicy: "dry-run-only";
    readonly requiresApproval: true;
};
export declare function planLspApplyCodeAction(request?: LspApplyCodeActionRequest): LspApplyCodeActionResult;
