What are the AWS Billing and Cost Management - GetCostAndUsage GroupBy limits

0

If I was to have an application that launches EC2 instances to run jobs and I was to tag each instance with a user id, I can see that using GetCostAndUsage i can GroupBy that Tag and get user level usage/costs. I can only assume that there will be a limit at which the API will not return successfully e.g. if we have 10000 users? Is there any indication what that limit would be, or would there be any way to aggregate low usage "users" into an "other" level of the returned data i.e. top 10 most prolific users and then everyone else?

Thanks

asked 3 months ago2043 views
1 Answer
0

Hello,

Thank you for your post,

You can Retrieves cost and usage metrics for your account. You can specify which cost and usage-related metric that you want the request to return. For example, you can specify BlendedCosts or UsageQuantity. You can also filter and group your data by various dimensions, such as SERVICE or AZ, in a specific time range. For more information, please refer: https://docs.aws.amazon.com/aws-cost-management/latest/APIReference/API_GetCostAndUsage.html

GroupBy:

You can group AWS costs using up to two different groups, either dimensions, tag keys, cost categories, or any two group by types.

Valid values for the DIMENSION type are AZ, INSTANCE_TYPE, LEGAL_ENTITY_NAME, INVOICING_ENTITY, LINKED_ACCOUNT, OPERATION, PLATFORM, PURCHASE_TYPE, SERVICE, TENANCY, RECORD_TYPE, and USAGE_TYPE.

When you group by the TAG type and include a valid tag key, you get all tag values, including empty strings.

As per the specified dimensions, you may customize your use case.

For information about filter limitations, see Quotas and restrictions in the Billing and Cost Management User Guide [1].

GetCostAndUsage comes under non-mutatiting. and it's limit is specified in article [2]:

References:

[1] https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/billing-limits.html

[2] https://docs.aws.amazon.com/AWSEC2/latest/APIReference/throttling.html#throttling-limits

AWS
SUPPORT ENGINEER
answered 3 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions