aws-cdk-lib.CfnResourceProps

interface CfnResourceProps

LanguageType name
.NETAmazon.CDK.CfnResourceProps
Gogithub.com/aws/aws-cdk-go/awscdk/v2#CfnResourceProps
Javasoftware.amazon.awscdk.CfnResourceProps
Pythonaws_cdk.CfnResourceProps
TypeScript (source)aws-cdk-lib » CfnResourceProps

Example

class MyConstruct extends Resource implements ITaggable {
  public readonly tags = new TagManager(TagType.KEY_VALUE, 'Whatever::The::Type');

  constructor(scope: Construct, id: string) {
    super(scope, id);

    new CfnResource(this, 'Resource', {
      type: 'Whatever::The::Type',
      properties: {
        // ...
        Tags: this.tags.renderedTags,
      },
    });
  }
}

Properties

NameTypeDescription
typestringCloudFormation resource type (e.g. AWS::S3::Bucket).
properties?{ [string]: any }Resource properties.

type

Type: string

CloudFormation resource type (e.g. AWS::S3::Bucket).


properties?

Type: { [string]: any } (optional, default: No resource properties.)

Resource properties.