createMultiRegionEndpoint method

Future<CreateMultiRegionEndpointResponse> createMultiRegionEndpoint({
  1. required Details details,
  2. required String endpointName,
  3. List<Tag>? tags,
})

Creates a multi-region endpoint (global-endpoint).

The primary region is going to be the AWS-Region where the operation is executed. The secondary region has to be provided in request's parameters. From the data flow standpoint there is no difference between primary and secondary regions - sending traffic will be split equally between the two. The primary region is the region where the resource has been created and where it can be managed.

May throw AlreadyExistsException. May throw BadRequestException. May throw LimitExceededException. May throw TooManyRequestsException.

Parameter details : Contains details of a multi-region endpoint (global-endpoint) being created.

Parameter endpointName : The name of the multi-region endpoint (global-endpoint).

Parameter tags : An array of objects that define the tags (keys and values) to associate with the multi-region endpoint (global-endpoint).

Implementation

Future<CreateMultiRegionEndpointResponse> createMultiRegionEndpoint({
  required Details details,
  required String endpointName,
  List<Tag>? tags,
}) async {
  final $payload = <String, dynamic>{
    'Details': details,
    'EndpointName': endpointName,
    if (tags != null) 'Tags': tags,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/v2/email/multi-region-endpoints',
    exceptionFnMap: _exceptionFns,
  );
  return CreateMultiRegionEndpointResponse.fromJson(response);
}