Open app
Moonborn — Developers

Audit trail for brand teams

Read the immutable audit log for persona mutations, refine actions, and config edits. Verify the hash chain.

Brand governance often needs "who changed what, when." Moonborn's audit log is the answer — hash-chained, immutable, exportable.

Read recent events

const events = await client.audit.listEvents({
  workspaceId: 'ws_...',
  category: 'persona',
  limit: 50,
});
for (const e of events) {
  console.log(e.occurredAt, e.actor.email, e.action, e.target.id);
}

Categories include persona, config, rbac, billing, webhooks. For brand QA: persona covers create / refine / fork / archive.

Filter by actor

const events = await client.audit.listEvents({
  workspaceId: 'ws_...',
  actorUserId: 'user_...',
  limit: 100,
});

Verify the hash chain

Every row stores hash = sha256(payload || previous_hash). Export the chain + run a local verification:

const exp = await client.audit.export({ workspaceId: 'ws_...' });
// Verify locally:
let expected = exp.seed;
for (const e of exp.events) {
  const computed = sha256(JSON.stringify(e.payload) + expected);
  if (computed !== e.hash) throw new Error('Tamper at ' + e.id);
  expected = e.hash;
}

Retention

  • 1 year (Pro/Team), 7 years (Enterprise), via privacy.retention.audit_log_years.
  • Per-workspace overrides within the plan's allowance.

Tier

Audit log: every tier. Export + hash-chain verification: Team and up.

Related