class CfnAccessGrantPropsMixin
| Language | Type name |
|---|---|
.NET | Amazon.CDK.Mixins.Preview.AWS.S3.Mixins.CfnAccessGrantPropsMixin |
Go | github.com/aws/aws-cdk-go/awscdkmixinspreview/v2/awss3/mixins#CfnAccessGrantPropsMixin |
Java | software.amazon.awscdk.mixins.preview.services.s3.mixins.CfnAccessGrantPropsMixin |
Python | aws_cdk.mixins_preview.aws_s3.mixins.CfnAccessGrantPropsMixin |
TypeScript | @aws-cdk/mixins-preview » aws_s3 » mixins » CfnAccessGrantPropsMixin |
Implements
IMixin
Extends
Mixin
The AWS::S3::AccessGrant resource creates an access grant that gives a grantee access to your S3 data.
The grantee can be an IAM user or role or a directory user, or group. Before you can create a grant, you must have an S3 Access Grants instance in the same Region as the S3 data. You can create an S3 Access Grants instance using the AWS::S3::AccessGrantsInstance . You must also have registered at least one S3 data location in your S3 Access Grants instance using AWS::S3::AccessGrantsLocation .
- Permissions - You must have the
s3:CreateAccessGrantpermission to use this resource. - Additional Permissions - For any directory identity -
sso:DescribeInstanceandsso:DescribeApplication
For directory users - identitystore:DescribeUser
For directory groups - identitystore:DescribeGroup
See also: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-s3-accessgrant.html
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { mixins } from '@aws-cdk/mixins-preview';
import { mixins as s3_mixins } from '@aws-cdk/mixins-preview/aws-s3';
const cfnAccessGrantPropsMixin = new s3_mixins.CfnAccessGrantPropsMixin({
accessGrantsLocationConfiguration: {
s3SubPrefix: 's3SubPrefix',
},
accessGrantsLocationId: 'accessGrantsLocationId',
applicationArn: 'applicationArn',
grantee: {
granteeIdentifier: 'granteeIdentifier',
granteeType: 'granteeType',
},
permission: 'permission',
s3PrefixType: 's3PrefixType',
tags: [{
key: 'key',
value: 'value',
}],
}, /* all optional props */ {
strategy: mixins.PropertyMergeStrategy.OVERRIDE,
});
Initializer
new CfnAccessGrantPropsMixin(props: CfnAccessGrantMixinProps, options?: CfnPropertyMixinOptions)
Parameters
- props
Cfn— L1 properties to apply.Access Grant Mixin Props - options
Cfn— Mixin options.Property Mixin Options
Create a mixin to apply properties to AWS::S3::AccessGrant.
Properties
| Name | Type | Description |
|---|---|---|
| props | Cfn | |
| strategy | Property | |
| static CFN_PROPERTY_KEYS | string[] |
props
Type:
Cfn
strategy
Type:
Property
static CFN_PROPERTY_KEYS
Type:
string[]
Methods
| Name | Description |
|---|---|
| apply | Apply the mixin properties to the construct. |
| supports(construct) | Check if this mixin supports the given construct. |
applyTo(construct)
public applyTo(construct: IConstruct): IConstruct
Parameters
- construct
IConstruct
Returns
Apply the mixin properties to the construct.
supports(construct)
public supports(construct: IConstruct): boolean
Parameters
- construct
IConstruct
Returns
boolean
Check if this mixin supports the given construct.

.NET
Go
Java
Python
TypeScript