tagResource method
Creates a tag for an EFS resource. You can create tags for EFS file systems and access points using this API operation.
This operation requires permissions for the
elasticfilesystem:TagResource
action.
May throw BadRequest. May throw InternalServerError. May throw FileSystemNotFound. May throw AccessPointNotFound.
Parameter resourceId
:
The ID specifying the EFS resource that you want to create a tag for.
Parameter tags
:
Implementation
Future<void> tagResource({
required String resourceId,
required List<Tag> tags,
}) async {
ArgumentError.checkNotNull(resourceId, 'resourceId');
ArgumentError.checkNotNull(tags, 'tags');
final $payload = <String, dynamic>{
'Tags': tags,
};
await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/2015-02-01/resource-tags/${Uri.encodeComponent(resourceId)}',
exceptionFnMap: _exceptionFns,
);
}