Skip to content

describe_images async

describe_images(
    *,
    config_overrides: Optional[AsyncAppStreamClientConfig] = None,
    names: Optional[StringList] = None,
    arns: Optional[ArnList] = None,
    type: Optional[VisibilityType] = None,
    next_token: Optional[String] = None,
    max_results: Optional[DescribeImagesMaxResults] = None,
) -> DescribeImagesResult

Retrieves a list that describes one or more specified images, if the image names or image ARNs are provided. Otherwise, all images in the account are described.

Parameters:

  • names (Optional[StringList], default: None ) –

    The names of the public or private images to describe.

  • arns (Optional[ArnList], default: None ) –

    The ARNs of the public, private, and shared images to describe.

  • type (Optional[VisibilityType], default: None ) –

    The type of image (public, private, or shared) to describe.

  • next_token (Optional[String], default: None ) –

    The pagination token to use to retrieve the next page of results for this operation. If this value is null, it retrieves the first page.

  • max_results (Optional[DescribeImagesMaxResults], default: None ) –

    The maximum size of each page of results.

Raises:

Source code in docs_src/capo_appstream/_services/async_app_stream.py
async def describe_images(
    self,
    *,
    config_overrides: Optional[AsyncAppStreamClientConfig] = None,
    names: Optional["capo_appstream.types.string_list.StringList"] = None,
    arns: Optional["capo_appstream.types.arn_list.ArnList"] = None,
    type: Optional["capo_appstream.types.visibility_type.VisibilityType"] = None,
    next_token: Optional["capo_appstream.types.string.String"] = None,
    max_results: Optional[
        "capo_appstream.types.describe_images_max_results.DescribeImagesMaxResults"
    ] = None,
) -> "capo_appstream.types.describe_images_result.DescribeImagesResult":
    """<p>Retrieves a list that describes one or more specified images, if the image names or image ARNs are provided. Otherwise, all images in the account are described.</p>

    Args:
        names: <p>The names of the public or private images to describe.</p>
        arns: <p>The ARNs of the public, private, and shared images to describe.</p>
        type: <p>The type of image (public, private, or shared) to describe. </p>
        next_token: <p>The pagination token to use to retrieve the next page of results for this operation. If this value is null, it retrieves the first page.</p>
        max_results: <p>The maximum size of each page of results.</p>

    Raises:
        capo_appstream.errors.invalid_parameter_combination_exception.InvalidParameterCombinationException: <p>Indicates an incorrect combination of parameters, or a missing parameter.</p>
        capo_appstream.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource was not found.</p>
        capo_appstream.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_appstream.types.describe_images_request.DescribeImagesRequest]",
    ) -> AsyncOperationResponse[
        "capo_appstream.types.describe_images_result.DescribeImagesResult"
    ]:
        import capo_appstream._operations.photon_admin_proxy_service.describe_images

        (
            output,
            http_response,
        ) = await capo_appstream._operations.photon_admin_proxy_service.describe_images.async_describe_images(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DescribeImages")
    )
    input_: capo_appstream.types.describe_images_request.DescribeImagesRequest = {}
    if names is not None:
        input_["names"] = names
    if arns is not None:
        input_["arns"] = arns
    if type is not None:
        input_["type"] = type
    if next_token is not None:
        input_["next_token"] = next_token
    if max_results is not None:
        input_["max_results"] = max_results

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output