export type SubjectFields = Record; export type FieldChange = { before: unknown; after: unknown; }; /** Deterministic JSON: object keys sorted, `undefined` entries dropped, arrays in order. * The one canonicalizer in this package — `hashFieldValue` (action-id content hashing) and * `changesetContentHash` (approval binds to exact bytes) must agree on what "same content" * means, so they share this function rather than each rolling their own. */ export declare function canonicalJson(value: unknown): string; export declare function hashFieldValue(value: unknown): string; export declare function subjectKey(subject: { type: string; id: string; }): string; /** Field-level diff of freshly observed subject fields against a shadow of them. */ export type SubjectShadow = { subject: { type: string; id: string; }; fields: SubjectFields; fieldHashes: Record; latestEventId: string; updatedAt: string; }; export declare function diffSubjectFields(shadow: SubjectShadow | undefined, observed: SubjectFields): Record;