IM
EN
Docs Home
Menu
Features

Audit Logs

Account-level operational logs for observability and troubleshooting.

inbox-manager logs audit

Audit Logs

The audit logs feature defines structured account-scoped operation events for execution history and troubleshooting. It gives you a reliable trace of who did what and what happened next.

Why This Matters

This feature preserves an auditable trail across credential, task, job, and email operations so incident review is based on concrete execution history. It combines account-scoped access with searchable log fields and explicit cleanup operations to keep diagnostics reliable over time.

Core Flow

Operational actions emit structured log events with subject and action fields, which operators query through list and search routes during troubleshooting. Detailed log reads and scoped cleanup calls remain explicit operations.

Operations

OperationEndpointPurpose
Create logPOST /api/accounts/:account_id/logsWrite structured operation event
List logsGET /api/accounts/:account_id/logsRetrieve account log stream
Search logsPOST /api/accounts/:account_id/logs/searchQuery logs by event criteria
Delete logs by searchPOST /api/accounts/:account_id/logs/search-deleteBulk cleanup matched logs
Get logGET /api/logs/:log_idRetrieve one log entry
Delete logDELETE /api/logs/:log_idRemove one log entry

Key Data and State

{
  id: "log_...",
  account_id: "acc_...",
  subject: "job",
  action: "retry",
  status: "failed",
  data: { job_id: "job_...", error_code: "provider_timeout" }
}

Failure Modes and Controls

Missing account scope or authorization rejects log reads and writes, and search-delete remains explicit and account-scoped to prevent accidental broad deletion. Structured fields preserve failure detail for deterministic debugging, while retrieval endpoints remain read-only and separate from mutation routes.

Operation Log, 09-audit-logs-and-operations.