Resource Type definition for AWS::CloudWatch::AccessGrant. An access grant authorizes a principal to perform a set of actions on resources in a space.
Create AccessGrant Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
@overload
def AccessGrant(resource_name: str,
args: AccessGrantArgs,
opts: Optional[ResourceOptions] = None)
@overload
def AccessGrant(resource_name: str,
opts: Optional[ResourceOptions] = None,
domain_id: Optional[str] = None,
permission: Optional[AccessGrantPermission] = None,
principal: Optional[AccessGrantPrincipalArgs] = None,
space_id: Optional[str] = None,
name: Optional[str] = None,
scoped_actions: Optional[Sequence[AccessGrantScopedActionsArgs]] = None,
tags: Optional[Sequence[_root_inputs.CreateOnlyTagArgs]] = None)
type: aws-native:cloudwatch:AccessGrant
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "aws-native_cloudwatch_access_grant" "name" {
# resource properties
}
Parameters
- resource_name
str
- The unique name of the resource.
- args
AccessGrantArgs
- The arguments to resource properties.
- opts
ResourceOptions
- Bag of options to control resource's behavior.
- ctx
Context
- Context object for the current deployment.
- name
string
- The unique name of the resource.
- args
AccessGrantArgs
- The arguments to resource properties.
- opts
ResourceOption
- Bag of options to control resource's behavior.
- name
String
- The unique name of the resource.
- args
AccessGrantArgs
- The arguments to resource properties.
- options
CustomResourceOptions
- Bag of options to control resource's behavior.
AccessGrant Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The AccessGrant resource accepts the following input properties:
Outputs
All input properties are implicitly available as output properties. Additionally, the AccessGrant resource produces the following output properties:
- AccountId
string
- The AWS account ID that owns the grant.
- Arn
string
- The Amazon Resource Name (ARN) of the access grant.
- CreatedAt
string
- The timestamp when the grant was created.
- CreatedBy
string
- The principal that created the grant.
- GrantId
string
- The unique ID of the access grant.
- GrantType
AccessGrantGrantType
- Who manages the grant.
- Id
string
- The provider-assigned unique ID for this managed resource.
- UpdatedAt
string
- The timestamp when the grant was last updated.
- accountId
String
- The AWS account ID that owns the grant.
- arn
String
- The Amazon Resource Name (ARN) of the access grant.
- createdAt
String
- The timestamp when the grant was created.
- createdBy
String
- The principal that created the grant.
- grantId
String
- The unique ID of the access grant.
- grantType
AccessGrantGrantType
- Who manages the grant.
- id
String
- The provider-assigned unique ID for this managed resource.
- updatedAt
String
- The timestamp when the grant was last updated.
- accountId
string
- The AWS account ID that owns the grant.
- arn
string
- The Amazon Resource Name (ARN) of the access grant.
- createdAt
string
- The timestamp when the grant was created.
- createdBy
string
- The principal that created the grant.
- grantId
string
- The unique ID of the access grant.
- grantType
AccessGrantGrantType
- Who manages the grant.
- id
string
- The provider-assigned unique ID for this managed resource.
- updatedAt
string
- The timestamp when the grant was last updated.
- account_id
str
- The AWS account ID that owns the grant.
- arn
str
- The Amazon Resource Name (ARN) of the access grant.
- created_at
str
- The timestamp when the grant was created.
- created_by
str
- The principal that created the grant.
- grant_id
str
- The unique ID of the access grant.
- grant_type
AccessGrantGrantType
- Who manages the grant.
- id
str
- The provider-assigned unique ID for this managed resource.
- updated_at
str
- The timestamp when the grant was last updated.
Look up Existing AccessGrant Resource
Get an existing AccessGrant resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static AccessGrant get(String name, Output<String> id, CustomResourceOptions options)
resources: existingAccessGrant: type: aws-native:cloudwatch:AccessGrant get: id: ${id}
import {
to = aws-native_cloudwatch_access_grant.example
id = "${id}"
}
- name
string
- The unique name of the resulting resource.
- id
Input<ID>
- The unique provider ID of the resource to look up.
- opts
CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name
str
- The unique name of the resulting resource.
- id
str
- The unique provider ID of the resource to look up.
- opts
ResourceOptions
- Bag of options to control resource's behavior.
- ctx
Context
- Context object for the current deployment.
- name
string
- The unique name of the resulting resource.
- id
IDInput
- The unique provider ID of the resource to look up.
- state
AccessGrantState
- Pass nil. This resource has no state arguments.
- opts
ResourceOption
- Bag of options to control resource's behavior.
- name
string
- The unique name of the resulting resource.
- id
Input<string>
- The unique provider ID of the resource to look up.
- opts
CustomResourceOptions
- Bag of options to control resource's behavior.
- name
String
- The unique name of the resulting resource.
- id
Output<String>
- The unique provider ID of the resource to look up.
- options
CustomResourceOptions
- Bag of options to control resource's behavior.
Supporting Types
AccessGrantGrantType
Who manages the grant.
| Name | Value |
|---|
| ServiceManaged | SERVICE_MANAGED |
| CustomerManaged | CUSTOMER_MANAGED |
| Name | Value |
|---|
| AccessGrantGrantTypeServiceManaged | SERVICE_MANAGED |
| AccessGrantGrantTypeCustomerManaged | CUSTOMER_MANAGED |
| Value |
|---|
SERVICE_MANAGED |
CUSTOMER_MANAGED |
| Name | Value |
|---|
| ServiceManaged | SERVICE_MANAGED |
| CustomerManaged | CUSTOMER_MANAGED |
| Name | Value |
|---|
| ServiceManaged | SERVICE_MANAGED |
| CustomerManaged | CUSTOMER_MANAGED |
| Name | Value |
|---|
| SERVICE_MANAGED | SERVICE_MANAGED |
| CUSTOMER_MANAGED | CUSTOMER_MANAGED |
| Value |
|---|
SERVICE_MANAGED |
CUSTOMER_MANAGED |
AccessGrantPermission
The permission granted.
| Name | Value |
|---|
| SpaceAdmin | SPACE_ADMIN |
| Read | READ |
| ReadWriteDelete | READ_WRITE_DELETE |
| Custom | CUSTOM |
| Name | Value |
|---|
| AccessGrantPermissionSpaceAdmin | SPACE_ADMIN |
| AccessGrantPermissionRead | READ |
| AccessGrantPermissionReadWriteDelete | READ_WRITE_DELETE |
| AccessGrantPermissionCustom | CUSTOM |
| Value |
|---|
SPACE_ADMIN |
READ |
READ_WRITE_DELETE |
CUSTOM |
| Name | Value |
|---|
| SpaceAdmin | SPACE_ADMIN |
| Read | READ |
| ReadWriteDelete | READ_WRITE_DELETE |
| Custom | CUSTOM |
| Name | Value |
|---|
| SpaceAdmin | SPACE_ADMIN |
| Read | READ |
| ReadWriteDelete | READ_WRITE_DELETE |
| Custom | CUSTOM |
| Name | Value |
|---|
| SPACE_ADMIN | SPACE_ADMIN |
| READ | READ |
| READ_WRITE_DELETE | READ_WRITE_DELETE |
| CUSTOM | CUSTOM |
| Value |
|---|
SPACE_ADMIN |
READ |
READ_WRITE_DELETE |
CUSTOM |
AccessGrantPrincipal, AccessGrantPrincipalArgs
The principal receiving the grant. Specify PrincipalId, PrincipalAttributes, or both.
AccessGrantPrincipalAttribute, AccessGrantPrincipalAttributeArgs
A single attribute condition used to match principals for attribute-based access.
- Key
string
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- Value
string
- The attribute value.
- Key
string
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- Value
string
- The attribute value.
- key
string
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- value
string
- The attribute value.
- key
String
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- value
String
- The attribute value.
- key
string
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- value
string
- The attribute value.
- key
str
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- value
str
- The attribute value.
- key
String
- The Identity Center user attribute to match on. One of userName, active, userStatus, displayName, email, name.givenName, name.familyName, enterprise.department, enterprise.division, enterprise.organization, enterprise.costCenter, or enterprise.employeeNumber.
- value
String
- The attribute value.
AccessGrantPrincipalPrincipalType
The type of principal receiving the grant.
| Name | Value |
|---|
| IdcUser | IDC_USER |
| IdcGroup | IDC_GROUP |
| IamUser | IAM_USER |
| IamRole | IAM_ROLE |
| IamRoot | IAM_ROOT |
| AccessProfile | ACCESS_PROFILE |
| Alert | ALERT |
| Agent | AGENT |
| Name | Value |
|---|
| AccessGrantPrincipalPrincipalTypeIdcUser | IDC_USER |
| AccessGrantPrincipalPrincipalTypeIdcGroup | IDC_GROUP |
| AccessGrantPrincipalPrincipalTypeIamUser | IAM_USER |
| AccessGrantPrincipalPrincipalTypeIamRole | IAM_ROLE |
| AccessGrantPrincipalPrincipalTypeIamRoot | IAM_ROOT |
| AccessGrantPrincipalPrincipalTypeAccessProfile | ACCESS_PROFILE |
| AccessGrantPrincipalPrincipalTypeAlert | ALERT |
| AccessGrantPrincipalPrincipalTypeAgent | AGENT |
| Value |
|---|
IDC_USER |
IDC_GROUP |
IAM_USER |
IAM_ROLE |
IAM_ROOT |
ACCESS_PROFILE |
ALERT |
AGENT |
| Name | Value |
|---|
| IdcUser | IDC_USER |
| IdcGroup | IDC_GROUP |
| IamUser | IAM_USER |
| IamRole | IAM_ROLE |
| IamRoot | IAM_ROOT |
| AccessProfile | ACCESS_PROFILE |
| Alert | ALERT |
| Agent | AGENT |
| Name | Value |
|---|
| IdcUser | IDC_USER |
| IdcGroup | IDC_GROUP |
| IamUser | IAM_USER |
| IamRole | IAM_ROLE |
| IamRoot | IAM_ROOT |
| AccessProfile | ACCESS_PROFILE |
| Alert | ALERT |
| Agent | AGENT |
| Name | Value |
|---|
| IDC_USER | IDC_USER |
| IDC_GROUP | IDC_GROUP |
| IAM_USER | IAM_USER |
| IAM_ROLE | IAM_ROLE |
| IAM_ROOT | IAM_ROOT |
| ACCESS_PROFILE | ACCESS_PROFILE |
| ALERT | ALERT |
| AGENT | AGENT |
| Value |
|---|
IDC_USER |
IDC_GROUP |
IAM_USER |
IAM_ROLE |
IAM_ROOT |
ACCESS_PROFILE |
ALERT |
AGENT |
AccessGrantResourceScope, AccessGrantResourceScopeArgs
A single resource scope entry within an access grant. Associates a resource type with optional ARN patterns, tag conditions, and row-level filters.
- ResourceType
string
- The resource type name, for example DataSet or OmniDashboard.
- ResourceArns
[]string
- Specific resource ARNs or ARN patterns. When set, actions are limited to these resources. When absent, defaults to all resources of the type.
- RowScopeGroups
[][]AccessGrantRowScope
- Row-level filters for this scope, as an OR of AND-groups: a row is visible when it matches every filter in any one group. Requires SignalTypes.
- SignalTypes
[]AccessGrantResourceScopeSignalTypesItem
- Signal types this scope's row filtering applies to. Required when RowScopeGroups is set.
- Tags
map[string]string
- Tag-based conditions for dynamic resource scoping. Access applies only to resources carrying all of the specified tag key-value pairs.
- resource_type
string
- The resource type name, for example DataSet or OmniDashboard.
- resource_arns
list(string)
- Specific resource ARNs or ARN patterns. When set, actions are limited to these resources. When absent, defaults to all resources of the type.
- row_scope_groups
list(list(object))
- Row-level filters for this scope, as an OR of AND-groups: a row is visible when it matches every filter in any one group. Requires SignalTypes.
- signal_types
list("LOGS" | "TRACES")
- Signal types this scope's row filtering applies to. Required when RowScopeGroups is set.
- tags
map(string)
- Tag-based conditions for dynamic resource scoping. Access applies only to resources carrying all of the specified tag key-value pairs.
- resourceType
String
- The resource type name, for example DataSet or OmniDashboard.
- resourceArns
List<String>
- Specific resource ARNs or ARN patterns. When set, actions are limited to these resources. When absent, defaults to all resources of the type.
- rowScopeGroups
List<List<AccessGrantRowScope>>
- Row-level filters for this scope, as an OR of AND-groups: a row is visible when it matches every filter in any one group. Requires SignalTypes.
- signalTypes
List<AccessGrantResourceScopeSignalTypesItem>
- Signal types this scope's row filtering applies to. Required when RowScopeGroups is set.
- tags
Map<String,String>
- Tag-based conditions for dynamic resource scoping. Access applies only to resources carrying all of the specified tag key-value pairs.
- resourceType
string
- The resource type name, for example DataSet or OmniDashboard.
- resourceArns
string[]
- Specific resource ARNs or ARN patterns. When set, actions are limited to these resources. When absent, defaults to all resources of the type.
- rowScopeGroups
AccessGrantRowScope[][]
- Row-level filters for this scope, as an OR of AND-groups: a row is visible when it matches every filter in any one group. Requires SignalTypes.
- signalTypes
AccessGrantResourceScopeSignalTypesItem[]
- Signal types this scope's row filtering applies to. Required when RowScopeGroups is set.
- tags
{[key: string]: string}
- Tag-based conditions for dynamic resource scoping. Access applies only to resources carrying all of the specified tag key-value pairs.
- resource_type
str
- The resource type name, for example DataSet or OmniDashboard.
- resource_arns
Sequence[str]
- Specific resource ARNs or ARN patterns. When set, actions are limited to these resources. When absent, defaults to all resources of the type.
- row_scope_groups
Sequence[Sequence[AccessGrantRowScope]]
- Row-level filters for this scope, as an OR of AND-groups: a row is visible when it matches every filter in any one group. Requires SignalTypes.
- signal_types
Sequence[AccessGrantResourceScopeSignalTypesItem]
- Signal types this scope's row filtering applies to. Required when RowScopeGroups is set.
- tags
Mapping[str, str]
- Tag-based conditions for dynamic resource scoping. Access applies only to resources carrying all of the specified tag key-value pairs.
- resourceType
String
- The resource type name, for example DataSet or OmniDashboard.
- resourceArns
List<String>
- Specific resource ARNs or ARN patterns. When set, actions are limited to these resources. When absent, defaults to all resources of the type.
- rowScopeGroups
List<List<Property Map>>
- Row-level filters for this scope, as an OR of AND-groups: a row is visible when it matches every filter in any one group. Requires SignalTypes.
- signalTypes
List<"LOGS" | "TRACES">
- Signal types this scope's row filtering applies to. Required when RowScopeGroups is set.
- tags
Map<String>
- Tag-based conditions for dynamic resource scoping. Access applies only to resources carrying all of the specified tag key-value pairs.
AccessGrantResourceScopeSignalTypesItem
| Name | Value |
|---|
| Logs | LOGS |
| Traces | TRACES |
| Name | Value |
|---|
| AccessGrantResourceScopeSignalTypesItemLogs | LOGS |
| AccessGrantResourceScopeSignalTypesItemTraces | TRACES |
| Name | Value |
|---|
| Logs | LOGS |
| Traces | TRACES |
| Name | Value |
|---|
| Logs | LOGS |
| Traces | TRACES |
| Name | Value |
|---|
| LOGS | LOGS |
| TRACES | TRACES |
AccessGrantRowScope, AccessGrantRowScopeArgs
A single additive row-level filter on an access grant. A row is visible when its value for the given field matches the filter's values.
- field
string
- The field the allowlist applies to, for example serviceName or accountId.
- operator
"IN"
- Match operator applied to this filter's values.
- values
list(string)
- The values the field is matched against.
- field
String
- The field the allowlist applies to, for example serviceName or accountId.
- operator
"IN"
- Match operator applied to this filter's values.
- values
List<String>
- The values the field is matched against.
AccessGrantRowScopeOperator
Match operator applied to this filter's values.
| Name | Value |
|---|
| AccessGrantRowScopeOperatorIn | IN |
AccessGrantScopedActions, AccessGrantScopedActionsArgs
A group of actions within an access grant, together with the resource scopes and context conditions that apply to exactly those actions.
- Actions
[]string
- The actions this group applies to, each in vendor-code:Action form.
- ContextConditions
map[string][]string
- Context conditions for fine-grained access control on these actions, as a map of condition keys to lists of allowed values.
- Resources
[]AccessGrantResourceScope
- Resource scopes constraining these actions to specific resources.
- actions
list(string)
- The actions this group applies to, each in vendor-code:Action form.
- context_conditions
map(list(string))
- Context conditions for fine-grained access control on these actions, as a map of condition keys to lists of allowed values.
- resources
list(object)
- Resource scopes constraining these actions to specific resources.
- actions
List<String>
- The actions this group applies to, each in vendor-code:Action form.
- contextConditions
Map<String,List<String>>
- Context conditions for fine-grained access control on these actions, as a map of condition keys to lists of allowed values.
- resources
List<AccessGrantResourceScope>
- Resource scopes constraining these actions to specific resources.
- actions
string[]
- The actions this group applies to, each in vendor-code:Action form.
- contextConditions
{[key: string]: string[]}
- Context conditions for fine-grained access control on these actions, as a map of condition keys to lists of allowed values.
- resources
AccessGrantResourceScope[]
- Resource scopes constraining these actions to specific resources.
- actions
Sequence[str]
- The actions this group applies to, each in vendor-code:Action form.
- context_conditions
Mapping[str, Sequence[str]]
- Context conditions for fine-grained access control on these actions, as a map of condition keys to lists of allowed values.
- resources
Sequence[AccessGrantResourceScope]
- Resource scopes constraining these actions to specific resources.
- actions
List<String>
- The actions this group applies to, each in vendor-code:Action form.
- contextConditions
Map<List<String>>
- Context conditions for fine-grained access control on these actions, as a map of condition keys to lists of allowed values.
- resources
List<Property Map>
- Resource scopes constraining these actions to specific resources.
CreateOnlyTag, CreateOnlyTagArgs
A set of tags to apply to the resource.
- Key
string
- The key name of the tag
- Value
string
- The value of the tag
- Key
string
- The key name of the tag
- Value
string
- The value of the tag
- key
string
- The key name of the tag
- value
string
- The value of the tag
- key
String
- The key name of the tag
- value
String
- The value of the tag
- key
string
- The key name of the tag
- value
string
- The value of the tag
- key
str
- The key name of the tag
- value
str
- The value of the tag
- key
String
- The key name of the tag
- value
String
- The value of the tag
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0