import { BetterSQLite3Database } from "drizzle-orm/better-sqlite3"; //#region src/connection.d.ts declare function getDatabasePath(): string; declare function setDatabasePath(path: string): void; type SharedDatabase = BetterSQLite3Database>; declare function getSharedDatabase(): SharedDatabase; declare function closeSharedDatabase(): void; //#endregion //#region src/migrations.d.ts /** * Migration runner for the shared monopi database. * * Applies SQL migrations from all registered schema modules in registration order. * Each module's migrations are tracked separately by module id + migration hash. */ declare function runMigrations(): void; declare function getSchemaVersion(): number; declare function resetDatabase(): void; //#endregion //#region src/registry.d.ts /** * Schema module registry. * * Extensions call registerSchemaModule() at load time to declare their SQLite * tables and migration SQL. The shared database applies all registered * migrations in registration order. */ type SchemaModuleId = string; interface SchemaModule { /** Unique identifier for this module (e.g. "analytics", "context-kb"). */ id: SchemaModuleId; /** Ordered SQL migration statements to create/update this module's tables. */ migrations: string[]; /** Optional: the table names this module owns, for introspection. */ tables?: string[]; } declare function registerSchemaModule(mod: SchemaModule): void; declare function getRegisteredSchemaModules(): SchemaModule[]; //#endregion export { type SchemaModule, type SchemaModuleId, type SharedDatabase, closeSharedDatabase, getDatabasePath, getRegisteredSchemaModules, getSchemaVersion, getSharedDatabase, registerSchemaModule, resetDatabase, runMigrations, setDatabasePath }; //# sourceMappingURL=index.d.ts.map