Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

cdk list

Focus mode
cdk list - AWS Cloud Development Kit (AWS CDK) v2

This is the AWS CDK v2 Developer Guide. The older CDK v1 entered maintenance on June 1, 2022 and ended support on June 1, 2023.

This is the AWS CDK v2 Developer Guide. The older CDK v1 entered maintenance on June 1, 2022 and ended support on June 1, 2023.

List all AWS CDK stacks and their dependencies from a CDK app.

Usage

$ cdk list <arguments> <options>

Arguments

CDK stack ID

The construct ID of the CDK stack from your app to perform this command against.

Type: String

Required: No

Options

For a list of global options that work with all CDK CLI commands, see Global options.

--help, -h BOOLEAN

Show command reference information for the cdk list command.

--long, -l BOOLEAN

Display AWS environment information for each stack.

Default value: false

--show-dependencies, -d BOOLEAN

Display stack dependency information for each stack.

Default value: false

Examples

List all stacks in the CDK app ‘node bin/main.js’

$ cdk list --app='node bin/main.js' Foo Bar Baz

List all stacks, including AWS environment details for each stack

$ cdk list --app='node bin/main.js' --long - name: Foo environment: name: 000000000000/bermuda-triangle-1 account: '000000000000' region: bermuda-triangle-1 - name: Bar environment: name: 111111111111/bermuda-triangle-2 account: '111111111111' region: bermuda-triangle-2 - name: Baz environment: name: 333333333333/bermuda-triangle-3 account: '333333333333' region: bermuda-triangle-3

On this page

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.