# CfnTelemetryRuleProps

Properties for defining a `CfnTelemetryRule`.

Extends: CfnTelemetryRuleProps
Used as props by: CfnTelemetryRule

- Source: Generated code
- Type last changed: v2.211.0 · 13 Aug 2025

## Example

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_observabilityadmin as observabilityadmin } from 'aws-cdk-lib';
const cfnTelemetryRuleProps: observabilityadmin.CfnTelemetryRuleProps = {
  rule: {
    resourceType: 'resourceType',
    telemetryType: 'telemetryType',

    // the properties below are optional
    allowFieldUpdates: false,
    allRegions: false,
    destinationConfiguration: {
      cloudtrailParameters: {
        advancedEventSelectors: [{
          fieldSelectors: [{
            endsWith: ['endsWith'],
            equalTo: ['equalTo'],
            field: 'field',
            notEndsWith: ['notEndsWith'],
            notEquals: ['notEquals'],
            notStartsWith: ['notStartsWith'],
            startsWith: ['startsWith'],
          }],

          // the properties below are optional
          name: 'name',
        }],
      },
      destinationPattern: 'destinationPattern',
      destinationType: 'destinationType',
      elbLoadBalancerLoggingParameters: {
        fieldDelimiter: 'fieldDelimiter',
        outputFormat: 'outputFormat',
      },
      kmsKeyArn: 'kmsKeyArn',
      logDeliveryParameters: {
        logTypes: ['logTypes'],
      },
      mskMonitoringParameters: {
        enhancedMonitoring: 'enhancedMonitoring',
      },
      retentionInDays: 123,
      vpcFlowLogParameters: {
        logFormat: 'logFormat',
        maxAggregationInterval: 123,
        trafficType: 'trafficType',
      },
      wafLoggingParameters: {
        loggingFilter: {
          defaultBehavior: 'defaultBehavior',
          filters: [{
            behavior: 'behavior',
            conditions: [{
              actionCondition: {
                action: 'action',
              },
              labelNameCondition: {
                labelName: 'labelName',
              },
            }],
            requirement: 'requirement',
          }],
        },
        logType: 'logType',
        redactedFields: [{
          method: 'method',
          queryString: 'queryString',
          singleHeader: {
            name: 'name',
          },
          uriPath: 'uriPath',
        }],
      },
    },
    regions: ['regions'],
    selectionCriteria: 'selectionCriteria',
    telemetrySourceTypes: ['telemetrySourceTypes'],
  },
  ruleName: 'ruleName',

  // the properties below are optional
  tags: [{
    key: 'key',
    value: 'value',
  }],
};
```

## Properties

- `rule`: [IResolvable](/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnTelemetryRule.TelemetryRuleProperty](/cdk/api/v2/docs/aws-cdk-lib.aws_observabilityadmin.CfnTelemetryRule.TelemetryRuleProperty.html) (required) — Retrieves the details of a specific telemetry rule in your account.

- `ruleName`: string (required) — The name of the telemetry rule.

- `tags`: [CfnTag](/cdk/api/v2/docs/aws-cdk-lib.CfnTag.html)[] — Lists all tags attached to the specified resource.

  Supports telemetry rule resources and telemetry pipeline resources.
