create_tags

Redshift.Client.create_tags(**kwargs)

Adds tags to a cluster.

A resource can have up to 50 tags. If you try to create more than 50 tags for a resource, you will receive an error and the attempt will fail.

If you specify a key that already exists for the resource, the value for that key will be updated with the new value.

See also: AWS API Documentation

Request Syntax

response = client.create_tags(
    ResourceName='string',
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
)
Parameters
  • ResourceName (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) to which you want to add the tag or tags. For example, arn:aws:redshift:us-east-2:123456789:cluster:t1 .

  • Tags (list) --

    [REQUIRED]

    One or more name/value pairs to add as tags to the specified resource. Each tag name is passed in with the parameter Key and the corresponding value is passed in with the parameter Value . The Key and Value parameters are separated by a comma (,). Separate multiple tags with a space. For example, --tags "Key"="owner","Value"="admin" "Key"="environment","Value"="test" "Key"="version","Value"="1.0" .

    • (dict) --

      A tag consisting of a name/value pair for a resource.

      • Key (string) --

        The key, or name, for the resource tag.

      • Value (string) --

        The value for the resource tag.

Returns

None

Exceptions

  • Redshift.Client.exceptions.TagLimitExceededFault
  • Redshift.Client.exceptions.ResourceNotFoundFault
  • Redshift.Client.exceptions.InvalidTagFault
  • Redshift.Client.exceptions.InvalidClusterStateFault