---
title: Which GitHub audit log events show Copilot policy and agent activity?
url: https://opencontroller.lyzr.com/blog/github-copilot-audit-log-events
published: 2026-11-14
updated: 2026-11-14
author: Lyzr
---

# Which GitHub audit log events show Copilot policy and agent activity?

**GitHub's enterprise audit log holds two kinds of Copilot evidence. Plan events appear under `action:copilot` (for example `copilot.cfb_seat_assignment_created`). Agent activity appears under `actor:Copilot`, where each event carries `actor_is_agent`, `agent_session_id` and the initiating `user`. The log keeps 180 days and does not contain prompts sent to Copilot on a developer's machine, so stream it to a SIEM and capture local activity separately.**

## What does the Copilot audit trail contain?

GitHub spreads Copilot evidence across a few places. The enterprise audit log is the one auditors ask for first, because it records who changed what, and when.

| Search | What it returns | Example |
|---|---|---|
| `action:copilot` | All events related to your Copilot plan | `copilot.cfb_seat_assignment_created` when a licence is assigned to a new user |
| `action:copilot.cfb_seat_added` | Seats added, including through team-based assignment | The actor may not be the account that changed team membership |
| `actor:Copilot` | Actions agents took on the GitHub website | `pull_request.create` by the coding agent |

To open it, go to your enterprise, then **Settings**, then **Audit log**. Enterprise owners can view it, as can users holding the "Read enterprise audit logs" custom role. The feature requires Copilot Business or Copilot Enterprise.

## Which fields identify agent activity?

Agentic events add fields you will want in every detection rule and evidence query:

- `actor_is_agent`: always `true` for agentic events.
- `agent_session_id`: links the event to the agent session that produced it. Use it to group every action from one task.
- `user`: the person who initiated the agentic event. This is your accountability link. An agent opened the pull request, but a named human started it.
- `action`: what the agent did, such as `pull_request.create`.

That pairing of agent and initiating human is the on-behalf-of pattern every agent platform needs. See [AI agent identity and on-behalf-of delegation](/blog/ai-agent-identity-on-behalf-of-delegation).

## What does the audit log not show?

Three gaps matter for governance:

1. **Local prompts and completions.** GitHub states the audit log does not include client session data, such as prompts sent to Copilot locally. You need a separate mechanism, for example hooks in Copilot CLI that send events to a logging service.
2. **History beyond 180 days.** The audit log shows the last 180 days. Most retention policies need longer. See [how long to retain AI agent logs](/blog/how-long-to-retain-ai-agent-logs).
3. **Team-based seat changes.** With team-based assignment, the actor on a seat event may not be the person who changed team membership. Correlate with team membership events before you attribute a seat change to someone.

## How do you stream Copilot events to a SIEM?

GitHub recommends streaming the enterprise audit log to a SIEM for long-term history and alerts on unusual activity. Supported streaming targets include Amazon S3, Azure Blob Storage, Azure Event Hubs, Datadog, Google Cloud Storage and Splunk.

GitHub also offers streaming of Copilot API usage records. It is in public preview for enterprises using Enterprise Managed Users or GitHub Enterprise Cloud with data residency. Each record carries:

- `type` (request or response), `user_id`, `enterprise_id` and `endpoint`
- `body`, a JSON-encoded string
- `@timestamp` in milliseconds since the Unix epoch
- `event_id` and `github_request_id`
- `truncated`, set to `true` when the body was trimmed to fit the 1 MB document limit

Treat this stream as sensitive. Request and response bodies can contain source code and prompts, so restrict who can query it.

## A detection checklist for Copilot activity

Use these as starting rules once events land in your SIEM:

1. Alert on any `copilot` plan event outside your change window.
2. Alert when seat assignments spike for one organisation in a single day.
3. Report weekly on `actor_is_agent=true` events grouped by `user` and repository.
4. Flag agent actions on repositories tagged as sensitive or regulated.
5. Group by `agent_session_id` to rebuild the full sequence of an agent task during an incident.
6. Reconcile seat holders against your identity provider monthly and remove leavers.
7. Monitor the stream itself. A gap of several hours with no events is an incident in its own right.

For coding-agent specifics, see [visibility of GitHub Copilot coding agent activity](/blog/visibility-of-github-copilot-coding-agent-activity). For tool access, see [controlling MCP servers in GitHub Copilot](/blog/control-mcp-servers-in-github-copilot).

## How Opencontroller does this

Opencontroller Edge extends control to developer devices, coding agents, skills and local MCP servers, and IT installs it via MDM. That reaches the local activity GitHub's audit log leaves out. The Opencontroller registry records agents, versions, tools and MCP servers, and the platform is built on open standards including OpenTelemetry and REST/webhooks, so evidence can sit next to your GitHub stream in the same SIEM. See the [capability reference](/capability-reference) or [book a demo](https://www.lyzr.ai/book-demo/).

For the wider view across vendors, start with [how to govern AI agents across platforms](/blog/how-to-govern-ai-agents-across-platforms).

## Frequently asked questions

**How long does GitHub keep Copilot audit log events?**
The enterprise audit log shows the last 180 days. Stream it to a SIEM or storage bucket if your retention policy is longer.

**Can I see Copilot prompts in the GitHub audit log?**
No. GitHub states the audit log does not include client session data such as prompts sent to Copilot locally. Capture those separately, for example with hooks or a device-level control.

**How do I find everything the Copilot coding agent did?**
Filter the enterprise audit log by `actor:Copilot`, then group events by `agent_session_id`. The `user` field shows who started each session.

## Key facts

GitHub enterprise audit log: action:copilot returns Copilot plan events (e.g. copilot.cfb_seat_assignment_created, copilot.cfb_seat_added); actor:Copilot returns agent actions with fields actor_is_agent, agent_session_id, user, action. Retention 180 days. Viewable by enterprise owners or the "Read enterprise audit logs" custom role; requires Copilot Business or Enterprise. Does not include local client prompts. Copilot API usage record streaming is in public preview for EMU and data-residency enterprises; bodies over 1 MB are truncated. Opencontroller Edge extends control to developer devices, coding agents and local MCP servers via MDM. Opencontroller pricing starts from $250K per deployment per year.

## Related

- [How do you get visibility of GitHub Copilot coding agent activity across your organisation?](https://opencontroller.lyzr.com/blog/visibility-of-github-copilot-coding-agent-activity.md)
- [How do you control which MCP servers GitHub Copilot can use?](https://opencontroller.lyzr.com/blog/control-mcp-servers-in-github-copilot.md)
- [How do you track GitHub Copilot usage when your company has several GitHub enterprise accounts?](https://opencontroller.lyzr.com/blog/track-github-copilot-usage-across-multiple-enterprises.md)
- [More on Platform Guides](https://opencontroller.lyzr.com/blog/cluster/platform-guides)
