Skip to main content

astroctl audit export

Export audit events

Synopsis​

Export audit events to file or stdout as CSV (the default) or JSON.

🏢 ENTERPRISE PLAN REQUIRED: This command is only available for organizations with Enterprise plans. 👥 PERMISSIONS: Users can export events they have access to.

Terminal
astroctl audit export [flags]

Examples​

Terminal

# Export your audit events as CSV
astroctl audit export

# Export audit events as JSON
astroctl audit export --format JSON

# Export to file
astroctl audit export --format JSON --output my-activity.json

Options​

Terminal
--action string Filter by action (Create, Delete, Update, Revoke, etc.)
--dry-run Only dry runs: requests that checked a change and changed nothing
--end-date string End: a date (2024-01-16, through its end) or an instant; alone, reaches back 30 days
--event-type string Filter by event type (APIKey, Cluster, Application, etc.)
--format string Export format (CSV, JSON) (default "CSV")
-h, --help help for export
--include-dry-runs Also include dry runs; by default only real changes are shown
--include-reads Also include recorded reads of sensitive data, such as the audit log itself
--org-id string Organization ID (Admins only)
--output string Output file path (default: stdout)
--resource-id string Only events on this resource ID (exact match)
--search string Case-insensitive search over action, resource, resource ID, actor name and email, channel and IP address
--start-date string Start: a date (2024-01-15) or an instant (2024-01-15T10:30:00Z); alone, runs to now
--user-id string Filter by user ID (Admins only)

SEE ALSO​