Skip to content

list_auto_scaling_configurations async

list_auto_scaling_configurations(
    *,
    config_overrides: Optional[AsyncAppRunnerClientConfig] = None,
    auto_scaling_configuration_name: Optional[AutoScalingConfigurationName] = None,
    latest_only: Optional[Boolean] = None,
    max_results: Optional[MaxResults] = None,
    next_token: Optional[NextToken] = None,
) -> ListAutoScalingConfigurationsResponse

Returns a list of active App Runner automatic scaling configurations in your Amazon Web Services account. You can query the revisions for a specific configuration name or the revisions for all active configurations in your account. You can optionally query only the latest revision of each requested name.

To retrieve a full description of a particular configuration revision, call and provide one of the ARNs returned by ListAutoScalingConfigurations.

Parameters:

  • auto_scaling_configuration_name (Optional[AutoScalingConfigurationName], default: None ) –

    The name of the App Runner auto scaling configuration that you want to list. If specified, App Runner lists revisions that share this name. If not specified, App Runner returns revisions of all active configurations.

  • latest_only (Optional[Boolean], default: None ) –

    Set to true to list only the latest revision for each requested configuration name.

    Set to false to list all revisions for each requested configuration name.

    Default: true

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

    The maximum number of results to include in each response (result page). It's used for a paginated request.

    If you don't specify MaxResults, the request retrieves all available results in a single response.

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

    A token from a previous result page. It's used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones that are specified in the initial request.

    If you don't specify NextToken, the request retrieves the first result page.

Raises:

Source code in docs_src/capo_apprunner/_services/async_app_runner.py
async def list_auto_scaling_configurations(
    self,
    *,
    config_overrides: Optional[AsyncAppRunnerClientConfig] = None,
    auto_scaling_configuration_name: Optional[
        "capo_apprunner.types.auto_scaling_configuration_name.AutoScalingConfigurationName"
    ] = None,
    latest_only: Optional["capo_apprunner.types.boolean.Boolean"] = None,
    max_results: Optional["capo_apprunner.types.max_results.MaxResults"] = None,
    next_token: Optional["capo_apprunner.types.next_token.NextToken"] = None,
) -> "capo_apprunner.types.list_auto_scaling_configurations_response.ListAutoScalingConfigurationsResponse":
    """<p>Returns a list of active App Runner automatic scaling configurations in your Amazon Web Services account. You can query the revisions for a specific configuration name or the revisions for all active configurations in your account. You can optionally query only the latest revision of each requested name.</p> <p>To retrieve a full description of a particular configuration revision, call and provide one of the ARNs returned by <code>ListAutoScalingConfigurations</code>.</p>

    Args:
        auto_scaling_configuration_name: <p>The name of the App Runner auto scaling configuration that you want to list. If specified, App Runner lists revisions that share this name. If not specified, App Runner returns revisions of all active configurations.</p>
        latest_only: <p>Set to <code>true</code> to list only the latest revision for each requested configuration name.</p> <p>Set to <code>false</code> to list all revisions for each requested configuration name.</p> <p>Default: <code>true</code> </p>
        max_results: <p>The maximum number of results to include in each response (result page). It's used for a paginated request.</p> <p>If you don't specify <code>MaxResults</code>, the request retrieves all available results in a single response.</p>
        next_token: <p>A token from a previous result page. It's used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones that are specified in the initial request.</p> <p>If you don't specify <code>NextToken</code>, the request retrieves the first result page.</p>

    Raises:
        capo_apprunner.errors.internal_service_error_exception.InternalServiceErrorException: <p>An unexpected service exception occurred.</p>
        capo_apprunner.errors.invalid_request_exception.InvalidRequestException: <p>One or more input parameters aren't valid. Refer to the API action's document page, correct the input parameters, and try the action again.</p>
        capo_apprunner.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_apprunner.types.list_auto_scaling_configurations_request.ListAutoScalingConfigurationsRequest]",
    ) -> AsyncOperationResponse[
        "capo_apprunner.types.list_auto_scaling_configurations_response.ListAutoScalingConfigurationsResponse"
    ]:
        import capo_apprunner._operations.app_runner.list_auto_scaling_configurations

        (
            output,
            http_response,
        ) = await capo_apprunner._operations.app_runner.list_auto_scaling_configurations.async_list_auto_scaling_configurations(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListAutoScalingConfigurations")
    )
    input_: capo_apprunner.types.list_auto_scaling_configurations_request.ListAutoScalingConfigurationsRequest = {}
    if auto_scaling_configuration_name is not None:
        input_["auto_scaling_configuration_name"] = auto_scaling_configuration_name
    if latest_only is not None:
        input_["latest_only"] = latest_only
    if max_results is not None:
        input_["max_results"] = max_results
    if next_token is not None:
        input_["next_token"] = next_token

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