import type { AdditionalToolDefinition } from '../contexts/ChatContext';
import type { FunctionToolPermission, AdditionalToolPreferences, AdditionalToolWithPermission } from '../types/additionalTools';
/**
 * Determines if a tool's permission can be configured by the user.
 * Tools with needsApproval set by developers are immutable.
 */
export declare const isToolPermissionConfigurable: (tool: AdditionalToolDefinition) => boolean;
/**
 * Gets the reason why a tool's permission is or isn't configurable
 */
export declare const getPermissionReason: (tool: AdditionalToolDefinition) => string;
/**
 * Resolves the effective permission for a tool based on developer settings and user preferences.
 * Priority order:
 * 1. Tool definition needsApproval (immutable) - highest priority
 * 2. User preference (stored) - if tool is configurable
 * 3. Default: 'enabled' - fallback
 */
export declare const resolveToolPermission: (tool: AdditionalToolDefinition, userPreferences: AdditionalToolPreferences) => FunctionToolPermission;
/**
 * Computes the complete permission state for an additional tool
 */
export declare const computeToolWithPermission: (tool: AdditionalToolDefinition, userPreferences: AdditionalToolPreferences) => AdditionalToolWithPermission;
/**
 * Loads additional tool preferences from localStorage
 */
export declare const loadAdditionalToolPreferences: () => AdditionalToolPreferences;
/**
 * Saves additional tool preferences to localStorage
 */
export declare const saveAdditionalToolPreferences: (preferences: AdditionalToolPreferences) => void;
/**
 * Updates a single tool's permission and persists to storage
 */
export declare const updateToolPermission: (toolName: string, permission: FunctionToolPermission, currentPreferences: AdditionalToolPreferences) => AdditionalToolPreferences;
/**
 * Removes a tool's permission override, reverting to default
 */
export declare const clearToolPermission: (toolName: string, currentPreferences: AdditionalToolPreferences) => AdditionalToolPreferences;
/**
 * Processes a list of additional tools, computing their permission states
 */
export declare const processAdditionalTools: (tools: AdditionalToolDefinition[], userPreferences?: AdditionalToolPreferences) => AdditionalToolWithPermission[];
//# sourceMappingURL=additionalToolPermissions.d.ts.map