interface TableGrantsProps
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.DynamoDB.TableGrantsProps |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsdynamodb#TableGrantsProps |
Java | software.amazon.awscdk.services.dynamodb.TableGrantsProps |
Python | aws_cdk.aws_dynamodb.TableGrantsProps |
TypeScript (source) | aws-cdk-lib » aws_dynamodb » TableGrantsProps |
Construction properties for TableGrants.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_dynamodb as dynamodb } from 'aws-cdk-lib';
import { aws_iam as iam } from 'aws-cdk-lib';
import { aws_dynamodb as interfaces_dynamodb } from 'aws-cdk-lib/interfaces';
declare const encryptedResource: iam.IEncryptedResource;
declare const resourceWithPolicyV2: iam.IResourceWithPolicyV2;
declare const tableRef: interfaces_dynamodb.ITableRef;
const tableGrantsProps: dynamodb.TableGrantsProps = {
table: tableRef,
// the properties below are optional
encryptedResource: encryptedResource,
hasIndex: false,
policyResource: resourceWithPolicyV2,
regions: ['regions'],
};
Properties
| Name | Type | Description |
|---|---|---|
| table | ITable | The table to grant permissions on. |
| encrypted | IEncrypted | The encrypted resource on which actions will be allowed. |
| has | boolean | Whether this table has indexes. |
| policy | IResource | The resource with policy on which actions will be allowed. |
| regions? | string[] | Additional regions other than the main one that this table is replicated to. |
table
Type:
ITable
The table to grant permissions on.
encryptedResource?
Type:
IEncrypted
(optional, default: No permission is added to the KMS key, even if it exists)
The encrypted resource on which actions will be allowed.
hasIndex?
Type:
boolean
(optional, default: false)
Whether this table has indexes.
If so, permissions are granted on all table indexes as well.
policyResource?
Type:
IResource
(optional, default: No resource policy is created)
The resource with policy on which actions will be allowed.
regions?
Type:
string[]
(optional, default: No regions)
Additional regions other than the main one that this table is replicated to.

.NET
Go
Java
Python
TypeScript (