aws-cdk-lib.aws_iam.CommonGrantOptions

interface CommonGrantOptions

LanguageType name
.NETAmazon.CDK.AWS.IAM.CommonGrantOptions
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsiam#CommonGrantOptions
Javasoftware.amazon.awscdk.services.iam.CommonGrantOptions
Pythonaws_cdk.aws_iam.CommonGrantOptions
TypeScript (source)aws-cdk-lib » aws_iam » CommonGrantOptions

Basic options for a grant operation.

Example

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_iam as iam } from 'aws-cdk-lib';

declare const conditions: any;
declare const grantable: iam.IGrantable;
const commonGrantOptions: iam.CommonGrantOptions = {
  actions: ['actions'],
  grantee: grantable,
  resourceArns: ['resourceArns'],

  // the properties below are optional
  conditions: {
    conditionsKey: {
      conditionsKey: conditions,
    },
  },
};

Properties

NameTypeDescription
actionsstring[]The actions to grant.
granteeIGrantableThe principal to grant to.
resourceArnsstring[]The resource ARNs to grant to.
conditions?{ [string]: { [string]: any } }Any conditions to attach to the grant.

actions

Type: string[]

The actions to grant.


grantee

Type: IGrantable

The principal to grant to.


resourceArns

Type: string[]

The resource ARNs to grant to.


conditions?

Type: { [string]: { [string]: any } } (optional, default: No conditions)

Any conditions to attach to the grant.