Home · Docs · Security · Audit log

Audit log

Every important action on a doc and across an org is recorded with actor, event type, and timestamp. Used for the History panel, the org audit page, and compliance review.

Sweetdocs writes an audit event for every meaningful action on a document — saves, shares, public-link toggles, restores, comments, edits by collaborators. Org-level events extend the same schema (member changes, library creates, domain captures).

These events power three distinct UI surfaces:

SurfaceScopeAudience
Doc History panelOne documentAnyone with read access to the doc
Org audit pageWhole organizationOrg Owners + Admins
Search / dashboards (internal)Compliance and securitysweetdocs operators when investigating issues
All eventsVersionsSharesMembersLast 7 days
ActorActionResourceTime
L Lee VaniderstineSaved a versionkyoto-trip2m ago
S Sam ParkShared accessArchitecture14m ago
L Lee VaniderstineMade publicPricing notes1h ago
A Avery ChenRestored a versionAuth migration plan3h ago
@ marisol@vendor.comDomain captureOrgyesterday

Event types

Every event has a event_type, a payload (JSON with event-specific fields), and a created_at. The current types:

Event typeDoc-scoped labelOrg-scoped label
versionVersion savedSaved a version
viewViewedViewed
shareShared <level> with someone / a groupShared access
unshareRevoked <level> accessRevoked access
public_onMade public (share link enabled)Made public
public_offMade private (share link disabled)Made private
restore / version_restoredRestored a previous versionRestored a version
comment_receivedNew commentCommented
comment_repliedReplied to a commentReplied
mentionedMentioned a collaboratorMentioned someone
doc_edited_by_collaboratorEdited by a collaboratorEdited

The labels are deliberately written two ways: the doc-scoped version reads like “what happened to this doc,” the org-scoped version reads like “what this person did.”

Doc-level audit (the History panel)

The History panel (right-side, clock icon in the toolbar) shows the audit timeline for the current document. Each row is one event.

Versions are clickable to preview / restore; non-version events are read-only timeline markers.

This is per-doc, per-user. Anyone with read access sees the same timeline.

Org-level audit

For orgs, an aggregate view of every event across every doc, folder, library, and member is available on the org page. This is Owner + Admin only — Members don’t see other people’s actions.

What’s covered org-wide:

What’s recorded with each event

Every event row includes:

FieldValue
actorWho did it (user ID + display name + avatar)
event_typeThe action type (from the table above)
payloadEvent-specific metadata as JSON
created_atWhen it happened (UTC, displayed in viewer’s local time)
resourceThe doc / folder / library / org targeted (for actions on resources)

For sign-in events, IP address and user-agent string are also captured for security review.

Retention

Audit events are retained according to your plan’s data retention policy:

Export to CSV

Org Owners and Admins can export the audit log as CSV from the org audit page. Useful for:

The CSV includes every column shown in the UI plus the full payload JSON for each event.

What the audit log isn’t

NotWhy
A way to see “all access to a document” by readers (public link viewers)Public link views are recorded as anonymous view events with no actor
Real-time alertsThe log is post-hoc — set up notifications separately if you need them
Tamper-proof / blockchain-styleThe DB is the source of truth; we don’t write to an append-only log outside Postgres
Free / Pro org auditFree/Pro doesn’t have orgs
Real session activity (every API call, every keystroke)Only meaningful semantic events are recorded — not every individual HTTP request

Compliance posture

For SOC 2 / ISO 27001-style audits, the org audit log is the primary artifact. It captures:

This is the standard four-W audit shape and meets most “log every administrative action” requirements.