import type { CordisContext, SettingsAPI, SettingsResult, NamespaceView } from '../types.js'; /** * Official browser-writable settings namespaces (dsh-host-apiproxy * WEB_SETTINGS_NAMESPACES), as documented in dsh-upstream-fixes/README.md. * Product namespaces and dynamic model-provider namespaces are not enumerable * without dsh internals; callers may extend this set via `extraWhitelist`. */ export declare const DEFAULT_WEB_SETTINGS_NAMESPACES: Set; /** A raw settings descriptor returned by the real settings service. */ interface SettingsDescriptor { ns: string; schema: any; value: any; base?: any; user?: any; applies?: any; secrets?: { path: string[]; set?: any; }[]; revision?: any; } /** * Shape a raw settings descriptor into the official NamespaceView wire shape * (mirrors dsh-upstream-fixes/lib/index.js `namespaceView`). */ export declare function toNamespaceView(descriptor: SettingsDescriptor): NamespaceView; /** * Map a thrown settings error into a SettingsResult, preserving the official * `settings-conflict` / `settings-rejected` classification. */ export declare function settingsErrorToResult(error: unknown, ns: string, method: string): SettingsResult; /** * Build the `ctx.dshLoader.settings` stable API. */ export declare function createSettingsAPI(opts: { ctx: CordisContext; exposeAllNamespaces: boolean; whitelist?: Set; /** The real `@deepseek-ai/dsh-settings` module, when it resolved at boot. */ module?: { installSettingsSection?: (ctx: unknown, ns: unknown, schema: unknown, entry: unknown, hooks: unknown) => void; settingsNamespace?: (id: string) => unknown; SettingsConflictError?: new (...args: never[]) => Error; }; }): SettingsAPI; export {};