Skip to content

describe_remediation_exceptions

describe_remediation_exceptions(
    config_rule_name: ConfigRuleName,
    *,
    config_overrides: Optional[ConfigServiceClientConfig] = None,
    resource_keys: Optional[RemediationExceptionResourceKeys] = None,
    limit: Optional[Limit] = None,
    next_token: Optional[String] = None,
) -> DescribeRemediationExceptionsResponse

Returns the details of one or more remediation exceptions. A detailed view of a remediation exception for a set of resources that includes an explanation of an exception and the time when the exception will be deleted. When you specify the limit and the next token, you receive a paginated response.

Config generates a remediation exception when a problem occurs executing a remediation action to a specific resource. Remediation exceptions blocks auto-remediation until the exception is cleared.

When you specify the limit and the next token, you receive a paginated response.

Limit and next token are not applicable if you request resources in batch. It is only applicable, when you request all resources.

Parameters:

  • config_rule_name (ConfigRuleName) –

    The name of the Config rule.

  • resource_keys (Optional[RemediationExceptionResourceKeys], default: None ) –

    An exception list of resource exception keys to be processed with the current request. Config adds exception for each resource key. For example, Config adds 3 exceptions for 3 resource keys.

  • limit (Optional[Limit], default: None ) –

    The maximum number of RemediationExceptionResourceKey returned on each page. The default is 25. If you specify 0, Config uses the default.

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

    The nextToken string returned in a previous request that you use to request the next page of results in a paginated response.

Raises:

  • InvalidNextTokenException –

    The specified next token is not valid. Specify the nextToken string that was returned in the previous response to get the next page of results.

  • InvalidParameterValueException –

    One or more of the specified parameters are not valid. Verify that your parameters are valid and try again.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_config_service/_services/config_service.py
def describe_remediation_exceptions(
    self,
    config_rule_name: "capo_config_service.types.config_rule_name.ConfigRuleName",
    *,
    config_overrides: Optional[ConfigServiceClientConfig] = None,
    resource_keys: Optional[
        "capo_config_service.types.remediation_exception_resource_keys.RemediationExceptionResourceKeys"
    ] = None,
    limit: Optional["capo_config_service.types.limit.Limit"] = None,
    next_token: Optional["capo_config_service.types.string.String"] = None,
) -> "capo_config_service.types.describe_remediation_exceptions_response.DescribeRemediationExceptionsResponse":
    """<p>Returns the details of one or more remediation exceptions. A detailed view of a remediation exception for a set of resources that includes an explanation of an exception and the time when the exception will be deleted. When you specify the limit and the next token, you receive a paginated response. </p> <note> <p>Config generates a remediation exception when a problem occurs executing a remediation action to a specific resource. Remediation exceptions blocks auto-remediation until the exception is cleared.</p> <p>When you specify the limit and the next token, you receive a paginated response. </p> <p>Limit and next token are not applicable if you request resources in batch. It is only applicable, when you request all resources.</p> </note>

    Args:
        config_rule_name: <p>The name of the Config rule.</p>
        resource_keys: <p>An exception list of resource exception keys to be processed with the current request. Config adds exception for each resource key. For example, Config adds 3 exceptions for 3 resource keys. </p>
        limit: <p>The maximum number of RemediationExceptionResourceKey returned on each page. The default is 25. If you specify 0, Config uses the default.</p>
        next_token: <p>The <code>nextToken</code> string returned in a previous request that you use to request the next page of results in a paginated response.</p>

    Raises:
        capo_config_service.errors.invalid_next_token_exception.InvalidNextTokenException: <p>The specified next token is not valid. Specify the <code>nextToken</code> string that was returned in the previous response to get the next page of results.</p>
        capo_config_service.errors.invalid_parameter_value_exception.InvalidParameterValueException: <p>One or more of the specified parameters are not valid. Verify that your parameters are valid and try again.</p>
        capo_config_service.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_config_service.types.describe_remediation_exceptions_request.DescribeRemediationExceptionsRequest]",
    ) -> OperationResponse[
        "capo_config_service.types.describe_remediation_exceptions_response.DescribeRemediationExceptionsResponse"
    ]:
        import capo_config_service._operations.starling_dove_service.describe_remediation_exceptions

        output, http_response = (
            capo_config_service._operations.starling_dove_service.describe_remediation_exceptions.describe_remediation_exceptions(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DescribeRemediationExceptions")
    )
    input_: capo_config_service.types.describe_remediation_exceptions_request.DescribeRemediationExceptionsRequest = {
        "config_rule_name": config_rule_name
    }
    if resource_keys is not None:
        input_["resource_keys"] = resource_keys
    if limit is not None:
        input_["limit"] = limit
    if next_token is not None:
        input_["next_token"] = next_token

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output