import type { ConfigFormat, ConfigObject, ConfigValue } from "../types.js"; declare function detectIndent(content: string): string; /** * Modify JSON content at a specific path while preserving comments and formatting. * Uses jsonc-parser's modify() for targeted updates. * * @param content - The original JSON content (may include comments) * @param path - JSON path array, e.g. ["mcpServers", "my-server"] * @param value - The value to set (or undefined to remove) * @returns The modified JSON content with comments preserved */ declare function modifyAtPath(content: string, path: (string | number)[], value: ConfigValue | undefined): string; /** * Merge a patch into JSON content while preserving comments and formatting. * Uses jsonc.modify() for each top-level key to preserve existing comments. * * @param content - The original JSON content (may include comments) * @param patch - Object with values to merge * @returns The modified JSON content with comments preserved */ declare function mergePreservingComments(content: string, patch: ConfigObject): string; /** * Remove a key from JSON content while preserving comments and formatting. * * @param content - The original JSON content * @param path - JSON path array to the key to remove * @returns The modified JSON content with comments preserved */ declare function removeAtPath(content: string, path: (string | number)[]): string; declare function serializeUpdate(content: string, current: ConfigObject, next: ConfigObject): string; export { detectIndent, modifyAtPath, mergePreservingComments, removeAtPath, serializeUpdate }; export declare const jsonFormat: ConfigFormat;