Constructs

Constructs are the basic building blocks of AWS Cloud Development Kit (AWS CDK) applications. A construct is a component within your application that represents one or more AWS CloudFormation resources and their configuration. You build your application, piece by piece, by importing and configuring constructs.

All constructs in the AWS CDK share three fundamental parameters during initialization:

  1. scope - The parent container where a construct lives. This could be a Stack or another construct.
  2. id - A unique identifier for the construct within its scope. AWS uses this to generate actual resource names and track the construct.
  3. props - A set of properties that define the construct’s initial configuration.