Discover available fields and data sources for Analytics queries.
Ternary's Analytics API puts you in control of your data and lets you make queries against the billing dataset you have ingested to Ternary. This endpoint supports the Query endpoint by helping you understand what dimensions and measures are available to you, and specifically, what cloud integrations those dimensions and measures are populated in.
Metadata reflects the caller's Analytics access in the selected tenant. Integration-specific fields are limited to accessible integrations; Ternary-defined fields can remain available without belonging to a particular integration. For MSP customer tenants, metadata excludes labels produced by billing rules, except labels from reallocation rules that redistribute costs. A successful response can contain "schemas": [] when no ready billing sources exist. Optional field descriptions and custom unit information can be unavailable even when the metadata request succeeds.
Each schema groups fields into measures, dimensions and timeDimensions. Field metadata includes:
| Field | Meaning |
|---|---|
displayName | Human-readable label; not necessarily unique. |
schemaFieldName | Field identifier to use in query measures, dimensions or filters. |
description | Field explanation, or null when unavailable. |
sourceUrl | Documentation URL, or null when unavailable. |
dataType | Underlying field data type. |
unitType | Optional unit: STANDARD, CURRENCY, PERCENTAGE, BINARY_BYTES, BYTES, CORES or KILOGRAMS. Percentage values use the 0–100 magnitude. |
namespace | Normalized namespace, such as FOCUS_SPEC_FIELD, GCP_LABEL or TERNARY_CUSTOM_MEASURE. |
providerName | Provider associated with the field. |
integrationName | Present only for custom data (BYOD) fields in CUSTOM_DATA_TAG or CUSTOM_DATA_BILLING_EXPORT_FIELD. Distinguishes entries with the same schemaFieldName from different integrations. |
Do not identify a field by its display name alone: fields with the same display name can belong to different namespaces. Use the returned field identifiers when building a query.
Dimensions and measures that you can use in queries always follow a structure, NAMESPACE/name. Namespaces include, but are not limited to:
FOCUS_SPEC_FIELD: Multi-cloud billing columns that are part of the FOCUS 1.0 or 1.1 specification.TERNARY_MULTI_CLOUD_FIELD: Multi-cloud billing columns that are created by Ternary for use in multiple clouds.GCP_LABEL: A label specified on a resource, project or folder within Google Cloud.AWS_USER_DEFINED_TAG,AWS_GENERATED_TAG: A tag specified on a resource or account within Amazon Web Services. User-defined tags are created by AWS users; generated tags occur naturally when using particular resources, such as EKS.AZURE_TAG: A tag specified on a resource within Microsoft Azure
Descriptions in this example are abbreviated from the catalog. The example shows several common namespaces, unavailable enrichment as null, an optional integration name, and an empty timeDimensions list. Actual fields depend on the selected tenant and data source. Send the response's schemaName value as data_source in the Query request body (for example, FOCUS_BILLING). Use each field's schemaFieldName value in the request's measures or dimensions (for example, FOCUS_SPEC_FIELD/BilledCost).
{
"schemas": [
{
"schemaName": "FOCUS_BILLING",
"measures": [
{
"displayName": "Billed Cost",
"dataType": "FLOAT",
"unitType": "CURRENCY",
"namespace": "FOCUS_SPEC_FIELD",
"providerName": "FOCUS",
"schemaFieldName": "FOCUS_SPEC_FIELD/BilledCost",
"description": "A charge serving as the basis for invoicing, inclusive of all reduced rates and discounts while excluding the amortization of upfront charges (one-time or recurring).",
"sourceUrl": "https://focus.finops.org/focus-specification/v1-1/"
},
{
"displayName": "cost_myCost",
"dataType": "FLOAT",
"unitType": "CURRENCY",
"namespace": "OCI_BILLING_EXPORT_FIELD",
"providerName": "OCI",
"schemaFieldName": "OCI_BILLING_EXPORT_FIELD/cost_myCost",
"description": null,
"sourceUrl": null
}
],
"dimensions": [
{
"displayName": "Sub Account ID",
"dataType": "STRING",
"namespace": "FOCUS_SPEC_FIELD",
"providerName": "FOCUS",
"schemaFieldName": "FOCUS_SPEC_FIELD/SubAccountId",
"description": "An ID assigned to a grouping of [resources](https://focus.finops.org/focus-specification/v1-1/#glossary:resource) or [services](https://focus.finops.org/focus-specification/v1-1/#glossary:service), often used to manage access and/or cost.",
"sourceUrl": "https://focus.finops.org/focus-specification/v1-1/"
},
{
"displayName": "Invoice Month",
"dataType": "STRING",
"namespace": "TERNARY_MULTI_CLOUD_FIELD",
"providerName": "TERNARY",
"schemaFieldName": "TERNARY_MULTI_CLOUD_FIELD/invoice_month",
"description": "A Ternary platform field. The billing period this row belongs to, formatted as YYYYMM (e.g. 202607 for July 2026). Populated consistently across every provider, even ones without a native invoice-period field.",
"sourceUrl": null
},
{
"displayName": "goog-fleet-project",
"dataType": "STRING",
"namespace": "GCP_LABEL",
"providerName": "GCP",
"schemaFieldName": "GCP_LABEL/goog-fleet-project",
"description": null,
"sourceUrl": null
},
{
"displayName": "eks_cluster_name",
"dataType": "STRING",
"namespace": "AWS_USER_DEFINED_TAG",
"providerName": "AWS",
"schemaFieldName": "AWS_USER_DEFINED_TAG/eks_cluster_name",
"description": null,
"sourceUrl": null
},
{
"displayName": "team",
"dataType": "STRING",
"namespace": "CUSTOM_DATA_TAG",
"providerName": "CUSTOM_DATA",
"schemaFieldName": "CUSTOM_DATA_TAG/team",
"description": null,
"sourceUrl": null,
"integrationName": "Example custom data integration"
}
],
"timeDimensions": []
}
]
}