Monitoring account activity with the audit log
- English
- 日本語
The audit log keeps track of events related to your Fastly account, users, and services. You can use the audit log to determine which changes were made and by whom. For example, you can use the audit log to review:
- when API tokens were created
- who logged in to your account via the control panel
- what types of changes may have been made to your service configuration settings and by whom (e.g., a user assigned to your account, a Fastly user acting on your behalf)
- when users make changes to their account security settings
- when superusers purchase additional products and features for your account via the control panel
You can use the Fastly control panel and API to view the audit log.
Accessing the audit log via the Fastly control panel
You must be assigned the role of superuser to view the audit log. You can filter audit log events by event type, token ID, service ID, user ID, and date directly in the Fastly control panel.
Follow these instructions to access the audit log for your account:
Log in to the Fastly control panel.
Go to Account > Audit log.
Accessing the audit log via the Fastly API
The /events
API endpoint can be used to retrieve the audit log for a Fastly account. For example, you could make the following API call in a terminal application to retrieve a filtered view of all recent audit log events:
$ curl -g -H "Fastly-Key: FASTLY_API_TOKEN" "https://api.fastly.com/events?filter[customer_id]=x4xCwxxJxGCx123Rx5xTx&page[number]=1&page[size]=1"
The response will look like this:
{ "data": [ { "attributes": { "admin": false, "created_at": "2016-06-06T20:05:10Z", "customer_id": "x4xCwxxJxGCx123Rx5xTx", "description": "Version 2 was activated", "event_type": "version.activate", "ip": "127.0.0.0", "metadata": { "version_number": 2 }, "service_id": "SU1Z0isxPaozGVKXdv0eY", "user_id": "x9KzsrACXZv8tPwlEDsKb6" }, "id": "5IH1QmNSV1Qi7jXc4oIZlZc", "type": "event" } ], "links": { "last": "https://api.fastly.com/events?filter[customer_id]=x4xCwxxJxGCx123Rx5xTx&page[number]=1&page[size]=1" }}
Check out the Fastly API documentation for more information.