import type { SqliteDatabase } from '../db/adapter.js'; import { type JsonObject, type EntryKind, type EntryStatus, type TrustLevel, type ValidatedRecordInput } from '../serialization/validate.js'; import { type DecodeStoredMemoryOptions } from './revisions.js'; export interface RecordEntryInput { workspace: string; kind: EntryKind; status?: EntryStatus; title: string; body: string; summary?: string | null; scope?: JsonObject; provenance?: JsonObject; trustLevel?: TrustLevel; confidence?: number; tags?: string[]; createdBy?: string; actor?: string; } export interface RecordEntryOptions { now?: string; idFactory?: () => string; } export interface ReadEntryInput { workspace: string; entryId: string; } export interface UpdateCandidateEntryInput { workspace: string; entryId: string; expectedRevision: number; kind: EntryKind; title: string; body: string; summary?: string | null; scope?: JsonObject; provenance?: JsonObject; tags?: string[]; createdBy?: string; actor?: string; now?: string; } export interface EntryRecord { id: string; workspace: string; kind: EntryKind; status: EntryStatus; title: string; body: string; summary: string | null; scope: JsonObject; provenance: JsonObject; trustLevel: TrustLevel; confidence: number; contentHash: string; revision: number; supersededBy: string | null; createdBy: string; createdAt: string; updatedAt: string; verifiedAt: string | null; tags: string[]; } /** Validate and canonicalize every input-derived field used to create a new entry. */ export declare function validateNewEntryInput(input: RecordEntryInput): { record: ValidatedRecordInput; contentHash: string; }; export declare function recordEntryInTransaction(database: SqliteDatabase, input: RecordEntryInput, options?: RecordEntryOptions): EntryRecord; export declare function recordEntry(database: SqliteDatabase, input: RecordEntryInput, options?: RecordEntryOptions): EntryRecord; export declare function readEntry(database: SqliteDatabase, input: ReadEntryInput, options?: DecodeStoredMemoryOptions): EntryRecord; export declare function updateCandidateEntry(database: SqliteDatabase, input: UpdateCandidateEntryInput): EntryRecord; export declare function updateCandidateEntryInTransaction(database: SqliteDatabase, input: UpdateCandidateEntryInput): EntryRecord; /** Internal snapshot refresh path; callers must already be inside the import transaction. */ export declare function updateManagedExternalEntryInTransaction(database: SqliteDatabase, input: UpdateCandidateEntryInput): EntryRecord; //# sourceMappingURL=entries.d.ts.map