import type { PermissionMode } from './permissions.js'; import type { SettingSource } from './options.js'; /** * Settings fields with a verified qodercli execution path. * * Unknown keys remain pass-through so callers can use settings introduced by * a newer paired CLI, but the SDK only gives first-class types to capabilities * that are implemented and tested. */ export interface Settings { general?: { fileCheckpointing?: { enabled?: boolean; [k: string]: unknown; }; [k: string]: unknown; }; security?: { disableYoloMode?: boolean; [k: string]: unknown; }; permissions?: { allow?: string[]; deny?: string[]; ask?: string[]; defaultMode?: PermissionMode; disableBypassPermissionsMode?: 'disable'; additionalDirectories?: string[]; [k: string]: unknown; }; mcp?: { lazyLoad?: boolean; [k: string]: unknown; }; model?: string; outputStyle?: string; skillOverrides?: Record; skillListingMaxDescChars?: number; skillListingBudgetFraction?: number; enabledPlugins?: Record>; pluginConfigs?: Record>; }>; [k: string]: unknown; } export type ResolvedSettingSource = SettingSource; export type ResolvedSettingsSource = { source: ResolvedSettingSource; settings: Settings; path?: string; }; export type SettingsProvenanceEntry = { source: ResolvedSettingSource; path?: string; }; export type ResolveSettingsOptions = { /** Directory used to resolve project and local settings. */ cwd?: string; /** Filesystem settings sources to load. Omit for all sources; pass [] for none. */ settingSources?: SettingSource[]; }; export type ResolvedSettings = { effective: Settings; provenance: Record; sources: ResolvedSettingsSource[]; }; /** * Filters escalating project default modes before SDK settings are applied. * * When the effective `permissions.defaultMode` is an escalating mode and the * winning source is project settings, remove that default mode from the * returned settings. Callers should use this before acting on resolved project * settings in SDK-hosted settings flows. */ export declare function filterEscalatingDefaultMode(resolved: ResolvedSettings): Settings;