updateDomainName method

Future<UpdateDomainNameResponse> updateDomainName({
  1. required String domainName,
  2. List<DomainNameConfiguration>? domainNameConfigurations,
  3. MutualTlsAuthenticationInput? mutualTlsAuthentication,
})

Updates a domain name.

May throw NotFoundException. May throw TooManyRequestsException. May throw BadRequestException. May throw ConflictException.

Parameter domainName : The domain name.

Parameter domainNameConfigurations : The domain name configurations.

Parameter mutualTlsAuthentication : The mutual TLS authentication configuration for a custom domain name.

Implementation

Future<UpdateDomainNameResponse> updateDomainName({
  required String domainName,
  List<DomainNameConfiguration>? domainNameConfigurations,
  MutualTlsAuthenticationInput? mutualTlsAuthentication,
}) async {
  ArgumentError.checkNotNull(domainName, 'domainName');
  final $payload = <String, dynamic>{
    if (domainNameConfigurations != null)
      'domainNameConfigurations': domainNameConfigurations,
    if (mutualTlsAuthentication != null)
      'mutualTlsAuthentication': mutualTlsAuthentication,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'PATCH',
    requestUri: '/v2/domainnames/${Uri.encodeComponent(domainName)}',
    exceptionFnMap: _exceptionFns,
  );
  return UpdateDomainNameResponse.fromJson(response);
}