listRelays method
Lists all the existing relay resources.
May throw ValidationException.
Parameter nextToken :
If you received a pagination token from a previous call to this API, you
can provide it here to continue paginating through the next page of
results.
Parameter pageSize :
The number of relays to be returned in one request.
Implementation
Future<ListRelaysResponse> listRelays({
String? nextToken,
int? pageSize,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'MailManagerSvc.ListRelays'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (nextToken != null) 'NextToken': nextToken,
if (pageSize != null) 'PageSize': pageSize,
},
);
return ListRelaysResponse.fromJson(jsonResponse.body);
}