Update Anomaly Subscription
| costexplorer_update_anomaly_subscription | R Documentation |
Updates an existing cost anomaly subscription¶
Description¶
Updates an existing cost anomaly subscription. Specify the fields that you want to update. Omitted fields are unchanged.
The JSON below describes the generic construct for each type. See
Request
Parameters
for possible values as they apply to AnomalySubscription.
Usage¶
costexplorer_update_anomaly_subscription(SubscriptionArn, Threshold,
Frequency, MonitorArnList, Subscribers, SubscriptionName,
ThresholdExpression)
Arguments¶
SubscriptionArn[required] A cost anomaly subscription Amazon Resource Name (ARN).
Threshold(deprecated)
The update to the threshold value for receiving notifications.
This field has been deprecated. To update a threshold, use ThresholdExpression. Continued use of Threshold will be treated as shorthand syntax for a ThresholdExpression.
You can specify either Threshold or ThresholdExpression, but not both.
FrequencyThe update to the frequency value that subscribers receive notifications.
MonitorArnListA list of cost anomaly monitor ARNs.
SubscribersThe update to the subscriber list.
SubscriptionNameThe new name of the subscription.
ThresholdExpressionThe update to the Expression object used to specify the anomalies that you want to generate alerts for. This supports dimensions and nested expressions. The supported dimensions are
ANOMALY_TOTAL_IMPACT_ABSOLUTEandANOMALY_TOTAL_IMPACT_PERCENTAGE, corresponding to an anomaly’s TotalImpact and TotalImpactPercentage, respectively (see Impact for more details). The supported nested expression types areANDandOR. The match optionGREATER_THAN_OR_EQUALis required. Values must be numbers between 0 and 10,000,000,000 in string format.You can specify either Threshold or ThresholdExpression, but not both.
The following are examples of valid ThresholdExpressions:
Absolute threshold:
{ "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }Percentage threshold:
{ "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }ANDtwo thresholds together:{ "And": [ { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }, { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } } ] }ORtwo thresholds together:{ "Or": [ { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }, { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } } ] }
Value¶
A list with the following syntax:
Request syntax¶
svc$update_anomaly_subscription(
SubscriptionArn = "string",
Threshold = 123.0,
Frequency = "DAILY"|"IMMEDIATE"|"WEEKLY",
MonitorArnList = list(
"string"
),
Subscribers = list(
list(
Address = "string",
Type = "EMAIL"|"SNS",
Status = "CONFIRMED"|"DECLINED"
)
),
SubscriptionName = "string",
ThresholdExpression = list(
Or = list(
list()
),
And = list(
list()
),
Not = list(),
Dimensions = list(
Key = "AZ"|"INSTANCE_TYPE"|"LINKED_ACCOUNT"|"LINKED_ACCOUNT_NAME"|"OPERATION"|"PURCHASE_TYPE"|"REGION"|"SERVICE"|"SERVICE_CODE"|"USAGE_TYPE"|"USAGE_TYPE_GROUP"|"RECORD_TYPE"|"OPERATING_SYSTEM"|"TENANCY"|"SCOPE"|"PLATFORM"|"SUBSCRIPTION_ID"|"LEGAL_ENTITY_NAME"|"DEPLOYMENT_OPTION"|"DATABASE_ENGINE"|"CACHE_ENGINE"|"INSTANCE_TYPE_FAMILY"|"BILLING_ENTITY"|"RESERVATION_ID"|"RESOURCE_ID"|"RIGHTSIZING_TYPE"|"SAVINGS_PLANS_TYPE"|"SAVINGS_PLAN_ARN"|"PAYMENT_OPTION"|"AGREEMENT_END_DATE_TIME_AFTER"|"AGREEMENT_END_DATE_TIME_BEFORE"|"INVOICING_ENTITY"|"ANOMALY_TOTAL_IMPACT_ABSOLUTE"|"ANOMALY_TOTAL_IMPACT_PERCENTAGE",
Values = list(
"string"
),
MatchOptions = list(
"EQUALS"|"ABSENT"|"STARTS_WITH"|"ENDS_WITH"|"CONTAINS"|"CASE_SENSITIVE"|"CASE_INSENSITIVE"|"GREATER_THAN_OR_EQUAL"
)
),
Tags = list(
Key = "string",
Values = list(
"string"
),
MatchOptions = list(
"EQUALS"|"ABSENT"|"STARTS_WITH"|"ENDS_WITH"|"CONTAINS"|"CASE_SENSITIVE"|"CASE_INSENSITIVE"|"GREATER_THAN_OR_EQUAL"
)
),
CostCategories = list(
Key = "string",
Values = list(
"string"
),
MatchOptions = list(
"EQUALS"|"ABSENT"|"STARTS_WITH"|"ENDS_WITH"|"CONTAINS"|"CASE_SENSITIVE"|"CASE_INSENSITIVE"|"GREATER_THAN_OR_EQUAL"
)
)
)
)