> 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/technical-reference/identity-access-and-administration/audit-events-and-api-key-activity.md).

# Audit Events and API Key Activity

Audit events record supported administrative and access activity. Use them with run history and API key activity to investigate a change.

{% 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 begin

Permission to view the relevant audit or API key activity report.

## Key concepts

| Term          | Definition                                                                                                                                            |
| ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| Audit event   | A record of a supported administrative or access-related operation. Audit coverage is different from complete workflow execution history.             |
| User identity | The authenticated person or application acting on a resource. It determines access; a display name or conversation ID does not authenticate a caller. |
| API key       | A secret credential accepted by a supported API or connector. Send it only through the documented authentication field or header.                     |
| Trace         | Details of the steps taken during a run. Use it to locate the first unexpected input, output, or error.                                               |
| Retention     | The period or policy for keeping a category of data. Deleting one resource is not a universal retention rule for all related systems.                 |

## Review audit events

1. Select the time range and available actor or resource filters.

![Use the actor, action, resource, and timestamp fields to interpret the event.](https://content.gitbook.com/content/SQ1Sgy933krTyK0S4JpP/blobs/ZITIaf508wekwguvFz4T/assets/g099-g099-01-list.png)

Use the actor, action, resource, and timestamp fields to interpret the event.

2. Inspect the event’s actor, action, time, and resource.
3. Compare it with the related run or configuration change and export through the supported control if needed.

You can trace the recorded activity to its relevant account and resource.

## Behavior and limitations

Audit coverage is not identical to runtime history. Absence of an audit event does not prove that no operation occurred. Retention and export availability depend on configuration. A key’s activity does not describe every downstream provider operation performed during a run.

## Related resources

[Audit logs](https://docs.stackai.com/guides-and-quickstarts/organization-administration/audit-logs.md)

[Organization Roles and Permissions](https://docs.stackai.com/technical-reference/identity-access-and-administration/organization-roles-and-permissions.md)


---

# 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/technical-reference/identity-access-and-administration/audit-events-and-api-key-activity.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.
