For AI agents: A markdown version of this page is available at https://dnd37xeb23o8n.cloudfront.net/stefon.simmons/docs-astro-web-10435/ja/api/latest/usage-metering/get-billing-dimension-mapping-for-usage-endpoints.md. A documentation index is available at /llms.txt.
Language
Datadog site

Get billing dimension mapping for usage endpoints

GEThttps://api.datadoghq.com/api/v2/usage/billing_dimension_mappinghttps://api.us3.datadoghq.com/api/v2/usage/billing_dimension_mappinghttps://api.us5.datadoghq.com/api/v2/usage/billing_dimension_mappinghttps://api.datadoghq.eu/api/v2/usage/billing_dimension_mappinghttps://api.ap1.datadoghq.com/api/v2/usage/billing_dimension_mappinghttps://api.ap2.datadoghq.com/api/v2/usage/billing_dimension_mappinghttps://api.uk1.datadoghq.com/api/v2/usage/billing_dimension_mappinghttps://api.ddog-gov.com/api/v2/usage/billing_dimension_mappinghttps://api.us2.ddog-gov.com/api/v2/usage/billing_dimension_mapping

概要

サポートされている使用量メータリングの公開 API エンドポイントに対応するキーへの課金ディメンションのマッピングを取得します。 マッピングデータは月単位で更新されます。

このエンドポイントは親レベル組織にのみアクセス可能です。

This endpoint requires the usage_read permission.

OAuth apps require the usage_read authorization scope to access this endpoint.

引数

クエリ文字列

名前
タイプ
説明
filter[month]
string

Datetime in ISO-8601 format, UTC, and for mappings beginning this month. Defaults to the current month.

filter[view]
string

String to specify whether to retrieve active billing dimension mappings for the contract or for all available mappings. Allowed views have the string active or all. Defaults to active.

Default: active

応答

OK

Billing dimensions mapping response.

フィールド
タイプ
説明
data
[object]

Billing dimensions mapping data.

コード例

Get billing dimension mapping for usage endpoints
# Set your Datadog site and credentials
export DD_SITE="datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="us3.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="us5.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="datadoghq.eu"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="ap1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="ap2.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="uk1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"
# Set your Datadog site and credentials
export DD_SITE="us2.ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X GET "https://api.${DD_SITE}/api/v2/usage/billing_dimension_mapping" \
-H "Accept: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}"