AWS CloudTrail records API activity in AWS accounts. Use it to look up events, inspect trail configuration and logging status, or run CloudTrail Lake queries.
Captured event types depend on configuration. Trails and event data stores log management events by default; data events, network activity events, and Insights events are captured only where you configure selectors for them. Read a trail's selectors before you treat its history as complete.
With AWS CloudTrail, you can:
- Look up recent activity: Search the last 90 days of management events by user, event name, resource, or event source
- Inspect trail configuration: Describe trails, check logging status, and read the event and Insights selectors that decide what gets captured
- Query history with SQL: Run CloudTrail Lake queries across event data stores for analysis that reaches further back than event lookup
- Confirm coverage: Verify that logging is actually enabled and that multi-region and organization trails are delivering
The block reads event history and trail configuration. Start Query runs a billable CloudTrail Lake query; Cancel Query stops one. The block does not alter trails or logging configuration. The following example grants the actions used by this block. Narrow resources where your AWS policy supports it:
cloudtrail:CancelQuery is the action Cancel Query needs, and it is not implied by Describe*, Get*, or List* — omit it and that one operation fails with an access-denied error. Note that Start Query is billed per GB scanned and consumes your account's concurrent-query quota of 10 queued or running queries.
Lookup Events is limited by AWS to two requests per second per account per Region. Each call uses AWS adaptive retry mode and allows up to six attempts, so a throttled request backs off exponentially with jitter within the retry budget. That is a retry budget, not a guarantee: sustained throttling past six attempts fails the call with a ThrottlingException, and because a fresh SDK client is built per invocation, adaptive mode's client-side rate limiter carries no pacing state between calls. Lookup Events also returns one page per call — feed nextToken back in to walk a broad search, and expect to handle a throttling error on a long paging loop.
CloudTrail Lake closed to new customers on May 31, 2026. Existing customers can continue using it; see AWS’s availability notice. This restriction applies to Lake queries, not ordinary event lookup or trail inspection.
Use the block
Integrate AWS CloudTrail into workflows. Look up the last 90 days of management and Insights events by user, event name, resource, or access key; inspect trail configuration, logging status, and event selectors; and run SQL queries against CloudTrail Lake event data stores. This block never changes trail or event data store configuration, and never starts or stops logging. Starting and cancelling a Lake query are the only actions that are not reads, and AWS bills Lake queries on the data they scan. Requires AWS access key and secret access key.
Actions
CloudTrail Look Up Events
Look up AWS CloudTrail management or Insights events from the last 90 days in a Region
CloudTrail Describe Trails
Retrieve the full configuration of one or more CloudTrail trails in the current Region
CloudTrail Get Trail
Retrieve the settings of a single CloudTrail trail by name or ARN
CloudTrail Get Trail Status
Check whether a CloudTrail trail is logging and surface its most recent delivery errors
CloudTrail List Trails
List the ARN, name, and home Region of every CloudTrail trail visible to the account
CloudTrail Get Event Selectors
Read which management, data, and network activity events a CloudTrail trail is configured to log
CloudTrail Get Insight Selectors
Read which CloudTrail Insights types are enabled on a trail or event data store
CloudTrail Start Query
Start a CloudTrail Lake SQL query over an event data store
CloudTrail Describe Query
Check the status, run time, and scan statistics of a CloudTrail Lake query
CloudTrail Get Query Results
Fetch a page of result rows from a finished CloudTrail Lake query
CloudTrail Cancel Query
Cancel a running CloudTrail Lake query
CloudTrail List Event Data Stores
List the CloudTrail Lake event data stores in the account for the current Region
CloudTrail Get Event Data Store
Retrieve the configuration of a single CloudTrail Lake event data store
CloudTrail List Tags
List the tags on CloudTrail trails, event data stores, dashboards, or channels