CfnAnomalySubscriptionPropsMixin

class aws_cdk.mixins_preview.aws_ce.mixins.CfnAnomalySubscriptionPropsMixin(props, *, strategy=None)

Bases: Mixin

The AWS::CE::AnomalySubscription resource (also referred to as an alert subscription) is a Cost Explorer resource type that sends notifications about specific anomalies that meet an alerting criteria defined by you.

You can specify the frequency of the alerts and the subscribers to notify.

Anomaly subscriptions can be associated with one or more `AWS::CE::AnomalyMonitor <https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ce-anomalymonitor.html>`_ resources, and they only send notifications about anomalies detected by those associated monitors. You can also configure a threshold to further control which anomalies are included in the notifications.

Anomalies that don’t exceed the chosen threshold and therefore don’t trigger notifications from an anomaly subscription will still be available on the console and from the `GetAnomalies <https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_GetAnomalies.html>`_ API.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ce-anomalysubscription.html

CloudformationResource:

AWS::CE::AnomalySubscription

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_ce import mixins as ce_mixins

cfn_anomaly_subscription_props_mixin = ce_mixins.CfnAnomalySubscriptionPropsMixin(ce_mixins.CfnAnomalySubscriptionMixinProps(
    frequency="frequency",
    monitor_arn_list=["monitorArnList"],
    resource_tags=[ce_mixins.CfnAnomalySubscriptionPropsMixin.ResourceTagProperty(
        key="key",
        value="value"
    )],
    subscribers=[ce_mixins.CfnAnomalySubscriptionPropsMixin.SubscriberProperty(
        address="address",
        status="status",
        type="type"
    )],
    subscription_name="subscriptionName",
    threshold=123,
    threshold_expression="thresholdExpression"
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::CE::AnomalySubscription.

Parameters:

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['frequency', 'monitorArnList', 'resourceTags', 'subscribers', 'subscriptionName', 'threshold', 'thresholdExpression']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

ResourceTagProperty

class CfnAnomalySubscriptionPropsMixin.ResourceTagProperty(*, key=None, value=None)

Bases: object

The tag structure that contains a tag key and value.

Parameters:
  • key (Optional[str]) – The key that’s associated with the tag.

  • value (Optional[str]) – The value that’s associated with the tag.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-resourcetag.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_ce import mixins as ce_mixins

resource_tag_property = ce_mixins.CfnAnomalySubscriptionPropsMixin.ResourceTagProperty(
    key="key",
    value="value"
)

Attributes

key

The key that’s associated with the tag.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-resourcetag.html#cfn-ce-anomalysubscription-resourcetag-key

value

The value that’s associated with the tag.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-resourcetag.html#cfn-ce-anomalysubscription-resourcetag-value

SubscriberProperty

class CfnAnomalySubscriptionPropsMixin.SubscriberProperty(*, address=None, status=None, type=None)

Bases: object

The recipient of AnomalySubscription notifications.

Parameters:
  • address (Optional[str]) – The email address or SNS Topic Amazon Resource Name (ARN), depending on the Type .

  • status (Optional[str]) – Indicates if the subscriber accepts the notifications.

  • type (Optional[str]) – The notification delivery channel.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-subscriber.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_ce import mixins as ce_mixins

subscriber_property = ce_mixins.CfnAnomalySubscriptionPropsMixin.SubscriberProperty(
    address="address",
    status="status",
    type="type"
)

Attributes

address

The email address or SNS Topic Amazon Resource Name (ARN), depending on the Type .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-subscriber.html#cfn-ce-anomalysubscription-subscriber-address

status

Indicates if the subscriber accepts the notifications.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-subscriber.html#cfn-ce-anomalysubscription-subscriber-status

type

The notification delivery channel.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ce-anomalysubscription-subscriber.html#cfn-ce-anomalysubscription-subscriber-type