> **Experimental**
>
> `@aws-cdk/aws-imagebuilder-alpha` is an [**experimental**](/stability) (alpha) package: its API may change in any release, without a major version bump.
# LifecyclePolicyDetail

Configuration details for the lifecycle policy rules.

- Stability: [Experimental](/cdk/api/stability.html)
- Source: [`lib/lifecycle-policy.ts`](https://github.com/aws/aws-cdk/blob/v2.275.0-alpha.0/packages/@aws-cdk/aws-imagebuilder-alpha/lib/lifecycle-policy.ts#L245)

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as imagebuilder_alpha from '@aws-cdk/aws-imagebuilder-alpha';
import * as cdk from 'aws-cdk-lib';
const lifecyclePolicyDetail: imagebuilder_alpha.LifecyclePolicyDetail = {
  action: {
    type: imagebuilder_alpha.LifecyclePolicyActionType.DELETE,

    // the properties below are optional
    includeAmis: false,
    includeContainers: false,
    includeSnapshots: false,
  },
  filter: {
    ageFilter: {
      age: cdk.Duration.minutes(30),

      // the properties below are optional
      retainAtLeast: 123,
    },
    countFilter: {
      count: 123,
    },
  },

  // the properties below are optional
  exclusionRules: {
    amiExclusionRules: {
      isPublic: false,
      lastLaunched: cdk.Duration.minutes(30),
      regions: ['regions'],
      sharedAccounts: ['sharedAccounts'],
      tags: {
        tagsKey: 'tags',
      },
    },
    imageExclusionRules: {
      tags: {
        tagsKey: 'tags',
      },
    },
  },
};
```

## Properties

- `action`: [LifecyclePolicyAction](/cdk/api/v2/docs/@aws-cdk_aws-imagebuilder-alpha.LifecyclePolicyAction.html) (required) — The action to perform in the lifecycle policy rule.

- `exclusionRules`: [LifecyclePolicyExclusionRules](/cdk/api/v2/docs/@aws-cdk_aws-imagebuilder-alpha.LifecyclePolicyExclusionRules.html) — The rules to apply for excluding resources from the lifecycle policy rule.

  **Default:** no exclusion rules are applied on any resource

- `filter`: [LifecyclePolicyFilter](/cdk/api/v2/docs/@aws-cdk_aws-imagebuilder-alpha.LifecyclePolicyFilter.html) (required) — The resource filtering to apply in the lifecycle policy rule.
