getConnectPeerAssociations method
Returns information about a core network Connect peer associations.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter globalNetworkId :
The ID of the global network.
Parameter connectPeerIds :
The IDs of the Connect peers.
Parameter maxResults :
The maximum number of results to return.
Parameter nextToken :
The token for the next page of results.
Implementation
Future<GetConnectPeerAssociationsResponse> getConnectPeerAssociations({
required String globalNetworkId,
List<String>? connectPeerIds,
int? maxResults,
String? nextToken,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
500,
);
final $query = <String, List<String>>{
if (connectPeerIds != null) 'connectPeerIds': connectPeerIds,
if (maxResults != null) 'maxResults': [maxResults.toString()],
if (nextToken != null) 'nextToken': [nextToken],
};
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri:
'/global-networks/${Uri.encodeComponent(globalNetworkId)}/connect-peer-associations',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return GetConnectPeerAssociationsResponse.fromJson(response);
}