untagResource method

Future<void> untagResource({
  1. required String resourceArn,
  2. required List<String> tagKeys,
})

Removes the specified tags from an Amazon Cognito identity pool. You can use this action up to 5 times per second, per account

May throw InvalidParameterException. May throw ResourceNotFoundException. May throw NotAuthorizedException. May throw TooManyRequestsException. May throw InternalErrorException.

Parameter resourceArn : The Amazon Resource Name (ARN) of the identity pool that the tags are assigned to.

Parameter tagKeys : The keys of the tags to remove from the user pool.

Implementation

Future<void> untagResource({
  required String resourceArn,
  required List<String> tagKeys,
}) async {
  ArgumentError.checkNotNull(resourceArn, 'resourceArn');
  _s.validateStringLength(
    'resourceArn',
    resourceArn,
    20,
    2048,
    isRequired: true,
  );
  ArgumentError.checkNotNull(tagKeys, 'tagKeys');
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AWSCognitoIdentityService.UntagResource'
  };
  await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ResourceArn': resourceArn,
      'TagKeys': tagKeys,
    },
  );
}