CloudWatch / Client / enable_insight_rules

enable_insight_rules#

CloudWatch.Client.enable_insight_rules(**kwargs)#

Enables the specified Contributor Insights rules. When rules are enabled, they immediately begin analyzing log data.

See also: AWS API Documentation

Request Syntax

response = client.enable_insight_rules(
    RuleNames=[
        'string',
    ]
)
Parameters:

RuleNames (list) –

[REQUIRED]

An array of the rule names to enable. If you need to find out the names of your rules, use DescribeInsightRules.

  • (string) –

Return type:

dict

Returns:

Response Syntax

{
    'Failures': [
        {
            'FailureResource': 'string',
            'ExceptionType': 'string',
            'FailureCode': 'string',
            'FailureDescription': 'string'
        },
    ]
}

Response Structure

  • (dict) –

    • Failures (list) –

      An array listing the rules that could not be enabled. You cannot disable or enable built-in rules.

      • (dict) –

        This array is empty if the API operation was successful for all the rules specified in the request. If the operation could not process one of the rules, the following data is returned for each of those rules.

        • FailureResource (string) –

          The specified rule that could not be deleted.

        • ExceptionType (string) –

          The type of error.

        • FailureCode (string) –

          The code of the error.

        • FailureDescription (string) –

          A description of the error.

Exceptions

  • CloudWatch.Client.exceptions.InvalidParameterValueException

  • CloudWatch.Client.exceptions.MissingRequiredParameterException

  • CloudWatch.Client.exceptions.LimitExceededException