tagResource method
Adds to or modifies the tags of the given resource. Tags are metadata that can be used to manage a resource.
May throw InternalFailureException.
May throw InvalidRequestException.
May throw LimitExceededException.
May throw ResourceInUseException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
Parameter resourceArn :
The ARN of the resource.
Parameter tags :
The new or modified tags for the resource.
Implementation
Future<void> tagResource({
required String resourceArn,
required List<Tag> tags,
}) async {
final $query = <String, List<String>>{
'resourceArn': [resourceArn],
};
final $payload = <String, dynamic>{
'tags': tags,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/tags',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
}