cdk-iam-floyd
Version:
AWS IAM policy statement generator with fluent interface for AWS CDK
359 lines (358 loc) • 13 kB
TypeScript
import { AccessLevelList } from '../../shared/access-level';
import { PolicyStatement, Operator } from '../../shared';
import { aws_iam as iam } from "aws-cdk-lib";
/**
* Statement provider for service [route53-recovery-control-config](https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonroute53recoverycontrols.html).
*
* @param sid [SID](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html) of the statement
*/
export declare class Route53RecoveryControlConfig extends PolicyStatement {
servicePrefix: string;
/**
* Grants permission to create a cluster
*
* Access Level: Write
*
* Possible conditions:
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster.html
*/
toCreateCluster(): this;
/**
* Grants permission to create a control panel
*
* Access Level: Write
*
* Possible conditions:
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel.html
*/
toCreateControlPanel(): this;
/**
* Grants permission to create a routing control
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol.html
*/
toCreateRoutingControl(): this;
/**
* Grants permission to create a safety rule
*
* Access Level: Write
*
* Possible conditions:
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/safetyrule.html
*/
toCreateSafetyRule(): this;
/**
* Grants permission to delete a cluster
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster-clusterarn.html
*/
toDeleteCluster(): this;
/**
* Grants permission to delete a control panel
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel-controlpanelarn.html
*/
toDeleteControlPanel(): this;
/**
* Grants permission to delete the RAM access control policy for a cluster
*
* Access Level: Write
*
* https://docs.aws.amazon.com/r53recovery/latest/dg/routing-control.failover-different-accounts.html
*/
toDeleteResourcePolicy(): this;
/**
* Grants permission to delete a routing control
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol-routingcontrolarn.html
*/
toDeleteRoutingControl(): this;
/**
* Grants permission to delete a safety rule
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/safetyrule-safetyrulearn.html
*/
toDeleteSafetyRule(): this;
/**
* Grants permission to describe a cluster
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster-clusterarn.html
*/
toDescribeCluster(): this;
/**
* Grants permission to describe a control panel
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel-controlpanelarn.html
*/
toDescribeControlPanel(): this;
/**
* Grants permission to describe a routing control
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol-routingcontrolarn.html
*/
toDescribeRoutingControl(): this;
/**
* Grants permission to describe a routing control
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol-routingcontrolarn.html
*/
toDescribeRoutingControlByName(): this;
/**
* Grants permission to describe a safety rule
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/safetyrule-safetyrulearn.html
*/
toDescribeSafetyRule(): this;
/**
* Grants permission to get the resource policy of a cluster
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster/resourcepolicy-resourcearn.html
*/
toGetResourcePolicy(): this;
/**
* Grants permission to list associated Route 53 health checks
*
* Access Level: List
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol-routingcontrolarn-associatedroute53healthchecks.html
*/
toListAssociatedRoute53HealthChecks(): this;
/**
* Grants permission to list clusters
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster.html
*/
toListClusters(): this;
/**
* Grants permission to list control panels
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanels.html
*/
toListControlPanels(): this;
/**
* Grants permission to list routing controls
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel-controlpanelarn-routingcontrols.html
*/
toListRoutingControls(): this;
/**
* Grants permission to list safety rules
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel-controlpanelarn-safetyrules.html
*/
toListSafetyRules(): this;
/**
* Grants permission to list tags for a resource
*
* Access Level: Read
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/tags-resource-arn.html
*/
toListTagsForResource(): this;
/**
* Grants permission to define the RAM access control policy for a cluster
*
* Access Level: Write
*
* https://docs.aws.amazon.com/r53recovery/latest/dg/routing-control.failover-different-accounts.html
*/
toPutResourcePolicy(): this;
/**
* Grants permission to tag a resource
*
* Access Level: Tagging
*
* Possible conditions:
* - .ifAwsTagKeys()
* - .ifAwsRequestTag()
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/tags-resource-arn.html
*/
toTagResource(): this;
/**
* Grants permission to remove tags from a resource
*
* Access Level: Tagging
*
* Possible conditions:
* - .ifAwsTagKeys()
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/tags-resource-arn.html
*/
toUntagResource(): this;
/**
* Grants permission to update a cluster
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster.html
*/
toUpdateCluster(): this;
/**
* Grants permission to update a cluster
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel.html
*/
toUpdateControlPanel(): this;
/**
* Grants permission to update a routing control
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol.html
*/
toUpdateRoutingControl(): this;
/**
* Grants permission to update a safety rule
*
* Access Level: Write
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/safetyrule.html
*/
toUpdateSafetyRule(): this;
protected accessLevelList: AccessLevelList;
/**
* Adds a resource of type cluster to the statement
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/cluster.html
*
* @param resourceId - Identifier for the resourceId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*
* Possible conditions:
* - .ifAwsResourceTag()
*/
onCluster(resourceId: string, account?: string, partition?: string): this;
/**
* Adds a resource of type controlpanel to the statement
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/controlpanel.html
*
* @param controlPanelId - Identifier for the controlPanelId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*
* Possible conditions:
* - .ifAwsResourceTag()
*/
onControlpanel(controlPanelId: string, account?: string, partition?: string): this;
/**
* Adds a resource of type routingcontrol to the statement
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/routingcontrol.html
*
* @param controlPanelId - Identifier for the controlPanelId.
* @param routingControlId - Identifier for the routingControlId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*/
onRoutingcontrol(controlPanelId: string, routingControlId: string, account?: string, partition?: string): this;
/**
* Adds a resource of type safetyrule to the statement
*
* https://docs.aws.amazon.com/recovery-cluster/latest/api/safetyrule.html
*
* @param controlPanelId - Identifier for the controlPanelId.
* @param safetyRuleId - Identifier for the safetyRuleId.
* @param account - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account.
* @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition.
*
* Possible conditions:
* - .ifAwsResourceTag()
*/
onSafetyrule(controlPanelId: string, safetyRuleId: string, account?: string, partition?: string): this;
/**
* Filters access by a tag's key and value in a request
*
* https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-requesttag
*
* Applies to actions:
* - .toCreateCluster()
* - .toCreateControlPanel()
* - .toCreateSafetyRule()
* - .toTagResource()
*
* @param tagKey The tag key to check
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
ifAwsRequestTag(tagKey: string, value: string | string[], operator?: Operator | string): this;
/**
* Filters access by tag key-value pairs attached to the resource
*
* https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-resourcetag
*
* Applies to resource types:
* - cluster
* - controlpanel
* - safetyrule
*
* @param tagKey The tag key to check
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
ifAwsResourceTag(tagKey: string, value: string | string[], operator?: Operator | string): this;
/**
* Filters access by the presence of tag keys in the request
*
* https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-tagkeys
*
* Applies to actions:
* - .toCreateCluster()
* - .toCreateControlPanel()
* - .toCreateSafetyRule()
* - .toTagResource()
* - .toUntagResource()
*
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
ifAwsTagKeys(value: string | string[], operator?: Operator | string): this;
/**
* Statement provider for service [route53-recovery-control-config](https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonroute53recoverycontrols.html).
*
*/
constructor(props?: iam.PolicyStatementProps);
}