CfnAPIKeyProps

class aws_cdk.aws_location.CfnAPIKeyProps(*, key_name, restrictions, description=None, expire_time=None, force_delete=None, force_update=None, no_expiry=None, tags=None)

Bases: object

Properties for defining a CfnAPIKey.

Parameters:
  • key_name (str) – A custom name for the API key resource. Requirements: - Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_). - Must be a unique API key name. - No spaces allowed. For example, ExampleAPIKey .

  • restrictions (Union[IResolvable, ApiKeyRestrictionsProperty, Dict[str, Any]]) – The API key restrictions for the API key resource.

  • description (Optional[str]) – Updates the description for the API key resource.

  • expire_time (Optional[str]) – The optional timestamp for when the API key resource will expire in ISO 8601 format .

  • force_delete (Union[bool, IResolvable, None]) – ForceDelete bypasses an API key’s expiry conditions and deletes the key. Set the parameter true to delete the key or to false to not preemptively delete the API key. Valid values: true , or false . .. epigraph:: This action is irreversible. Only use ForceDelete if you are certain the key is no longer in use.

  • force_update (Union[bool, IResolvable, None]) – The boolean flag to be included for updating ExpireTime or Restrictions details. Must be set to true to update an API key resource that has been used in the past 7 days. False if force update is not preferred.

  • no_expiry (Union[bool, IResolvable, None]) – Whether the API key should expire. Set to true to set the API key to have no expiration time.

  • tags (Optional[Sequence[Union[CfnTag, Dict[str, Any]]]]) – Applies one or more tags to the map resource. A tag is a key-value pair that helps manage, identify, search, and filter your resources by labelling them.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html

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_location as location

cfn_aPIKey_props = location.CfnAPIKeyProps(
    key_name="keyName",
    restrictions=location.CfnAPIKey.ApiKeyRestrictionsProperty(
        allow_actions=["allowActions"],
        allow_resources=["allowResources"],

        # the properties below are optional
        allow_referers=["allowReferers"]
    ),

    # the properties below are optional
    description="description",
    expire_time="expireTime",
    force_delete=False,
    force_update=False,
    no_expiry=False,
    tags=[CfnTag(
        key="key",
        value="value"
    )]
)

Attributes

description

Updates the description for the API key resource.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-description

expire_time

//www.iso.org/iso-8601-date-and-time-format.html>`_ .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-expiretime

Type:

The optional timestamp for when the API key resource will expire in `ISO 8601 format <https

Type:

//docs.aws.amazon.com/https

force_delete

ForceDelete bypasses an API key’s expiry conditions and deletes the key.

Set the parameter true to delete the key or to false to not preemptively delete the API key.

Valid values: true , or false . .. epigraph:

This action is irreversible. Only use ForceDelete if you are certain the key is no longer in use.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-forcedelete

force_update

The boolean flag to be included for updating ExpireTime or Restrictions details.

Must be set to true to update an API key resource that has been used in the past 7 days. False if force update is not preferred.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-forceupdate

key_name

A custom name for the API key resource.

Requirements:

  • Contain only alphanumeric characters (A–Z, a–z, 0–9), hyphens (-), periods (.), and underscores (_).

  • Must be a unique API key name.

  • No spaces allowed. For example, ExampleAPIKey .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-keyname

no_expiry

Whether the API key should expire.

Set to true to set the API key to have no expiration time.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-noexpiry

restrictions

The API key restrictions for the API key resource.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-restrictions

tags

Applies one or more tags to the map resource.

A tag is a key-value pair that helps manage, identify, search, and filter your resources by labelling them.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-location-apikey.html#cfn-location-apikey-tags