listStateTemplates method
Lists information about created state templates.
May throw AccessDeniedException.
May throw InternalServerException.
May throw ThrottlingException.
May throw ValidationException.
Parameter listResponseScope :
When you set the listResponseScope parameter to
METADATA_ONLY, the list response includes: state template ID,
Amazon Resource Name (ARN), creation time, and last modification time.
Parameter maxResults :
The maximum number of items to return, between 1 and 100, inclusive.
Parameter nextToken :
The token to retrieve the next set of results, or null if
there are no more results.
Implementation
Future<ListStateTemplatesResponse> listStateTemplates({
ListResponseScope? listResponseScope,
int? maxResults,
String? nextToken,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
100,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target': 'IoTAutobahnControlPlane.ListStateTemplates'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (listResponseScope != null)
'listResponseScope': listResponseScope.value,
if (maxResults != null) 'maxResults': maxResults,
if (nextToken != null) 'nextToken': nextToken,
},
);
return ListStateTemplatesResponse.fromJson(jsonResponse.body);
}