DomainGrants

class aws_cdk.aws_opensearchservice.DomainGrants(*args: Any, **kwargs)

Bases: object

Collection of grant methods for a IDomainRef.

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_opensearchservice as opensearchservice
from aws_cdk.interfaces import aws_opensearchservice as interfaces_aws_opensearchservice

# domain_ref: interfaces_aws_opensearchservice.IDomainRef

domain_grants = opensearchservice.DomainGrants.from_domain(domain_ref)

Methods

read(grantee)

Grant read permissions for this domain and its contents to an IAM principal (Role/Group/User).

Parameters:

grantee (IGrantable)

Return type:

Grant

read_write(grantee)

Grant read/write permissions for this domain and its contents to an IAM principal (Role/Group/User).

Parameters:

grantee (IGrantable)

Return type:

Grant

write(grantee)

Grant write permissions for this domain and its contents to an IAM principal (Role/Group/User).

Parameters:

grantee (IGrantable)

Return type:

Grant

Static Methods

classmethod from_domain(resource)

Creates grants for DomainGrants.

Parameters:

resource (IDomainRef)

Return type:

DomainGrants