# Transition

Describes when an object transitions to a specified storage class.

- Source: [`aws-s3/lib/rule.ts`](https://github.com/aws/aws-cdk/blob/v2.273.0/packages/aws-cdk-lib/aws-s3/lib/rule.ts#L151)
- Type last changed: v2.26.0 · 30 May 2022

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cdk from 'aws-cdk-lib';
import { aws_s3 as s3 } from 'aws-cdk-lib';

declare const storageClass: s3.StorageClass;
const transition: s3.Transition = {
  storageClass: storageClass,

  // the properties below are optional
  transitionAfter: cdk.Duration.minutes(30),
  transitionDate: new Date(),
};
```

## Properties

- `storageClass`: [StorageClass](/cdk/api/v2/docs/aws-cdk-lib.aws_s3.StorageClass.html) (required) — The storage class to which you want the object to transition.

- `transitionAfter`: [Duration](/cdk/api/v2/docs/aws-cdk-lib.Duration.html) = No transition count. — Indicates the number of days after creation when objects are transitioned to the specified storage class.

- `transitionDate`: date = No transition date. — Indicates when objects are transitioned to the specified storage class.

  The date value must be in ISO 8601 format. The time is always midnight UTC.
