Get the audit log for an organization
Gets the audit log for an organization. For more information, see "Reviewing the audit log for your organization."
To use this endpoint, you must be an organization owner, and you must use an access token with the admin:org scope. GitHub Apps must have the organization_administration read permission to use this endpoint.
By default, the response includes up to 30 events from the past three months. Use the phrase parameter to filter results and retrieve older events. For example, use the phrase parameter with the created qualifier to filter events based on when the events occurred. For more information, see "Reviewing the audit log for your organization."
Use pagination to retrieve fewer or more than 30 events. For more information, see "Using pagination in the REST API."
Path parameters
The organization name. The name is not case sensitive.
Query parameters
A search phrase. For more information, see Searching the audit log.
The event types to include:
- web - returns web (non-Git) events.
- git - returns Git events.
- all - returns both web and Git events.
The default is web.
A cursor, as given in the Link header. If specified, the query only searches for events after this cursor.
A cursor, as given in the Link header. If specified, the query only searches for events before this cursor.
The order of audit log events. To list newest events first, specify desc. To list oldest events first, specify asc.
The default is desc.
The number of results per page (max 100).
Page number of the results to fetch.
Response
Response