Convert Cost Management data to FOCUS Convert existing Cost Management actual and amortized datasets to FOCUS.
On this page
This document provides guidance for converting Cost Management actual and amortized datasets to the FinOps Open Cost and Usage Specification (FOCUS). To learn more about FOCUS, refer to the FOCUS overview.
ā”ļø How to convert Cost Management data to FOCUS
In order to convert cost and usage data to FOCUS, you will need both the actual and amortized cost datasets:
- Keep all rows from the amortized cost data.
- Filter the actual cost data to only include rows where ChargeType == āPurchaseā or āRefundā and PricingModel == āReservationā or āSavingsPlanā.
Apply the following logic to all of the rows:
FOCUS column | Cost Management column | Transform |
---|---|---|
BilledCost | CostInBillingCurrency | If ChargeType == āUsageā and PricingModel == āReservationā or āSavingsPlanā, then 0 ; otherwise, use CostInBillingCurrency |
BillingAccountId | EA: BillingAccountId MCA: BillingProfileId | None |
BillingAccountName | EA: BillingAccountName MCA: BillingProfileName | None |
BillingCurrency | EA: BillingCurrencyCode MCA: BillingCurrency | None |
BillingPeriodEnd | BillingPeriodEndDate | Add 1 day for the exclusive end date |
BillingPeriodStart | BillingPeriodStartDate | None |
ChargeCategory | ChargeType | If āUsageā, āPurchaseā, āCreditā, or āTaxā, same value; if āUnusedReservationā or āUnusedSavingsPlanā, then Usage ; if āRefundā, āPurchaseā; otherwise, Adjustment |
ChargeClass | ChargeType | If āRefundā, then use Correction |
ChargeDescription | ProductName | None |
ChargeFrequency | Frequency | If āOneTimeā, One-Time ; if āRecurringā, Recurring ; if āUsageBasedā, Usage-Based ; otherwise, Other |
ChargePeriodEnd | Date | Add 1 day for the exclusive end date |
ChargePeriodStart | Date | None |
CommitmentDiscountCategory | BenefitId | If BenefitId contains ā/microsoft.capacity/ā (case-insensitive), Usage ; if contains ā/microsoft.billingbenefits/ā, use Spend ; otherwise, null |
CommitmentDiscountId | BenefitId | None |
CommitmentDiscountName | BenefitName | None |
CommitmentDiscountStatus | ChargeType | If āUnusedReservationā or āUnusedSavingsPlanā, then Unused ; else if PricingModel == āReservationā or āSavingsPlanā, then Used ; otherwise, null |
CommitmentDiscountType | BenefitId | If BenefitId contains ā/microsoft.capacity/ā (case-insensitive), Reservation ; if contains ā/microsoft.billingbenefits/ā, Savings Plan ; otherwise, null |
ConsumedQuantity | Quantity | If ChargeType == āUsageā, then Quantity; otherwise, null |
ConsumedUnit | UnitOfMeasure | If ChargeType == āUsageā, then map using Pricing units data file; otherwise, null |
ContractedCost | UnitPrice * Quantity / focus:x_PricingBlockSize | Note that x_PricingBlockSize requires a mapping. See column notes for details. |
ContractedUnitPrice | UnitPrice | None |
EffectiveCost | CostInBillingCurrency | If ChargeType == āPurchaseā or āRefundā and PricingModel == āReservationā or āSavingsPlanā, then 0 ; otherwise, use CostInBillingCurrency |
InvoiceIssuerName | PartnerName | If PartnerName is empty, use Microsoft |
ListCost | EA: Not available MCA: PaygCostInBillingCurrency | None |
ListUnitPrice | EA: PayGPrice MCA: PayGPrice * ExchangeRate | None |
PricingCategory | PricingModel | If āOnDemandā, then Standard ; if āSpotā, then Dynamic ; if āReservationā or āSavings Planā, then Committed ; otherwise, null |
PricingQuantity | Quantity / focus:x_PricingBlockSize | Note that x_PricingBlockSize requires a mapping. See column notes for details. |
PricingUnit | DistinctUnits (lookup) | Map UnitOfMeasure to DistinctUnits using Pricing units data file |
ProviderName | Microsoft | None |
PublisherName | PublisherName | None |
RegionId | focus:RegionName | Lowercase and remove spaces |
RegionName | ResourceLocation | Map ResourceLocation (OriginalValue) to RegionName using Regions data file2 |
ResourceId | ResourceId | None |
ResourceName | EA: ResourceName MCA: last(split(ResourceId, ā/ā)) | Azure resource names include multiple levels (e.g., āSqlServerName/SqlDbNameā), which requires more processing. This is a simplified approach to only use the last, most-specific segment. |
ResourceType | SingularDisplayName (lookup) | Map ResourceType to SingularDisplayName using Resource types data file |
ServiceCategory | ServiceCategory (lookup) | Map ConsumedService and ResourceType to SerivceCategory using Services data file |
ServiceName | ServiceName (lookup) | Map ConsumedService and ResourceType to SerivceName using Services data file |
SkuId | EA: Not available MCA: ProductId | None |
SkuPriceId | Not available | None |
SubAccountId | SubscriptionId | None |
SubAccountName | SubscriptionName | None |
Tags | Tags | Wrap in { and } if needed |
1. Quantity in Cost Management is the consumed (usage) quantity.
2. While RegionName is a direct mapping of ResourceLocation, Cost Management and FinOps toolkit reports do additional data cleansing to ensure consistency in values based on the Regions data file.
šāāļø Feedback about FOCUS columns
If you have feedback about our mappings or about our full FOCUS support plans, please start a thread in discussions. If you believe youāve found a bug, please create an issue.
If you have feedback about FOCUS, please create an issue in the FOCUS repository. We also encourage you to consider contributing to the FOCUS project. The project is looking for more practitioners to help bring their experience to help guide efforts and make this the most useful spec it can be. To learn more about FOCUS or to contribute to the project, visit focus.finops.org.
š§ See also
- How to update existing reports to FOCUS
- How to compare FOCUS with actual/amortized cost
- Data dictionary
- Generating a unique ID
- Known issues
- Common terms
š§° Related tools
- š¦ FinOps hubs ā Open, extensible, and scalable cost reporting.
- š Power BI reports ā Accelerate your reporting with Power BI starter kits.
- š„ļø PowerShell module ā Automate and manage FinOps solutions and capabilities.
- š Open data ā Data available for anyone to access, use, and share without restriction.