import { z } from 'zod'; import { type DatetimeString, type DidString, type HandleString } from '@atproto/lex'; import { AccountStatus } from '../account-manager/account-manager.js'; import type { CommitDataWithOps, SyncEvtData } from '../repo/index.js'; import type { RepoSeqInsert } from './db/index.js'; export declare const formatSeqCommit: (did: string, commitData: CommitDataWithOps) => Promise; export declare const formatSeqSyncEvt: (did: DidString, data: SyncEvtData) => Promise; export declare const syncEvtDataFromCommit: (commitData: CommitDataWithOps) => SyncEvtData; export declare const formatSeqIdentityEvt: (did: DidString, handle?: HandleString) => Promise; export declare const formatSeqAccountEvt: (did: DidString, status: AccountStatus) => Promise; export declare const commitEvtOp: z.ZodObject<{ action: z.ZodUnion<[z.ZodLiteral<"create">, z.ZodLiteral<"update">, z.ZodLiteral<"delete">]>; path: z.ZodString; cid: z.ZodNullable, unknown>>; prev: z.ZodOptional, unknown>>; }, "strip", z.ZodTypeAny, { action: "create" | "delete" | "update"; path: string; cid: import("multiformats/cid").CID | null; prev?: import("multiformats/cid").CID | undefined; }, { action: "create" | "delete" | "update"; path: string; cid?: unknown; prev?: unknown; }>; export type CommitEvtOp = z.infer; export declare const commitEvt: z.ZodObject<{ rebase: z.ZodBoolean; tooBig: z.ZodBoolean; repo: z.ZodEffects; commit: z.ZodEffects, unknown>; rev: z.ZodString; since: z.ZodNullable; blocks: z.ZodType, z.ZodTypeDef, Uint8Array>; ops: z.ZodArray, z.ZodLiteral<"update">, z.ZodLiteral<"delete">]>; path: z.ZodString; cid: z.ZodNullable, unknown>>; prev: z.ZodOptional, unknown>>; }, "strip", z.ZodTypeAny, { action: "create" | "delete" | "update"; path: string; cid: import("multiformats/cid").CID | null; prev?: import("multiformats/cid").CID | undefined; }, { action: "create" | "delete" | "update"; path: string; cid?: unknown; prev?: unknown; }>, "many">; blobs: z.ZodArray, unknown>, "many">; prevData: z.ZodOptional, unknown>>; }, "strip", z.ZodTypeAny, { rebase: boolean; tooBig: boolean; repo: `did:${string}:${string}`; commit: import("multiformats/cid").CID; rev: string; since: string | null; blocks: Uint8Array; ops: { action: "create" | "delete" | "update"; path: string; cid: import("multiformats/cid").CID | null; prev?: import("multiformats/cid").CID | undefined; }[]; blobs: import("multiformats/cid").CID[]; prevData?: import("multiformats/cid").CID | undefined; }, { rebase: boolean; tooBig: boolean; repo: string; commit?: unknown; rev: string; since: string | null; blocks: Uint8Array; ops: { action: "create" | "delete" | "update"; path: string; cid?: unknown; prev?: unknown; }[]; blobs: unknown[]; prevData?: unknown; }>; export type CommitEvt = z.infer; export declare const syncEvt: z.ZodObject<{ did: z.ZodEffects; blocks: z.ZodType, z.ZodTypeDef, Uint8Array>; rev: z.ZodString; }, "strip", z.ZodTypeAny, { did: `did:${string}:${string}`; blocks: Uint8Array; rev: string; }, { did: string; blocks: Uint8Array; rev: string; }>; export type SyncEvt = z.infer; export declare const identityEvt: z.ZodObject<{ did: z.ZodEffects; handle: z.ZodOptional>; }, "strip", z.ZodTypeAny, { did: `did:${string}:${string}`; handle?: `${string}.${string}` | undefined; }, { did: string; handle?: string | undefined; }>; export type IdentityEvt = z.infer; export declare const accountEvt: z.ZodObject<{ did: z.ZodEffects; active: z.ZodBoolean; status: z.ZodOptional>; }, "strip", z.ZodTypeAny, { did: `did:${string}:${string}`; active: boolean; status?: AccountStatus.Takendown | AccountStatus.Suspended | AccountStatus.Deleted | AccountStatus.Deactivated | undefined; }, { did: string; active: boolean; status?: AccountStatus.Takendown | AccountStatus.Suspended | AccountStatus.Deleted | AccountStatus.Deactivated | undefined; }>; export type AccountEvt = z.infer; type TypedCommitEvt = { type: 'commit'; seq: number; time: DatetimeString; evt: CommitEvt; }; type TypedSyncEvt = { type: 'sync'; seq: number; time: DatetimeString; evt: SyncEvt; }; type TypedIdentityEvt = { type: 'identity'; seq: number; time: DatetimeString; evt: IdentityEvt; }; type TypedAccountEvt = { type: 'account'; seq: number; time: DatetimeString; evt: AccountEvt; }; export type SeqEvt = TypedCommitEvt | TypedSyncEvt | TypedIdentityEvt | TypedAccountEvt; export {}; //# sourceMappingURL=events.d.ts.map