A replacement for App, sitting at the root of a CDK application. GuRootExperimental will synthesise a riff-raff.yaml file for a CDK application.

Usage is a case of updating /<repo-root>/cdk/bin/cdk.ts from:

import { App } from "aws-cdk-lib";

const app = new App();

new MyStack(app, "my-stack-CODE", {});
new MyStack(app, "my-stack-PROD", {});


import { GuRootExperimental } from "@guardian/cdk/lib/experimental/constructs/root";

const app = new GuRootExperimental();

new MyStack(app, "my-stack-CODE", {});
new MyStack(app, "my-stack-PROD", {});


  • App
    • GuRootExperimental


  • Initializes a CDK application.


    • Optional props: AppProps

      initialization properties

    Returns GuRootExperimental


_assemblyBuilder: CloudAssemblyBuilder

The cloud assembly builder that is being used for this App

_treeMetadata: boolean

Include construct tree metadata as part of the Cloud Assembly.

account?: string

The default account for all resources defined within this stage.

node: Node

The tree node.

parentStage?: Stage

The parent stage or undefined if this is the app. *

policyValidationBeta1: IPolicyValidationPluginBeta1[]

Validation plugins to run during synthesis. If any plugin reports any violation, synthesis will be interrupted and the report displayed to the user.


- no validation plugins are used
region?: string

The default region for all resources defined within this stage.

stageName: string

The name of the stage. Based on names of the parent stages separated by hypens.


  • get artifactId(): string
  • Artifact ID of the assembly if it is a nested stage. The root stage (app) will return an empty string.

    Derived from the construct path.

    Returns string

  • get assetOutdir(): string
  • The cloud assembly asset output directory.

    Returns string

  • get outdir(): string
  • The cloud assembly output directory.

    Returns string


  • Returns a string representation of this construct.

    Returns string

  • Checks if an object is an instance of the App class.


    • obj: any

      The object to evaluate

    Returns obj is App

    true if obj is an App.

  • Checks if x is a construct.

    Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

    Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.


    • x: any

      Any object

    Returns x is Construct

    true if x is an object created from a class which extends Construct.

  • Test whether the given construct is a stage.


    • x: any

    Returns x is Stage

  • Return the stage this construct is contained with, if available. If called on a nested stage, returns its parent.


    • construct: IConstruct

    Returns undefined | Stage

Generated using TypeDoc