listProxySessions method
Lists the proxy sessions for the specified Amazon Chime SDK Voice Connector.
May throw BadRequestException.
May throw ForbiddenException.
May throw NotFoundException.
May throw ServiceFailureException.
May throw ServiceUnavailableException.
May throw ThrottledClientException.
May throw UnauthorizedClientException.
Parameter voiceConnectorId :
The Voice Connector ID.
Parameter maxResults :
The maximum number of results to return in a single call.
Parameter nextToken :
The token used to retrieve the next page of results.
Parameter status :
The proxy session status.
Implementation
Future<ListProxySessionsResponse> listProxySessions({
required String voiceConnectorId,
int? maxResults,
String? nextToken,
ProxySessionStatus? status,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
100,
);
final $query = <String, List<String>>{
if (maxResults != null) 'max-results': [maxResults.toString()],
if (nextToken != null) 'next-token': [nextToken],
if (status != null) 'status': [status.value],
};
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri:
'/voice-connectors/${Uri.encodeComponent(voiceConnectorId)}/proxy-sessions',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return ListProxySessionsResponse.fromJson(response);
}