AWS::BillingConductor::CustomLineItem
Creates a custom line item that can be used to create a one-time or recurring, fixed or percentage-based charge that you can apply to a single billing group. You can apply custom line items to the current or previous billing period. You can create either a fee or a discount custom line item.
Syntax
To declare this entity in your Amazon CloudFormation template, use the following syntax:
JSON
{ "Type" : "AWS::BillingConductor::CustomLineItem", "Properties" : { "BillingGroupArn" :String, "BillingPeriodRange" :BillingPeriodRange, "CustomLineItemChargeDetails" :CustomLineItemChargeDetails, "Description" :String, "Name" :String, "Tags" :[ Tag, ... ]} }
YAML
Type: AWS::BillingConductor::CustomLineItem Properties: BillingGroupArn:StringBillingPeriodRange:BillingPeriodRangeCustomLineItemChargeDetails:CustomLineItemChargeDetailsDescription:StringName:StringTags:- Tag
Properties
BillingGroupArn-
The Amazon Resource Name (ARN) that references the billing group where the custom line item applies to.
Required: Yes
Type: String
Update requires: Replacement
BillingPeriodRangeA time range for which the custom line item is effective.
Required: No
Type: BillingPeriodRange
Update requires: No interruption
CustomLineItemChargeDetailsThe charge details of a custom line item. It should contain only one of
FlatorPercentage.Required: No
Type: CustomLineItemChargeDetails
Update requires: No interruption
Description-
The custom line item's description. This is shown on the Bills page in association with the charge value.
Required: No
Type: String
Update requires: No interruption
Name-
The custom line item's name.
Required: Yes
Type: String
Update requires: No interruption
TagsA map that contains tag keys and tag values that are attached to a custom line item.
Required: No
Type: List of Tag
Update requires: No interruption
Return values
Ref
For more information about using the Reffunction, see Ref.
Fn::GetAtt
ArnThe Amazon Resource Name (ARN) that references the billing group where the custom line item applies to.
AssociationSize-
The number of resources that are associated to the custom line item.
CreationTimeThe time created.
CurrencyCode-
The custom line item's charge value currency. Only one of the valid values can be used.
LastModifiedTimeThe most recent time the custom line item was modified.
ProductCodeThe product code associated with the custom line item.
Examples
Flat custom line item
The following example shows a flat charge custom line item of $10 attached to a billing group.
JSON
{ "Resources": { "TestFlatCustomLineItem": { "Type": "AWS::BillingConductor::CustomLineItem", "Properties": { "Name": "TestFlatCustomLineItem", "Description": "Test flat custom line item created through CloudFormation for a $10 charge.", "BillingGroupArn": { "Fn::GetAtt": ["TestBillingGroup", "Arn"] }, "CustomLineItemChargeDetails": { "Flat": { "ChargeValue": 10 }, "Type": "FEE" }, "BillingPeriodRange": { "InclusiveStartBillingPeriod": "2022-11" } } } } }
YAML
Resources: TestFlatCustomLineItem: Type: 'AWS::BillingConductor::CustomLineItem' Properties: Name: 'TestFlatCustomLineItem' Description: 'Test flat custom line item created through CloudFormation for a $10 charge.' BillingGroupArn: !GetAtt TestBillingGroup.Arn CustomLineItemChargeDetails: Flat: ChargeValue: 10 Type: 'FEE' BillingPeriodRange: InclusiveStartBillingPeriod: 2022-11
Percentage custom line item
The following example shows a percentage charge custom line item that is 10% of the billing group total cost.
JSON
{ "Resources": { "TestPercentageCustomLineItem": { "Type": "AWS::BillingConductor::CustomLineItem", "Properties": { "Name": "TestPercentageCustomLineItem", "Description": "Test percentage custom line item created through CloudFormation for a %10 additional charge on the overall total bill of the billing group.", "BillingGroupArn": { "Fn::GetAtt": ["TestBillingGroup", "Arn"] }, "CustomLineItemChargeDetails": { "Percentage": { "PercentageValue": 10, "ChildAssociatedResources": [ {"Fn::GetAtt": ["TestBillingGroup", "Arn"]} ] }, "Type": "FEE" } } } } }
YAML
Resources: TestPercentageCustomLineItem: Type: 'AWS::BillingConductor::CustomLineItem' Properties: Name: 'TestPercentageCustomLineItem' Description: 'Test percentage custom line item created through CloudFormation for a %10 additional charge on the overall total bill of the billing group.' BillingGroupArn: !GetAtt TestBillingGroup.Arn CustomLineItemChargeDetails: Percentage: PercentageValue: 10 ChildAssociatedResources: - !GetAtt TestBillingGroup.Arn Type: 'FEE'