/** * Drizzle ORM schema for the **cron / todo schedule** table (`schedules`) — the * durable sink for recurring-task schedules registered by the `cron_schedule` * agent tool (T11962 · under T11679 · M7 · epic T11456). * * One row per recurring schedule: a cron expression plus the task TEMPLATE * (title / description) materialized on each fire, an `enabled` flag, and * creation/update timestamps. The `cron_schedule` agent tool * ({@link import('../tools/schedule-agent-tools.js')}) registers a row through the * leased Gate-3 accessor ({@link import('./schedule-store.js')}) so it persists * WITHOUT a running daemon (T11950 AC3); a future daemon scheduler consumes the * SAME table as a separate reader (T11962 AC4). * * ## Pure runtime infrastructure (NOT the exodus target shape) * * Like `_writer_leases` (T11627), `pi_session_*` (T11899), and `selfimprove_dhq` * (T11911), this table is co-located inside EACH scope's consolidated `cleo.db` * (project + global) via the `drizzle-cleo-project` / `drizzle-cleo-global` * migration sets — so the two lineages produce the SAME migration hash and the * consolidated single-file journal converges across both * (CONSOLIDATED_JOURNAL_LINEAGES cross-lineage guard, T11829). It is NOT part of * the exodus target shape under `schema/cleo-project/`, so the consolidated * schema-parity gate (T11364) does not re-derive its CHECK set — exactly the * runtime-infrastructure precedent. * * ## E10 typing * * TEXT ISO-8601 timestamps (`created_at` / `updated_at`); a typed boolean * (`enabled`, `integer({ mode: 'boolean' })` → CHECK IN (0,1)). No JSON columns — * the task template is two plain TEXT columns (title + nullable description). * * @module * @task T11962 * @epic T11679 * @see ./schedule-store.ts — the Gate-3 accessor over this table * @see ./selfimprove-dhq-schema.ts — the runtime-infrastructure-table precedent this mirrors * @see ../../migrations/drizzle-cleo-project — project migration (CREATE TABLE schedules) * @see ../../migrations/drizzle-cleo-global — global migration (byte-identical, journal convergence) */ /** * The physical name of the schedule table. Exported so the accessor and tests all * reference one source of truth. */ export declare const SCHEDULES_TABLE: "schedules"; /** * `schedules` — one row per recurring (cron) task schedule. * * `cronExpr` is the recurrence (a standard 5-field cron expression); `title` / * `description` are the task template materialized on each fire; `enabled` toggles * whether the daemon scheduler (a separate consumer, AC4) should fire it. The row * is written by the leased accessor ({@link import('./schedule-store.js')}) — the * `cron_schedule` agent tool delegates to it daemon-OFF. * * @task T11962 */ export declare const schedules: import("drizzle-orm/sqlite-core").SQLiteTableWithColumns<{ name: "schedules"; schema: undefined; columns: { id: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "number int53"; data: number; driverParam: number; notNull: true; hasDefault: true; isPrimaryKey: true; isAutoincrement: false; hasRuntimeDefault: false; enumValues: undefined; baseColumn: never; identity: undefined; generated: undefined; }, {}>; scheduleId: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "string"; data: string; driverParam: string; notNull: true; hasDefault: false; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: [string, ...string[]]; baseColumn: never; identity: undefined; generated: undefined; }, {}>; cronExpr: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "string"; data: string; driverParam: string; notNull: true; hasDefault: false; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: [string, ...string[]]; baseColumn: never; identity: undefined; generated: undefined; }, {}>; title: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "string"; data: string; driverParam: string; notNull: true; hasDefault: false; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: [string, ...string[]]; baseColumn: never; identity: undefined; generated: undefined; }, {}>; description: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "string"; data: string; driverParam: string; notNull: false; hasDefault: false; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: [string, ...string[]]; baseColumn: never; identity: undefined; generated: undefined; }, {}>; enabled: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "boolean"; data: boolean; driverParam: number; notNull: true; hasDefault: true; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: undefined; baseColumn: never; identity: undefined; generated: undefined; }, {}>; createdAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "string"; data: string; driverParam: string; notNull: true; hasDefault: true; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: [string, ...string[]]; baseColumn: never; identity: undefined; generated: undefined; }, {}>; updatedAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{ name: string; tableName: "schedules"; dataType: "string"; data: string; driverParam: string; notNull: true; hasDefault: true; isPrimaryKey: false; isAutoincrement: false; hasRuntimeDefault: false; enumValues: [string, ...string[]]; baseColumn: never; identity: undefined; generated: undefined; }, {}>; }; dialect: "sqlite"; }>; /** Row type for `schedules` SELECT queries. */ export type ScheduleRow = typeof schedules.$inferSelect; /** Row type for `schedules` INSERT operations. */ export type NewScheduleRow = typeof schedules.$inferInsert; //# sourceMappingURL=schedule-schema.d.ts.map