> ## Documentation Index
> Fetch the complete documentation index at: https://docs.costory.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Standard Columns

> Costory normalizes billing data from AWS, GCP, Azure, Datadog, and Elastic Cloud into a unified schema. Here is how each column is populated per provider.

Costory ingests raw billing exports from each cloud provider and normalizes them into a consistent set of `cos_*` columns. This lets you query, filter, and group costs across providers using a single schema, so you don't need to learn each provider's billing format. For Elastic Cloud setup and grain (project × day × product line), see [Elastic Cloud billing](/setup/billing/elastic-cloud).

Columns are organized into the following categories:

| Category        | Description                                                                                                                   |
| --------------- | ----------------------------------------------------------------------------------------------------------------------------- |
| **Invoice**     | Fields sourced directly from the provider billing export (accounts, charges, services, regions, resources, Kubernetes labels) |
| **Costory**     | Fields enriched by Costory (standardized region names, compute metadata, pricing model, marketplace flag)                     |
| **Datasources** | The Costory datasource that produced the row                                                                                  |

***

## Datasource & Provider Identification

### Invoice Issuer

The legal entity issuing the invoice, it also helps identifying marketplace purchases.

<Tabs>
  <Tab title="AWS">Sourced from `line_item_legal_entity`.</Tab>

  <Tab title="GCP">
    `"Google Cloud"` for first-party Google transactions (Compute Engine,
    Invoice service). For marketplace purchases, falls back to `seller_name` or
    `service.description`.
  </Tab>

  <Tab title="Azure">Hardcoded to `"Azure"`.</Tab>
  <Tab title="Datadog">Hardcoded to `"DataDog"`.</Tab>
  <Tab title="Elastic Cloud">Hardcoded to `"Elastic Cloud"`.</Tab>
</Tabs>

## Account & Billing

### Billing Account Id

The top-level billing or payer account.

<Tabs>
  <Tab title="AWS">`bill_payer_account_id`</Tab>
  <Tab title="GCP">`billing_account_id`</Tab>
  <Tab title="Azure">`BillingAccountId`</Tab>
  <Tab title="Datadog">`account_name`</Tab>
  <Tab title="Elastic Cloud">Elastic **project id** (`id` on the daily project snapshot).</Tab>
</Tabs>

***

### Sub Account ID / Project ID

The sub-account, project, or subscription under which the cost is incurred.

<Tabs>
  <Tab title="AWS">`line_item_usage_account_name`</Tab>
  <Tab title="GCP">`project.name` (falls back to `service.description`).</Tab>
  <Tab title="Azure">`SubscriptionName`</Tab>
  <Tab title="Datadog">`account_name`</Tab>
  <Tab title="Elastic Cloud">Elastic **project name** (`name`).</Tab>
</Tabs>

***

## Charge Classification

### Charge Category

Classifies the type of charge. Normalized to one of: `Usage`, `Purchase`, `Tax`, `Adjustment`.

<Tabs>
  <Tab title="AWS">
    Mapped from `line_item_line_item_type`: - `Usage`,
    `SavingsPlanCoveredUsage`, `SavingsPlanNegation`, `DiscountedUsage`,
    `BundledDiscount`, `Discount`, `PrivateRateDiscount`, `EdpDiscount` becomes
    **Usage** - `Fee`, `SavingsPlanUpfrontFee`, `RIFee`,
    `SavingsPlanRecurringFee` becomes **Purchase** - `Credit`, `Refund` becomes
    **Adjustment** - `Tax` becomes **Tax**
  </Tab>

  <Tab title="GCP">
    Mapped from `cost_type`: - `regular` becomes **Usage** - `tax` becomes **Tax** -
    `adjustment`, `credit`, `rounding_error`, and discount credit types becomes
    **Adjustment**
  </Tab>

  <Tab title="Azure">
    Mapped from `ChargeType`: - `Usage`, `UnusedReservation`,
    `UnusedSavingsPlan` becomes **Usage** - `Purchase` becomes **Purchase** - `Tax` becomes
    **Tax** - Everything else becomes **Adjustment**
  </Tab>

  <Tab title="Datadog">Always **Usage**.</Tab>
  <Tab title="Elastic Cloud">Always **Usage**.</Tab>
</Tabs>

***

### Charge Description

A human-readable description of the charge line item.

<Tabs>
  <Tab title="AWS">`line_item_line_item_description`</Tab>
  <Tab title="GCP">`sku.description`</Tab>
  <Tab title="Azure">`COALESCE(ProductName, ServiceName)`</Tab>
  <Tab title="Datadog">`charge_type`</Tab>
  <Tab title="Elastic Cloud">Full Elastic product line label for that line (same as **Service name**).</Tab>
</Tabs>

***

### Charge Frequency

How often the charge recurs. Normalized to: `One-Time`, `Recurring`, `Usage-Based`.

