An AuditOutbox row is a pending copy of an audit event waiting to be delivered to downstream systems. It mirrors the audit details — the action, tenantId, userId, resourceType, resourceId, metadata, and ipAddress — and adds delivery bookkeeping. The drainedAt timestamp marks when the event was successfully sent, attempts counts how many tries have been made, and lastError records why a delivery failed. This outbox pattern guarantees that audit events are not lost even if the receiving system is briefly unavailable.
Technical section
Data model, API, and internals — visible to developers.
