Skip to main content

billing_views

Creates, updates, deletes or gets a billing_view resource or lists billing_views in a region

Overview

Namebilling_views
TypeResource
DescriptionA billing view is a container of cost & usage metadata.
Idawscc.billing.billing_views

Fields

NameDatatypeDescription
arnstring
billing_view_typestring
data_filter_expressionobject
created_atnumberThe time when the billing view was created.
descriptionstring
namestring
owner_account_idstring
tagsarrayAn array of key-value pairs associated to the billing view being created.
source_viewsarrayAn array of strings that define the billing view's source.
updated_atnumberThe time when the billing view was last updated.
regionstringAWS region.

For more information, see AWS::Billing::BillingView.

Methods

NameAccessible byRequired Params
create_resourceINSERTName, SourceViews, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all properties from an individual billing_view.

SELECT
region,
arn,
billing_view_type,
data_filter_expression,
created_at,
description,
name,
owner_account_id,
tags,
source_views,
updated_at
FROM awscc.billing.billing_views
WHERE region = 'us-east-1' AND data__Identifier = '<Arn>';

INSERT example

Use the following StackQL query and manifest file to create a new billing_view resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.billing.billing_views (
Name,
SourceViews,
region
)
SELECT
'{{ Name }}',
'{{ SourceViews }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM awscc.billing.billing_views
WHERE data__Identifier = '<Arn>'
AND region = 'us-east-1';

Permissions

To operate on the billing_views resource, the following permissions are required:

Create

billing:CreateBillingView,
billing:TagResource,
billing:ListTagsForResource,
billing:GetBillingView,
billing:ListSourceViewsForBillingView

Read

billing:GetBillingView,
billing:ListTagsForResource,
billing:ListSourceViewsForBillingView

Update

billing:UpdateBillingView,
billing:GetBillingView,
billing:ListTagsForResource,
billing:TagResource,
billing:UntagResource,
billing:ListSourceViewsForBillingView

Delete

billing:GetBillingView,
billing:DeleteBillingView

List

billing:ListBillingViews