# ArchiveProps

The event archive properties.

Extends: ArchiveProps
Extends: BaseArchiveProps
Used as props by: Archive

- Source: [`aws-events/lib/archive.ts`](https://github.com/aws/aws-cdk/blob/v2.275.0/packages/aws-cdk-lib/aws-events/lib/archive.ts#L50)
- Type last changed: v2.235.0 · 15 Jan 2026

## Example

```ts
import * as kms from 'aws-cdk-lib/aws-kms';
import { Archive, EventBus } from 'aws-cdk-lib/aws-events';

const stack = new Stack();

declare const kmsKey: kms.IKey;

const eventBus = new EventBus(stack, 'Bus');

const archive = new Archive(stack, 'Archive', {
  kmsKey: kmsKey,
  sourceEventBus: eventBus,
  eventPattern: {
    source: ['aws.ec2']
  },
});
```

## Properties

- `archiveName`: string — The name of the archive.

  **Default:** Automatically generated

- `description`: string = none — A description for the archive.

- `eventPattern`: [EventPattern](/cdk/api/v2/docs/aws-cdk-lib.aws_events.EventPattern.html) (required) — An event pattern to use to filter events sent to the archive.

- `kmsKey`: [IKey](/cdk/api/v2/docs/aws-cdk-lib.aws_kms.IKey.html) — The customer managed key that encrypts this archive.

  **Default:** Use an AWS managed key

- `retention`: [Duration](/cdk/api/v2/docs/aws-cdk-lib.Duration.html) = Infinite — The number of days to retain events for.

  Default value is 0. If set to 0, events are retained indefinitely.

- `sourceEventBus`: [IEventBusRef](/cdk/api/v2/docs/aws-cdk-lib.interfaces.aws_events.IEventBusRef.html) (required) — The event source associated with the archive.