<Tabs>
  <Tab title="AWS">
    Based on `bill_bill_type`: - `Refund` or `Purchase` becomes **One-Time** -
    `Anniversary` becomes **Recurring**
  </Tab>

  <Tab title="GCP">Always **Recurring**.</Tab>

  <Tab title="Azure">
    Sourced from the `Frequency` field: - `OneTime` becomes **One-Time** - `Recurring`
    becomes **Recurring** - `UsageBased` becomes **Usage-Based**
  </Tab>

  <Tab title="Datadog">Always **Recurring**.</Tab>
  <Tab title="Elastic Cloud">Always **Usage-Based**.</Tab>
</Tabs>

***

## Service & SKU

### Category

A high-level cost category such as Compute, Storage, or Networking.
Mapped from a defined list of services.

<Tabs>
  <Tab title="AWS">Mapped from a defined list of services.</Tab>
  <Tab title="GCP">Mapped from a defined list of services.</Tab>
  <Tab title="Azure">Mapped from a defined list of services.</Tab>
  <Tab title="Datadog">Mapped from a defined list of services.</Tab>
  <Tab title="Elastic Cloud">Line **`type`** from the product line JSON (for example **`VCU`**, **`Search AI Lake`**, **`support`**).</Tab>
</Tabs>

***

### Service Name

The name of the cloud service.

<Tabs>
  <Tab title="AWS">
    `line_item_product_code` for first-party services. For marketplace,
    extracted from `product.key_value` (`product_name`).
  </Tab>

  <Tab title="GCP">`service.description`</Tab>
  <Tab title="Azure">`ConsumedService`</Tab>
  <Tab title="Datadog">`product_name`</Tab>
  <Tab title="Elastic Cloud">Full Elastic product line label for that line (for example `Elasticsearch - General Purpose - Search VCU (GCP us-central1)`).</Tab>
</Tabs>

***

### SKU ID

The SKU identifier.

<Tabs>
  <Tab title="AWS">
    `product_sku` for first-party services; marketplace product name otherwise.
  </Tab>

  <Tab title="GCP">`sku.id`</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`product_name`</Tab>
  <Tab title="Elastic Cloud">Product line **`sku`** code (for example `elasticsearch.general-purpose-search-vcu_gcp-us-central1`).</Tab>
</Tabs>

***

### SKU Description

A human-readable SKU description.

<Tabs>
  <Tab title="AWS">
    `CONCAT(product_operation, "_", product_product_family)` for first-party
    services; marketplace product name otherwise.
  </Tab>

  <Tab title="GCP">`sku.description`</Tab>
  <Tab title="Azure">`meterName`</Tab>
  <Tab title="Datadog">`charge_type`</Tab>
  <Tab title="Elastic Cloud">Same as **Service name** (human-readable product line label).</Tab>
</Tabs>

***

## Location & Infrastructure

### Availability Zone

The availability zone of the resource.

<Tabs>
  <Tab title="AWS">`line_item_availability_zone`</Tab>
  <Tab title="GCP">`location.zone`</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### Region ID

The raw, provider-specific region identifier.

<Tabs>
  <Tab title="AWS">`product.key_value["region"]` or `product_region_code`</Tab>
  <Tab title="GCP">`location.region`</Tab>
  <Tab title="Azure">`ResourceLocation`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">Parsed from the product line **SKU** when it includes a cloud/region suffix (for example `gcp-us-central1` from `..._gcp-us-central1`); otherwise `NULL`.</Tab>
</Tabs>

***

### Region

The standardized, human-readable region name. Costory maps each provider's raw region identifier to a common name via an internal region mapper.

<Tabs>
  <Tab title="AWS">`StandardRegionName` joined on `product_region_code`.</Tab>
  <Tab title="GCP">`StandardRegionName` joined on `location.region`.</Tab>
  <Tab title="Azure">`StandardRegionName` joined on `ResourceLocation`.</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">Same **region token** as **Region ID** when present (Elastic encodes region in the SKU string).</Tab>
</Tabs>

***

## Resource

### Resource Id

The unique identifier of the resource.

<Tabs>
  <Tab title="AWS">`line_item_resource_id`</Tab>

  <Tab title="GCP">
    `resource.global_name` (detailed billing only, otherwise `NULL`).
  </Tab>

  <Tab title="Azure">`COALESCE(ResourceId, InstanceId)`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">Elastic **project id** (same as **Billing account id**).</Tab>
</Tabs>

***

### Resource Name

A human-readable name for the resource.

<Tabs>
  <Tab title="AWS">`line_item_resource_id` (same as Resource Id).</Tab>

  <Tab title="GCP">
    `resource.name` (detailed billing only, otherwise `NULL`).
  </Tab>

  <Tab title="Azure">`COALESCE(ResourceGroupName, ResourceGroup)`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">Elastic **project name** (same as **Sub account id**).</Tab>
</Tabs>

***

## Commitment Discounts

### Commitment Discount Category

The type of commitment discount. `Usage` indicates a resource-based commitment (Reserved Instances, resource-based CUDs). `Spend` indicates a dollar-based commitment (Savings Plans, dollar-based CUDs).

