createAccount method

Future<CreateAccountResponse> createAccount({
  1. required String name,
})

Creates an Amazon Chime account under the administrator's AWS account. Only Team account types are currently supported for this action. For more information about different account types, see Managing Your Amazon Chime Accounts in the Amazon Chime Administration Guide.

May throw UnauthorizedClientException. May throw NotFoundException. May throw ForbiddenException. May throw BadRequestException. May throw ThrottledClientException. May throw ServiceUnavailableException. May throw ServiceFailureException.

Parameter name : The name of the Amazon Chime account.

Implementation

Future<CreateAccountResponse> createAccount({
  required String name,
}) async {
  ArgumentError.checkNotNull(name, 'name');
  _s.validateStringLength(
    'name',
    name,
    1,
    100,
    isRequired: true,
  );
  final $payload = <String, dynamic>{
    'Name': name,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/accounts',
    exceptionFnMap: _exceptionFns,
  );
  return CreateAccountResponse.fromJson(response);
}