export type ShellEnvironmentInspectionPermission = "shell:environment:inspect" | "filesystem:read";
export type ShellEnvironmentInspectionBoundary = "input" | "scope" | "permission" | "contract" | "governance" | "provider";
export type ShellEnvironmentInspectionContext = {
    runtimeId?: string;
    sessionId?: string;
    invocationId?: string;
    dryRun?: boolean;
    guard?: {
        allowed?: boolean;
        accepted?: boolean;
        reason?: string;
    };
    allowedWorkingDirectories?: readonly string[];
    grantedPermissions?: readonly ShellEnvironmentInspectionPermission[];
    auditMetadata?: Readonly<Record<string, unknown>>;
};
export type ShellEnvironmentSnapshot = Readonly<Record<string, string | undefined>>;
export type ShellEnvironmentInspectionTarget = {
    workingDirectory: string;
    shellExecutable?: string;
    environment?: ShellEnvironmentSnapshot;
    variablesToInspect?: readonly string[];
};
export type ShellEnvironmentInspectionRequest = {
    target?: Partial<ShellEnvironmentInspectionTarget>;
    context?: ShellEnvironmentInspectionContext;
    provider?: ShellEnvironmentInspectionProvider;
};
export type ShellEnvironmentInspectionErrorCode = "MISSING_WORKING_DIRECTORY" | "INVALID_SHELL_EXECUTABLE" | "INVALID_ENVIRONMENT" | "INVALID_VARIABLE_NAME" | "SCOPE_REJECTED" | "PERMISSION_DENIED" | "REAL_INSPECTION_BLOCKED" | "GOVERNANCE_REJECTED" | "PROVIDER_UNAVAILABLE" | "PROVIDER_REJECTED";
export type ShellEnvironmentInspectionError = {
    code: ShellEnvironmentInspectionErrorCode;
    message: string;
    boundary: ShellEnvironmentInspectionBoundary;
    publicSafe: true;
    safeForRuntimeInspection: true;
    internalDetailExposed: false;
};
export type ShellEnvironmentInspectionAuditEvent = {
    type: string;
    toolId: "shell.environmentInspection";
    invocationId: string;
    dryRun: boolean;
    workingDirectory?: string;
    metadata: Readonly<Record<string, unknown>>;
};
export type ShellEnvironmentVariableReport = {
    name: string;
    present: boolean;
    redacted: boolean;
    valuePreview?: string;
};
export type ShellEnvironmentInspectionOutput = {
    kind: "agentCore.basicTool.shell.environmentInspection";
    target: Pick<ShellEnvironmentInspectionTarget, "workingDirectory" | "shellExecutable">;
    variables: readonly ShellEnvironmentVariableReport[];
    pathEntries: readonly string[];
    permissionsRequired: readonly ShellEnvironmentInspectionPermission[];
    dryRun: boolean;
    executionBlocked: boolean;
    unsafeSideEffects: false;
    inspectionEnvelope: {
        operation: "inspect-shell-environment";
        source: "provided-snapshot";
        realProcessReadRequired: boolean;
    };
};
export type ShellEnvironmentInspectionProviderRequest = {
    target: ShellEnvironmentInspectionTarget;
    context?: ShellEnvironmentInspectionContext;
};
export type ShellEnvironmentInspectionProvider = (request: ShellEnvironmentInspectionProviderRequest) => ShellEnvironmentInspectionOutput | Promise<ShellEnvironmentInspectionOutput>;
export type ShellEnvironmentInspectionResult = {
    ok: true;
    toolId: "shell.environmentInspection";
    output: ShellEnvironmentInspectionOutput;
    audit: readonly ShellEnvironmentInspectionAuditEvent[];
    events: readonly string[];
} | {
    ok: false;
    toolId: "shell.environmentInspection";
    error: ShellEnvironmentInspectionError;
    audit: readonly ShellEnvironmentInspectionAuditEvent[];
    events: readonly string[];
};
export declare const shellEnvironmentInspectionDescriptor: {
    readonly toolId: "shell.environmentInspection";
    readonly capability: "inspect-shell-environment";
    readonly route: "agent_executionEngine.basic_toolLayer.baseTools.shellBase.shellDetection";
    readonly defaultDryRun: true;
    readonly tapOwnsApproval: true;
    readonly permissionsRequired: readonly ["shell:environment:inspect"];
    readonly unsafeSideEffects: false;
};
export declare function inspectShellEnvironment(request?: ShellEnvironmentInspectionRequest): ShellEnvironmentInspectionResult;
export declare function executeShellEnvironmentInspection(request?: ShellEnvironmentInspectionRequest): Promise<ShellEnvironmentInspectionResult>;