<Tabs>
  <Tab title="AWS">
    * Savings Plan ARN present becomes **Spend** - Reservation ARN present becomes **Usage**
  </Tab>

  <Tab title="GCP">
    * `COMMITTED_USAGE_DISCOUNT_DOLLAR_BASE` becomes **Spend** -
      `COMMITTED_USAGE_DISCOUNT` becomes **Usage**
  </Tab>

  <Tab title="Azure">
    * `microsoft.capacity` in `benefitId` becomes **Usage** -
      `microsoft.billingbenefits` in `benefitId` becomes **Spend**
  </Tab>

  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### Commitment Discount Id

The identifier of the commitment discount (ARN, CUD name, or benefit ID).

<Tabs>
  <Tab title="AWS">
    `savings_plan_savings_plan_a_r_n` or `reservation_reservation_a_r_n`
  </Tab>

  <Tab title="GCP">`cud.full_name` (extracted from credits array).</Tab>
  <Tab title="Azure">`benefitId`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

## Compute Enrichment

These fields are enriched by Costory to provide deeper visibility into compute spend.

### Machine Type

The instance or machine type (e.g., `m5.xlarge`, `n2-standard-4`).

<Tabs>
  <Tab title="AWS">
    Extracted from `line_item_usage_type` after the `:` separator.
  </Tab>

  <Tab title="GCP">
    From `system_labels` where the key matches `machine_spec`.
  </Tab>

  <Tab title="Azure">
    Extracted from `ProductName` via regex, for Virtual Machines Compute only.
  </Tab>

  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### Machine Family

The machine family (e.g., `m5`, `n2`, `Dv3`).

<Tabs>
  <Tab title="AWS">First part of the machine type (split on `.`).</Tab>

  <Tab title="GCP">
    First part of the `machine_spec` system label (split on `-`).
  </Tab>

  <Tab title="Azure">
    Extracted from `MeterSubCategory` via regex (`Virtual Machines Xxx Series`).
  </Tab>

  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### Pricing Model (Spot / On Demand)

How the resource is priced. Normalized to: `On Demand`, `Spot`, `Reservation`, `Savings Plan`.

<Tabs>
  <Tab title="AWS">
    * `DiscountedUsage` becomes **Reservation** - `SavingsPlanCoveredUsage` becomes
      **Savings Plan** - Usage type contains `SpotUsage` becomes **Spot** - `Usage` becomes
      **On Demand**
  </Tab>

  <Tab title="GCP">
    SKU description contains `Spot` or `Preemptible` becomes **Spot**; otherwise **On
    Demand**.
  </Tab>

  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### Marketplace Purchase

Whether the charge is a marketplace purchase. This field is not populated directly by billing converters. It is derived downstream by Costory.

***

### Line Item Usage Type

The raw usage type from the provider. Not populated as a `cos_*` column in converters. Available via provider-specific labels (e.g., `aws_line_item_usage_type` for AWS).

<Tabs>
  <Tab title="AWS">`line_item_usage_type`</Tab>
  <Tab title="GCP">SKU description</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">Line **`type`** on the product line (for example **`VCU`**). Also available on labels such as **`line_type`**.</Tab>
</Tabs>

***

## Kubernetes

These fields provide Kubernetes-level cost attribution. For GCP, most are populated natively from GKE billing labels. For AWS and Azure, they are typically enriched downstream via Costory's K8s integration.

### K8s Cluster Name

The name of the kubernetes cluster.

<Tabs>
  <Tab title="AWS">`NULL` (populated downstream via K8s enrichment).</Tab>
  <Tab title="GCP">Label `k8s-cluster-name`.</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### K8s Namespace

The kubernetes namespace for that cost.

<Tabs>
  <Tab title="AWS">`NULL`</Tab>
  <Tab title="GCP">Label `k8s-namespace`.</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### K8s Namespace Reallocated

Namespace reallocated: is a view over namespace with the waste cost reallocated to each namespace depending on their usage: this is only available on AWS EKS.

***

### K8s Workload Name

The name of the workload, it's the name of pod it can contain ids.

<Tabs>
  <Tab title="AWS">`NULL`</Tab>
  <Tab title="GCP">Label `k8s-workload-name`.</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### K8s Workload Type

The Kubernetes workload type (Deployment, StatefulSet, DaemonSet, etc.).

<Tabs>
  <Tab title="AWS">`NULL`</Tab>
  <Tab title="GCP">Label `k8s-workload-type`.</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>

***

### K8s Node Pool Name

The name of the node pool (node group in AWS).

<Tabs>
  <Tab title="AWS">Resource tag matching `nodegroup_name`.</Tab>
  <Tab title="GCP">Label `k8s-node-pool-name`.</Tab>
  <Tab title="Azure">`NULL`</Tab>
  <Tab title="Datadog">`NULL`</Tab>
  <Tab title="Elastic Cloud">`NULL`</Tab>
</Tabs>
