import { type ConfigDocumentField, type ConnectorConfigDocument } from "./config-document.js"; import { type ExclusivePrivateFileSystem } from "./exclusive-private-file.js"; export declare const CONFIG_WORKBENCH_HTML_FORMAT = "guildcontrol.config-workbench-html.v1"; export declare const CONFIG_WORKBENCH_HTML_SCHEMA_VERSION = 1; declare const CONFIG_WORKBENCH_TOP_LEVEL_ORDER: readonly ["$schema", "capabilities", "credential", "gateway", "identity", "limits", "name", "observability", "readScope", "runtime", "schemaVersion", "scopes", "storage", "tools"]; declare const CONFIG_WORKBENCH_GROUPS: readonly [{ readonly description: "Format, policy name, external credential reference, and immutable Discord identity"; readonly id: "identity"; readonly label: "Identity and format"; }, { readonly description: "Exact guild boundary and optional exact channel boundary"; readonly id: "read"; readonly label: "Read boundary"; }, { readonly description: "Advertised MCP surface and risk-separated toolsets"; readonly id: "tools"; readonly label: "Tool surface"; }, { readonly description: "Optional privacy-safe real-time connection and bounded event memory"; readonly id: "gateway"; readonly label: "Gateway"; }, { readonly description: "Independent opt-in audit and write gates"; readonly id: "capabilities"; readonly label: "Capabilities"; }, { readonly description: "Exact Discord IDs that constrain each feature"; readonly id: "scopes"; readonly label: "Feature scopes"; }, { readonly description: "Bounded interaction, upload, and queue controls"; readonly id: "limits"; readonly label: "Limits"; }, { readonly description: "Content-free state and caller-owned local input roots"; readonly id: "storage"; readonly label: "Local storage"; }, { readonly description: "Non-secret runtime behavior"; readonly id: "runtime"; readonly label: "Runtime"; }, { readonly description: "Content-free local and OTLP diagnostics"; readonly id: "observability"; readonly label: "Observability"; }]; type ConfigWorkbenchGroupId = typeof CONFIG_WORKBENCH_GROUPS[number]["id"]; interface ConfigWorkbenchConstraint { enumValues?: readonly string[]; maximum?: number; maxItems?: number; maxLength?: number; minimum?: number; minItems?: number; minLength?: number; pattern?: string; referenceProviders?: readonly { field: "path" | "variable"; maximumLength?: number; minimumLength?: number; pattern?: string; provider: "environment" | "file"; }[]; } export interface ConfigWorkbenchField extends ConfigDocumentField { readonly constraints: ConfigWorkbenchConstraint; readonly editable: boolean; readonly group: ConfigWorkbenchGroupId; } export interface DiscordConfigWorkbenchModel { readonly activeDocument: ConnectorConfigDocument; readonly activeDocumentDigest: string; readonly activeFile: string; readonly candidateFilename: string; readonly connectorName: string; readonly connectorVersion: string; readonly fields: readonly ConfigWorkbenchField[]; readonly format: typeof CONFIG_WORKBENCH_HTML_FORMAT; readonly groups: typeof CONFIG_WORKBENCH_GROUPS; readonly platform: NodeJS.Platform; readonly schemaDigest: string; readonly schemaId: string; readonly schemaVersion: typeof CONFIG_WORKBENCH_HTML_SCHEMA_VERSION; readonly topLevelOrder: typeof CONFIG_WORKBENCH_TOP_LEVEL_ORDER; readonly toolsets: readonly string[]; } export interface DiscordConfigWorkbenchHtmlExportReport { readonly activeConfigurationWritten: false; readonly activeDocumentDigest: string; readonly activeFile: string; readonly automaticNetwork: "disabled"; readonly browserOpened: false; readonly bytes: number; readonly candidateAuthority: "explicit-download-only"; readonly candidateFilename: string; readonly configurationEmbedded: true; readonly credentialsEmbedded: false; readonly discordContacted: false; readonly externalNavigationOrigins: readonly []; readonly file: string; readonly format: typeof CONFIG_WORKBENCH_HTML_FORMAT; readonly htmlDigest: string; readonly outputFileCreated: true; readonly schemaDigest: string; readonly schemaVersion: typeof CONFIG_WORKBENCH_HTML_SCHEMA_VERSION; readonly secretValuesRead: false; readonly statePersistence: "disabled"; readonly status: "ok"; } export interface ConfigWorkbenchDirectoryMetadata { readonly mode: number; readonly uid: number; isDirectory(): boolean; isSymbolicLink(): boolean; } export interface ConfigWorkbenchFileSystem extends ExclusivePrivateFileSystem { lstat(path: string): Promise; realpath(path: string): Promise; } export interface DiscordConfigWorkbenchHtmlExportOptions { readonly fileSystem?: ConfigWorkbenchFileSystem; readonly platform?: NodeJS.Platform; readonly processUserId?: number; } export declare function createDiscordConfigWorkbenchModel(activeFile: string, documentValue: ConnectorConfigDocument, platform?: NodeJS.Platform): DiscordConfigWorkbenchModel; export declare function renderDiscordConfigWorkbenchHtml(model: DiscordConfigWorkbenchModel): string; export declare function exportDiscordConfigWorkbenchHtml(activeFile: string, outputFile: string, options?: DiscordConfigWorkbenchHtmlExportOptions): Promise; export {}; //# sourceMappingURL=config-workbench-html.d.ts.map