listImages method
Returns the list of images that you have access to. Newly created images can take up to two minutes to appear in the ListImages API Results.
May throw CallRateLimitExceededException.
May throw ClientException.
May throw ForbiddenException.
May throw InvalidPaginationTokenException.
May throw InvalidRequestException.
May throw ServiceException.
May throw ServiceUnavailableException.
Parameter byName :
Requests a list of images with a specific recipe name.
Parameter filters :
Use the following filters to streamline results:
-
name -
osVersion -
platform -
type -
version
Parameter includeDeprecated :
Includes deprecated images in the response list.
Parameter maxResults :
Specify the maximum number of items to return in a request.
Parameter nextToken :
A token to specify where to start paginating. This is the nextToken from a
previously truncated response.
Parameter owner :
The owner defines which images you want to list. By default, this request
will only show images owned by your account. You can use this field to
specify if you want to view images owned by yourself, by Amazon, or those
images that have been shared with you by other customers.
Implementation
Future<ListImagesResponse> listImages({
bool? byName,
List<Filter>? filters,
bool? includeDeprecated,
int? maxResults,
String? nextToken,
Ownership? owner,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
25,
);
final $payload = <String, dynamic>{
if (byName != null) 'byName': byName,
if (filters != null) 'filters': filters,
if (includeDeprecated != null) 'includeDeprecated': includeDeprecated,
if (maxResults != null) 'maxResults': maxResults,
if (nextToken != null) 'nextToken': nextToken,
if (owner != null) 'owner': owner.value,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/ListImages',
exceptionFnMap: _exceptionFns,
);
return ListImagesResponse.fromJson(response);
}