Glacier / Client / list_tags_for_vault
list_tags_for_vault¶
- Glacier.Client.list_tags_for_vault(**kwargs)¶
This operation lists all the tags attached to a vault. The operation returns an empty map if there are no tags. For more information about tags, see Tagging Amazon Glacier Resources.
See also: AWS API Documentation
Request Syntax
response = client.list_tags_for_vault( vaultName='string' )
- Parameters:
accountId (string) –
The
AccountIdvalue is the AWS account ID of the account that owns the vault. You can either specify an AWS account ID or optionally a single ‘-’ (hyphen), in which case Amazon Glacier uses the AWS account ID associated with the credentials used to sign the request. If you use an account ID, do not include any hyphens (‘-’) in the ID.Note: this parameter is set to “-” bydefault if no value is not specified.
vaultName (string) –
[REQUIRED]
The name of the vault.
- Return type:
dict
- Returns:
Response Syntax
{ 'Tags': { 'string': 'string' } }
Response Structure
(dict) –
Contains the Amazon Glacier response to your request.
Tags (dict) –
The tags attached to the vault. Each tag is composed of a key and a value.
(string) –
(string) –
Exceptions
Glacier.Client.exceptions.InvalidParameterValueExceptionGlacier.Client.exceptions.MissingParameterValueExceptionGlacier.Client.exceptions.ResourceNotFoundExceptionGlacier.Client.exceptions.ServiceUnavailableExceptionGlacier.Client.exceptions.NoLongerSupportedException
Examples
The example lists all the tags attached to the vault examplevault.
response = client.list_tags_for_vault( accountId='-', vaultName='examplevault', ) print(response)
Expected Output:
{ 'Tags': { 'date': 'july2015', 'id': '1234', }, 'ResponseMetadata': { '...': '...', }, }