# StageProps

Construction properties of a Pipeline Stage.

- Source: [`aws-codepipeline/lib/pipeline.ts`](https://github.com/aws/aws-cdk/blob/v2.274.0/packages/aws-cdk-lib/aws-codepipeline/lib/pipeline.ts#L131)
- Type last changed: v2.186.0 · 27 Mar 2025

## Example

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

declare const action: codepipeline.Action;
declare const rule: codepipeline.Rule;
const stageProps: codepipeline.StageProps = {
  stageName: 'stageName',

  // the properties below are optional
  actions: [action],
  beforeEntry: {
    conditions: [{
      result: codepipeline.Result.ROLLBACK,
      rules: [rule],
    }],
  },
  onFailure: {
    conditions: [{
      result: codepipeline.Result.ROLLBACK,
      rules: [rule],
    }],
    result: codepipeline.Result.ROLLBACK,
    retryMode: codepipeline.RetryMode.ALL_ACTIONS,
  },
  onSuccess: {
    conditions: [{
      result: codepipeline.Result.ROLLBACK,
      rules: [rule],
    }],
  },
  transitionDisabledReason: 'transitionDisabledReason',
  transitionToEnabled: false,
};
```

## Properties

- `actions`: [IAction](/cdk/api/v2/docs/aws-cdk-lib.aws_codepipeline.IAction.html)[] — The list of Actions to create this Stage with.

  You can always add more Actions later by calling `IStage#addAction`.

- `beforeEntry`: [Conditions](/cdk/api/v2/docs/aws-cdk-lib.aws_codepipeline.Conditions.html) — The method to use when a stage allows entry.

  **Default:** No conditions are applied before stage entry

- `onFailure`: [FailureConditions](/cdk/api/v2/docs/aws-cdk-lib.aws_codepipeline.FailureConditions.html) — The method to use when a stage has not completed successfully.

  **Default:** No failure conditions are applied

- `onSuccess`: [Conditions](/cdk/api/v2/docs/aws-cdk-lib.aws_codepipeline.Conditions.html) — The method to use when a stage has succeeded.

  **Default:** No success conditions are applied

- `stageName`: string (required) — The physical, human-readable name to assign to this Pipeline Stage.

- `transitionDisabledReason`: string — The reason for disabling transition to this stage.

  **Default:** 'Transition disabled'

  Only applicable
  if `transitionToEnabled` is set to `false`.

- `transitionToEnabled`: boolean = true — Whether to enable transition to this stage.
