deleteUserProfile method

Future<void> deleteUserProfile({
  1. required String iamUserArn,
})

Deletes a user profile.

Required Permissions: To use this action, an IAM user must have an attached policy that explicitly grants permissions. For more information about user permissions, see Managing User Permissions.

May throw ValidationException. May throw ResourceNotFoundException.

Parameter iamUserArn : The user's IAM ARN. This can also be a federated user's ARN.

Implementation

Future<void> deleteUserProfile({
  required String iamUserArn,
}) async {
  ArgumentError.checkNotNull(iamUserArn, 'iamUserArn');
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'OpsWorks_20130218.DeleteUserProfile'
  };
  await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'IamUserArn': iamUserArn,
    },
  );
}