Skip to content

Commit 74dd323

Browse files
author
AWS
committed
AWS Cost Explorer Service Update: You can now create cost categories with inherited value rules and specify default values for any uncategorized costs.
1 parent c8bfdee commit 74dd323

File tree

2 files changed

+53
-11
lines changed

2 files changed

+53
-11
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"type": "feature",
3+
"category": "AWS Cost Explorer Service",
4+
"contributor": "",
5+
"description": "You can now create cost categories with inherited value rules and specify default values for any uncategorized costs."
6+
}

services/costexplorer/src/main/resources/codegen-resources/service-2.json

Lines changed: 47 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -720,10 +720,32 @@
720720
"ProcessingStatus":{
721721
"shape":"CostCategoryProcessingStatusList",
722722
"documentation":"<p> The list of processing statuses for Cost Management products for a specific cost category. </p>"
723-
}
723+
},
724+
"DefaultValue":{"shape":"CostCategoryValue"}
724725
},
725726
"documentation":"<p>The structure of Cost Categories. This includes detailed metadata and the set of rules for the <code>CostCategory</code> object.</p>"
726727
},
728+
"CostCategoryInheritedValueDimension":{
729+
"type":"structure",
730+
"members":{
731+
"DimensionName":{
732+
"shape":"CostCategoryInheritedValueDimensionName",
733+
"documentation":"<p>The name of dimension for which to group costs.</p> <p>If you specify <code>LINKED_ACCOUNT_NAME</code>, the cost category value will be based on account name. If you specify <code>TAG</code>, the cost category value will be based on the value of the specified tag key.</p>"
734+
},
735+
"DimensionKey":{
736+
"shape":"GenericString",
737+
"documentation":"<p>The key to extract cost category values.</p>"
738+
}
739+
},
740+
"documentation":"<p>When creating or updating a cost category, you can define the <code>CostCategoryRule</code> rule type as <code>INHERITED_VALUE</code>. This rule type adds the flexibility of defining a rule that dynamically inherits the cost category value from the dimension value defined by <code>CostCategoryInheritedValueDimension</code>. For example, if you wanted to dynamically group costs based on the value of a specific tag key, you would first choose an inherited value rule type, then choose the tag dimension and specify the tag key to use.</p>"
741+
},
742+
"CostCategoryInheritedValueDimensionName":{
743+
"type":"string",
744+
"enum":[
745+
"LINKED_ACCOUNT_NAME",
746+
"TAG"
747+
]
748+
},
727749
"CostCategoryMaxResults":{
728750
"type":"integer",
729751
"max":100,
@@ -732,7 +754,7 @@
732754
"CostCategoryName":{
733755
"type":"string",
734756
"documentation":"<p>The unique name of the Cost Category.</p>",
735-
"max":255,
757+
"max":50,
736758
"min":1,
737759
"pattern":"^(?! )[\\p{L}\\p{N}\\p{Z}-_]*(?<! )$"
738760
},
@@ -785,7 +807,8 @@
785807
"Values":{
786808
"shape":"CostCategoryValuesList",
787809
"documentation":"<p> A list of unique cost category values in a specific cost category. </p>"
788-
}
810+
},
811+
"DefaultValue":{"shape":"CostCategoryValue"}
789812
},
790813
"documentation":"<p>A reference to a Cost Category containing only enough information to identify the Cost Category.</p> <p>You can use this information to retrieve the full Cost Category information using <code>DescribeCostCategory</code>.</p>"
791814
},
@@ -795,19 +818,30 @@
795818
},
796819
"CostCategoryRule":{
797820
"type":"structure",
798-
"required":[
799-
"Value",
800-
"Rule"
801-
],
802821
"members":{
803822
"Value":{"shape":"CostCategoryValue"},
804823
"Rule":{
805824
"shape":"Expression",
806825
"documentation":"<p>An <a href=\"https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_Expression.html\">Expression</a> object used to categorize costs. This supports dimensions, tags, and nested expressions. Currently the only dimensions supported are <code>LINKED_ACCOUNT</code>, <code>SERVICE_CODE</code>, <code>RECORD_TYPE</code>, and <code>LINKED_ACCOUNT_NAME</code>.</p> <p>Root level <code>OR</code> is not supported. We recommend that you create a separate rule instead.</p> <p> <code>RECORD_TYPE</code> is a dimension used for Cost Explorer APIs, and is also supported for Cost Category expressions. This dimension uses different terms, depending on whether you're using the console or API/JSON editor. For a detailed comparison, see <a href=\"https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/manage-cost-categories.html#cost-categories-terms\">Term Comparisons</a> in the <i>AWS Billing and Cost Management User Guide</i>.</p>"
826+
},
827+
"InheritedValue":{
828+
"shape":"CostCategoryInheritedValueDimension",
829+
"documentation":"<p>The value the line item will be categorized as, if the line item contains the matched dimension.</p>"
830+
},
831+
"Type":{
832+
"shape":"CostCategoryRuleType",
833+
"documentation":"<p>You can define the <code>CostCategoryRule</code> rule type as either <code>REGULAR</code> or <code>INHERITED_VALUE</code>. The <code>INHERITED_VALUE</code> rule type adds the flexibility of defining a rule that dynamically inherits the cost category value from the dimension value defined by <code>CostCategoryInheritedValueDimension</code>. For example, if you wanted to dynamically group costs based on the value of a specific tag key, you would first choose an inherited value rule type, then choose the tag dimension and specify the tag key to use.</p>"
807834
}
808835
},
809836
"documentation":"<p>Rules are processed in order. If there are multiple rules that match the line item, then the first rule to match is used to determine that Cost Category value.</p>"
810837
},
838+
"CostCategoryRuleType":{
839+
"type":"string",
840+
"enum":[
841+
"REGULAR",
842+
"INHERITED_VALUE"
843+
]
844+
},
811845
"CostCategoryRuleVersion":{
812846
"type":"string",
813847
"documentation":"<p>The rule schema version in this particular Cost Category.</p>",
@@ -832,8 +866,8 @@
832866
},
833867
"CostCategoryValue":{
834868
"type":"string",
835-
"documentation":"<p>The value a line item will be categorized as, if it matches the rule.</p>",
836-
"max":255,
869+
"documentation":"<p>The default value for the cost category.</p>",
870+
"max":50,
837871
"min":1,
838872
"pattern":"^(?! )[\\p{L}\\p{N}\\p{Z}-_]*(?<! )$"
839873
},
@@ -1005,7 +1039,8 @@
10051039
"Rules":{
10061040
"shape":"CostCategoryRulesList",
10071041
"documentation":"<p>The Cost Category rules used to categorize costs. For more information, see <a href=\"https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_CostCategoryRule.html\">CostCategoryRule</a>.</p>"
1008-
}
1042+
},
1043+
"DefaultValue":{"shape":"CostCategoryValue"}
10091044
}
10101045
},
10111046
"CreateCostCategoryDefinitionResponse":{
@@ -3981,7 +4016,8 @@
39814016
"Rules":{
39824017
"shape":"CostCategoryRulesList",
39834018
"documentation":"<p>The <code>Expression</code> object used to categorize costs. For more information, see <a href=\"https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_CostCategoryRule.html\">CostCategoryRule </a>. </p>"
3984-
}
4019+
},
4020+
"DefaultValue":{"shape":"CostCategoryValue"}
39854021
}
39864022
},
39874023
"UpdateCostCategoryDefinitionResponse":{

0 commit comments

Comments
 (0)