Tearleads

principal_mutation_journal Client SQLite table

Authored work survives cache resets and remains until its outcome is known.

Declared in packages/client-sdk/src/data/sqlite/schema/principalMutationJournalSchema.ts

Columns

  • scope_idtext
    • primary key
    • not null

    Base64 SHA-256 of the domain-tagged journal scope: identity trust domain, organization, user, signing key fingerprint, and the device signer when present. At most one unresolved mutation per scope.

  • organization_idtext
    • not null

    Organization the mutation targets; must match the opening scope.

  • identity_bundle_formatinteger
    • not null
    • default 1

    Format of the principal identity data in this row. Always 1; restoring a backup row with any other value is refused.

  • serialized_requesttext
    • not null

    Canonical JSON of the authored mutation: its complete wire body.

  • signaturetext
    • not null

    Base64 ML-DSA-87 signature by the user's identity signing key over the scope and serializedRequest, checked before the request is parsed.

DDL

The statements the client runs to create this table and its indexes.

CREATE TABLE IF NOT EXISTS "principal_mutation_journal" (
  "scope_id" TEXT NOT NULL PRIMARY KEY,
  "organization_id" TEXT NOT NULL,
  "identity_bundle_format" INTEGER NOT NULL DEFAULT 1,
  "serialized_request" TEXT NOT NULL,
  "signature" TEXT NOT NULL
);