listDomains method
Retrieves a list of domains associated to a specified fleet.
May throw UnauthorizedException. May throw InternalServerErrorException. May throw InvalidRequestException. May throw ResourceNotFoundException. May throw TooManyRequestsException.
Parameter fleetArn
:
The ARN of the fleet.
Parameter maxResults
:
The maximum number of results to be included in the next page.
Parameter nextToken
:
The pagination token used to retrieve the next page of results for this
operation. If this value is null, it retrieves the first page.
Implementation
Future<ListDomainsResponse> listDomains({
required String fleetArn,
int? maxResults,
String? nextToken,
}) async {
ArgumentError.checkNotNull(fleetArn, 'fleetArn');
_s.validateStringLength(
'fleetArn',
fleetArn,
20,
2048,
isRequired: true,
);
_s.validateNumRange(
'maxResults',
maxResults,
1,
1152921504606846976,
);
_s.validateStringLength(
'nextToken',
nextToken,
1,
4096,
);
final $payload = <String, dynamic>{
'FleetArn': fleetArn,
if (maxResults != null) 'MaxResults': maxResults,
if (nextToken != null) 'NextToken': nextToken,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/listDomains',
exceptionFnMap: _exceptionFns,
);
return ListDomainsResponse.fromJson(response);
}