CfnAccessKeyPropsMixin

class aws_cdk.mixins_preview.aws_iam.mixins.CfnAccessKeyPropsMixin(props, *, strategy=None)

Bases: Mixin

Creates a new AWS secret access key and corresponding AWS access key ID for the specified user.

The default status for new keys is Active .

For information about quotas on the number of keys you can create, see IAM and AWS STS quotas in the IAM User Guide . .. epigraph:

To ensure the security of your AWS account , the secret access key is accessible only during key and user creation. You must save the key (for example, in a text file) if you want to be able to access it again. If a secret key is lost, you can rotate access keys by increasing the value of the ``serial`` property.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iam-accesskey.html

CloudformationResource:

AWS::IAM::AccessKey

Mixin:

true

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.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_iam import mixins as iam_mixins

cfn_access_key_props_mixin = iam_mixins.CfnAccessKeyPropsMixin(iam_mixins.CfnAccessKeyMixinProps(
    serial=123,
    status="status",
    user_name="userName"
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::IAM::AccessKey.

Parameters:
  • props (Union[CfnAccessKeyMixinProps, Dict[str, Any]]) – L1 properties to apply.

  • strategy (Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['serial', 'status', 'userName']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental