/** * Schéma Zod de la config d'application — validé au resolve de `defineConfig` (D1). * * Vit dans le CORE (zod = peerDep core, back-only) : `import { defineConfig } from * "nodefony"` valide tout seul, sans que chaque app porte son propre schéma. But : * planter PROPREMENT au boot (message clair) sur une config malformée, plutôt qu'un * `Cannot read properties of undefined` plus tard en runtime. * * Le schéma DÉCRIT (il ne dérive pas les défauts — ceux-ci sont dans `./defaults`). * Tous les champs sont `.optional()` : il rejette les TYPES/valeurs invalides, pas * l'absence (le merge a déjà rempli les défauts ; le Kernel a des fallbacks * résiduels). Les clés inconnues — `module-` (overrides validés par chaque * module), `App`, `cluster`… — sont ignorées (objet zod non-strict). */ import { z } from "zod"; /** * Schéma de la config app résolue. Exposé pour l'introspection (Studio : * `z.toJSONSchema(appConfigSchema)` → panneau de config + formulaire éditable). * * Chaque champ porte un `.describe()` FR (rôle + défaut) → consommé par le * panneau de config Studio (`/nodefony/config`, carte de l'app). */ export declare const appConfigSchema: z.ZodObject<{ modules: z.ZodOptional>; locale: z.ZodOptional; templating: z.ZodOptional; orm: z.ZodOptional; packageManager: z.ZodOptional>; domain: z.ZodOptional; domainAlias: z.ZodOptional>; domainCheck: z.ZodOptional; servers: z.ZodOptional; http: z.ZodOptional; }, z.core.$strip>, z.ZodLiteral]>>; https: z.ZodOptional; protocol: z.ZodOptional>; }, z.core.$strip>, z.ZodLiteral]>>; h2c: z.ZodOptional; port: z.ZodOptional; }, z.core.$strict>>; ws: z.ZodOptional>; wss: z.ZodOptional>; portPolicy: z.ZodOptional>; portRetryAttempts: z.ZodOptional; }, z.core.$strip>>; cluster: z.ZodOptional; timing: z.ZodOptional>; verbose: z.ZodOptional; tooling: z.ZodOptional; }, z.core.$strict>>; shutdownDeadline: z.ZodOptional; log: z.ZodOptional; debug: z.ZodOptional]>>; requestFormat: z.ZodOptional>; buffered: z.ZodOptional]>>; driver: z.ZodOptional>; format: z.ZodOptional>; dir: z.ZodOptional; file: z.ZodOptional; sync: z.ZodOptional; }, z.core.$strip>>; maxStack: z.ZodOptional; queryFile: z.ZodOptional; maxScanBytes: z.ZodOptional; }, z.core.$strip>>; queryDriver: z.ZodOptional; loki: z.ZodOptional; username: z.ZodOptional; password: z.ZodOptional; headers: z.ZodOptional>; timeoutMs: z.ZodOptional; batchSize: z.ZodOptional; flushIntervalMs: z.ZodOptional; maxQueue: z.ZodOptional; labels: z.ZodOptional>; tenantId: z.ZodOptional; maxScanLines: z.ZodOptional; }, z.core.$strict>>; opensearch: z.ZodOptional; username: z.ZodOptional; password: z.ZodOptional; headers: z.ZodOptional>; timeoutMs: z.ZodOptional; batchSize: z.ZodOptional; flushIntervalMs: z.ZodOptional; maxQueue: z.ZodOptional; index: z.ZodOptional; maxHits: z.ZodOptional; }, z.core.$strict>>; }, z.core.$strip>>; }, z.core.$strip>; /** Type inféré de la config app (source unique TS ↔ runtime). */ export type AppConfig = z.infer; /** * JSON Schema introspectable de la config d'application — destiné au panneau de * config Studio (`/nodefony/config`, carte de l'app). Documenté via les * `.describe()` du schéma (rôle + défaut de chaque champ). */ export declare function appConfigJsonSchema(): unknown; /** * Valide la config app résolue ; lève une erreur au message agrégé si invalide. * * Appelée par `defineConfig().resolve()` après le deep-merge avec les défauts. * * @param options - config app résolue à valider. * @throws Error si la config ne respecte pas {@link appConfigSchema}. */ export declare function validateAppConfig(options: unknown): void;