Skip to content
v2.273.0

CfnJsonProps Struct ​

Example ​

ts
const tagParam = new CfnParameter(this, 'TagName');

const stringEquals = new CfnJson(this, 'ConditionJson', {
  value: {
    [`aws:PrincipalTag/${tagParam.valueAsString}`]: true,
  },
});

const principal = new iam.AccountRootPrincipal().withConditions({
  StringEquals: stringEquals,
});

new iam.Role(this, 'MyRole', { assumedBy: principal });

Properties ​

valueanyvalueAnyvalueObjectValueobjectValueinterface{}required#
The value to resolve.

Can be any JavaScript object, including tokens and references in keys or values.

Used as props by ​