How to reliably calculate ARN from Cost and Usage Report columns

1

We are working on building an automated parser which can read AWS Cost and Usage reports and link cost entries to respective resources. We are trying to go past two challenge -

  1. CUR doesn't provide a column for resource ARN directly
  2. If we want to calculate it ourselves, one missing info is the resource type against each service Does anyone know why these information are not included in CUR and if there is a reliable way to construct ARN from already available columns? Any info would be appreciated. Thanks.
質問済み 1年前575ビュー
1回答
0

Hello Atanu Roy,

Thank you for reaching out to us. Let me help you with your queries :

  1. CUR doesn't provide a column for resource ARN directly.

A : The Cost and Usage report does have a direct coloumn that will get you the resource ARN directly. Its called line_item_resource_id. While you created CUR first, you should click on the check box that states : include resource ids for it to show up in your CUR.

You can create a new CUR report with this feature enabled so that you can see the Resource ARN's directly. Please use document : Creating Cost and Usage Reports

profile pictureAWS
回答済み 1年前
profile picture
エキスパート
レビュー済み 1ヶ月前
  • Hi Nithin,

    Thank you for responding. We have already enabled that option. However, in the format we get (we are using text/csv) there are no line_item_resource_id column. Instead we get a column named lineItem/ResourceId which only contains the resource id part (not the full ARN separated by : characters). Can you please help me out if we are missing something in the configuration?

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン