Skip to content

Audit Trail

The Audit Trail panel records security and compliance events for your organization. Navigate to Insights > Audit Trail.

What Gets Audited

NextEpoch automatically records these events:

ActionTrigger
user_loginUser authenticates via SSO
login_failedAuthentication failure
user_createdNew user account created via SSO
member_invitedTeam member invitation sent
member_role_changedMember role updated (includes old and new role)
member_removedMember removed from organization
credential_createdAPI credential created
credential_revokedAPI credential revoked

Audit Entry Fields

Each audit entry contains:

FieldDescription
received_atWhen the event occurred
actionThe audit action (see table above)
actor_typeWho performed it (user, system)
actor_idThe actor's ID
actor_nameThe actor's display name
actor_ipIP address of the actor
resource_typeWhat was affected (user, member, credential)
resource_idThe affected resource's ID
resource_nameThe affected resource's name
outcomesuccess or failure
reasonFailure reason (if applicable)
user_agentClient user agent string
request_idRequest identifier for correlation
context_jsonAdditional metadata as JSON

Filters

  • Time range — Last hour, 24 hours, 7 days, or 30 days
  • Action — Filter by specific audit action
  • Outcome — Filter by success or failure

Expanded Details

Click an audit entry row to expand it. The expanded view shows the context_json parsed as key-value pairs, which includes action-specific metadata like old and new roles for member_role_changed events.

Querying Audit Data with SQL

For advanced analysis, query the audit table directly via the Insights API:

sql
-- Failed logins in the last 24 hours
SELECT actor_name, actor_ip, received_at, reason
FROM audit
WHERE action = 'login_failed'
  AND received_at > NOW() - INTERVAL '24 hours'
ORDER BY received_at DESC

-- Role changes this week
SELECT actor_name, resource_name, context_json, received_at
FROM audit
WHERE action = 'member_role_changed'
  AND received_at > NOW() - INTERVAL '7 days'
ORDER BY received_at DESC

Next Steps

NextEpoch Cloud Documentation