Sets tags (key and value pairs) to the assessment template that is specified by the ARN of the assessment template.
See also: AWS API Documentation
Request Syntax
response = client.set_tags_for_resource(
resourceArn='string',
tags=[
{
'key': 'string',
'value': 'string'
},
]
)
[REQUIRED]
The ARN of the assessment template that you want to set tags to.
A collection of key and value pairs that you want to set to the assessment template.
A key and value pair. This data type is used as a request parameter in the SetTagsForResource action and a response element in the ListTagsForResource action.
A tag key.
A value assigned to a tag key.
None
Exceptions
Inspector.Client.exceptions.InternalException
Inspector.Client.exceptions.InvalidInputException
Inspector.Client.exceptions.AccessDeniedException
Inspector.Client.exceptions.NoSuchEntityException
Inspector.Client.exceptions.ServiceTemporarilyUnavailableException
Examples
Sets tags (key and value pairs) to the assessment template that is specified by the ARN of the assessment template.
response = client.set_tags_for_resource(
resourceArn='arn:aws:inspector:us-west-2:123456789012:target/0-nvgVhaxX/template/0-7sbz2Kz0',
tags=[
{
'key': 'Example',
'value': 'example',
},
],
)
print(response)
Expected Output:
{
'ResponseMetadata': {
'...': '...',
},
}