Audit Log
đ Tutorial - Audit Database Activities with Bytebase API
Audit Log Service | https://api.bytebase.com/#tag/auditlogservice |
Bytebase provides workspace level and project level audit logs. You may call Bytebase API to export the audit logs and send it an external log sink such as AWS S3.
Workspace level
# Search
curl -X POST http://bytebase.example.com/v1/auditLogs:search \
-H 'Authorization: Bearer '${bytebase_token}
# Export in base64
curl -X POST http://bytebase.example.com/v1/auditLogs:export \
-H 'Authorization: Bearer '${bytebase_token} \
--data '{
"format": "JSON"
}'
Project level
# Search
curl -X POST http://bytebase.example.com/v1/projects/project-sample/auditLogs:search \
-H 'Authorization: Bearer '${bytebase_token}
# Export in base64
curl -X POST http://bytebase.example.com/v1/projects/project-sample/auditLogs:export \
-H 'Authorization: Bearer '${bytebase_token} \
--data '{
"format": "JSON"
}'