> ## Documentation Index
> Fetch the complete documentation index at: https://controlplanecorporation-kyle-cron-and-quotas.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Audit Trail

> Tamper-proof audit trail for tracking all Control Plane and custom workload actions. Covers UI filtering, API queries, and custom workload audit integration.

## Overview

Control Plane provides a tamper-proof audit trail for both Control Plane and custom workload actions. The [audit trail UI](#audit-trail-ui) lets you search, filter, and view these events.

Each action performed in the Control Plane console or via the [CLI](/cli-reference/overview) is captured, securely stored, and indexed using the audit trail. In the UI, most resources include an audit trail link that opens the audit trail page with the resource ID prefilled. Additional filters can be added to drill down to specific events.

Custom workloads can use the audit trail service without needing to build their own solution. See [custom workloads](#custom-workloads) for details.

## Audit Trail UI

The audit trail UI displays details for each captured event.

Each action contains:

* Timestamp
* Name of resource
* Type of resource
* Version
* Status
* Message
* Subject (the user that acted)
* Link to view raw JSON for the event

The actions displayed can be filtered by:

* Kind of resource
* Audit context (the `cpln` audit context shows only Control Plane actions)
* Resource name or ID
* Subject name
* Start and optional end date

## Sample Audit Trail UI

Below is a sample of the audit trail UI after executing a query that returns captured actions:

<Frame>
  <img src="https://mintcdn.com/controlplanecorporation-kyle-cron-and-quotas/ghqw54Sjw30mCVAa/images/reference/audittrail/log-ui-audit-trail.png?fit=max&auto=format&n=ghqw54Sjw30mCVAa&q=85&s=d623c2740695afdd940f99dacf1d55bf" alt="Audit trail UI showing a filtered list of captured actions with timestamps, principals, and action types" width="1599" height="1075" data-path="images/reference/audittrail/log-ui-audit-trail.png" />
</Frame>

## Custom Workloads

The audit trail architecture is generic and allows any [workload](/concepts/workload) to securely and reliably capture events.

To use the audit trail, a [workload](/concepts/workload) must first create an [audit context](/reference/auditctx). See the [audit context](/reference/auditctx) reference for configuration details.

<Note>Detailed workload integration examples will be available soon.</Note>

### View Custom Audit Trail

To view the actions captured by your workload, you can use:

* Control Plane Audit Trail UI:
  * You can select an [audit context](/reference/auditctx) to view only those actions.
* Control Plane audit API:
  * Use the API to create a custom UI for audit data.
  * View the [Audit API OpenAPI spec](https://audit.cpln.io/openapi.json) to review the audit schema and available methods.
