listTemplateShares method
List review template shares.
May throw AccessDeniedException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter templateArn :
The review template ARN.
Parameter maxResults :
The maximum number of results to return for this request.
Parameter sharedWithPrefix :
The Amazon Web Services account ID, organization ID, or organizational
unit (OU) ID with which the profile is shared.
Implementation
Future<ListTemplateSharesOutput> listTemplateShares({
required String templateArn,
int? maxResults,
String? nextToken,
String? sharedWithPrefix,
ShareStatus? status,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
50,
);
final $query = <String, List<String>>{
if (maxResults != null) 'MaxResults': [maxResults.toString()],
if (nextToken != null) 'NextToken': [nextToken],
if (sharedWithPrefix != null) 'SharedWithPrefix': [sharedWithPrefix],
if (status != null) 'Status': [status.value],
};
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri: '/templates/shares/${Uri.encodeComponent(templateArn)}',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return ListTemplateSharesOutput.fromJson(response);
}