> For the complete documentation index, see [llms.txt](https://docs.stackai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.stackai.com/guides-and-quickstarts/organization-administration/audit-logs.md).

# Audit logs

Audit logs record organization activity and access decisions. Use them to investigate who performed an action, which resource it affected, and whether access was allowed.

{% embed url="<https://files.gitbook.com/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSQ1Sgy933krTyK0S4JpP%2Fuploads%2FC49kZ8dPRDGt8JliqqqP%2FG099.mp4?alt=media&token=0553290f-f212-42d4-b843-a45569f6363d>" %}

## Before you start

Have the organization, actor or affected resource, and investigation time range ready. Reading events is an administrator investigation task. Use [Roles and permissions](https://docs.stackai.com/guides-and-quickstarts/organization-administration/roles-and-permissions.md) to investigate the role behind an unexpected denied action. Forwarding events through OpenTelemetry requires an observability administrator to supply the endpoint and authentication; involve IT for that integration.

You need access to organization audit logs. Event export also requires the destination endpoint and its authentication settings.

## Choose a reporting period

Open Settings → Audit Logs and review the event fields.

![Audit event fields](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/ZITIaf508wekwguvFz4T/assets/g099-g099-01-list.png)

Use resource, action, actor, decision, role, and timestamp together to interpret an event.

Choose the date or interval relevant to the investigation.

![Audit reporting period](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/N4N7H1Q9eeTucL2VooTs/assets/g099-g099-02-date.png)

Keep the reporting period explicit when comparing events.

## Filter and inspect events

Use Filters to narrow results to the actor or user you need.

![Actor or user event filter](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/DSvjSkZtTGD8dgdpoKTa/assets/g099-g099-03-user.png)

Check the resulting rows before adding more restrictions.

Filter by the relevant Action and combine it with date or actor filters as needed.

![Action filter](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/slLUwxVuu1EyCK9IUSM6/assets/g099-g099-04-resource.png)

This narrows the list to the operations under investigation.

Search for a relevant term within the result set.

![Audit event search](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/tY0Mxrw5NaBz52fjOuBx/assets/g099-g099-05-search.png)

Compare the matching events and their allow or deny decisions.

Use the Decision filter to inspect denied actions.

![Denied-action filter](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/BflpXVKhYMbmzuLWtJgh/assets/g099-g099-06-result.png)

Compare the attempted operation with the actor's role and resource access before drawing a conclusion.

## Configure event export

Open Export to review OpenTelemetry Export settings.

![OpenTelemetry Export endpoint and authentication settings](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/QE0rN0dOsjc1ms3DRB2X/assets/g099-g099-07-export.png)

This forwards events to an observability platform. Configure its endpoint and authentication for the intended integration rather than expecting a spreadsheet download.

## Important behavior

An audit event records an operation and its access decision. Use the actor, resource, role, and timestamp together when investigating it.

OpenTelemetry Export forwards events to an observability platform. It is not a spreadsheet download.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.stackai.com/guides-and-quickstarts/organization-administration/audit-logs.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
