Variable: AuditRecorded
constAuditRecorded:TUnion<[TObject<{action:TLiteral<"subject.create">;actor:TUnion<[TObject<{kind:TLiteral<"tenant">;roles:TArray<TString>;scopePath:TString;subjectId:TString;tenant:TString; }>,TObject<{kind:TLiteral<"platform">;roles:TArray<TString>;scopePath:TLiteral<"/">;subjectId:TLiteral<"00000000-0000-0000-0000-000000000000">;tenant:TLiteral<"platform">; }>]>;correlationId:TString;occurredAt:TString;onBehalfOf:TOptional<TString>;outcome:TUnsafe<"success">;payload:TObject<{kind:TUnion<[TLiteral<"organization">,TLiteral<"person">]>;path:TString; }>;payloadHash:TString;producerModule:TString;recordId:TString;target:TOptional<TObject<{id:TString;type:TString; }>>;tenant:TString; }>,TObject<{action:TLiteral<"authentication-identity.link">;actor:TUnion<[TObject<{kind:TLiteral<"tenant">;roles:TArray<TString>;scopePath:TString;subjectId:TString;tenant:TString; }>,TObject<{kind:TLiteral<"platform">;roles:TArray<TString>;scopePath:TLiteral<"/">;subjectId:TLiteral<"00000000-0000-0000-0000-000000000000">;tenant:TLiteral<"platform">; }>]>;correlationId:TString;occurredAt:TString;onBehalfOf:TOptional<TString>;outcome:TUnsafe<"success">;payload:TObject<{subjectId:TString; }>;payloadHash:TString;producerModule:TString;recordId:TString;target:TOptional<TObject<{id:TString;type:TString; }>>;tenant:TString; }>,TObject<{action:TLiteral<"bootstrap.apply">;actor:TUnion<[TObject<{kind:TLiteral<"tenant">;roles:TArray<TString>;scopePath:TString;subjectId:TString;tenant:TString; }>,TObject<{kind:TLiteral<"platform">;roles:TArray<TString>;scopePath:TLiteral<"/">;subjectId:TLiteral<"00000000-0000-0000-0000-000000000000">;tenant:TLiteral<"platform">; }>]>;correlationId:TString;occurredAt:TString;onBehalfOf:TOptional<TString>;outcome:TUnsafe<"success">;payload:TObject<{anchorCreated:TBoolean;identitiesCreated:TInteger;organizationsCreated:TInteger; }>;payloadHash:TString;producerModule:TString;recordId:TString;target:TOptional<TObject<{id:TString;type:TString; }>>;tenant:TString; }>]>
Defined in: packages/contracts/src/schemas/audit.ts:87
event.<tenant>.<module>.audit.recorded.v1 body: one audit record, published by
the producing module from its outbox in the same transaction as the write it
describes. A union on action, one member per key of AUDIT_ACTIONS and one more
per extra payload version of an action (access.deny and identifier.publish have
two each), so an unregistered action, or a payload field the action does not list,
fails validation at the producer. recordId is also the JetStream Nats-Msg-Id.
Members are only ever appended: N168 compares this schema with master member by member, so a published member is never edited, reordered or merged with another.