Azure インテグレーション

Datadog-Azure インテグレーションの構成は、Datadog API から直接行います。 詳細については、Datadog-Azure インテグレーションのページを参照してください。

GET https://api.ap1.datadoghq.com/api/v1/integration/azurehttps://api.datadoghq.eu/api/v1/integration/azurehttps://api.ddog-gov.com/api/v1/integration/azurehttps://api.datadoghq.com/api/v1/integration/azurehttps://api.us3.datadoghq.com/api/v1/integration/azurehttps://api.us5.datadoghq.com/api/v1/integration/azure

概要

お使いの Datadog アカウントで構成されたすべての Datadog-Azure インテグレーションをリストします。 This endpoint requires the azure_configuration_read permission.

応答

OK

Accounts configured for your organization.

Expand All

フィールド

種類

説明

app_service_plan_filters

string

Limit the Azure app service plans that are pulled into Datadog using tags. Only app service plans that match one of the defined tags are imported into Datadog.

automute

boolean

Silence monitors for expected Azure VM shutdowns.

client_id

string

Your Azure web application ID.

client_secret

string

Your Azure web application secret key.

container_app_filters

string

Limit the Azure container apps that are pulled into Datadog using tags. Only container apps that match one of the defined tags are imported into Datadog.

cspm_enabled

boolean

When enabled, Datadog’s Cloud Security Management product scans resource configurations monitored by this app registration. Note: This requires resource_collection_enabled to be set to true.

custom_metrics_enabled

boolean

Enable custom metrics for your organization.

errors

[string]

Errors in your configuration.

host_filters

string

Limit the Azure instances that are pulled into Datadog by using tags. Only hosts that match one of the defined tags are imported into Datadog.

metrics_enabled

boolean

Enable Azure metrics for your organization.

metrics_enabled_default

boolean

Enable Azure metrics for your organization for resource providers where no resource provider config is specified.

new_client_id

string

Your New Azure web application ID.

new_tenant_name

string

Your New Azure Active Directory ID.

resource_collection_enabled

boolean

When enabled, Datadog collects metadata and configuration info from cloud resources (compute instances, databases, load balancers, etc.) monitored by this app registration.

resource_provider_configs

[object]

Configuration settings applied to resources from the specified Azure resource providers.

metrics_enabled

boolean

Collect metrics for resources from this provider.

namespace

string

The provider namespace to apply this configuration to.

tenant_name

string

Your Azure Active Directory ID.

usage_metrics_enabled

boolean

Enable azure.usage metrics for your organization.

{
  "app_service_plan_filters": "key:value,filter:example",
  "automute": true,
  "client_id": "testc7f6-1234-5678-9101-3fcbf464test",
  "client_secret": "TestingRh2nx664kUy5dIApvM54T4AtO",
  "container_app_filters": "key:value,filter:example",
  "cspm_enabled": true,
  "custom_metrics_enabled": true,
  "errors": [
    "*"
  ],
  "host_filters": "key:value,filter:example",
  "metrics_enabled": true,
  "metrics_enabled_default": true,
  "new_client_id": "new1c7f6-1234-5678-9101-3fcbf464test",
  "new_tenant_name": "new1c44-1234-5678-9101-cc00736ftest",
  "resource_collection_enabled": true,
  "resource_provider_configs": [
    {
      "metrics_enabled": true,
      "namespace": "Microsoft.Compute"
    }
  ],
  "tenant_name": "testc44-1234-5678-9101-cc00736ftest",
  "usage_metrics_enabled": true
}

Bad Request

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Authentication Error

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Too many requests

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

コード例

from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

api.AzureIntegration.list()

Instructions

First install the library and its dependencies and then save the example to example.py and run following commands:

    
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comddog-gov.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" python "example.py"

POST https://api.ap1.datadoghq.com/api/v1/integration/azurehttps://api.datadoghq.eu/api/v1/integration/azurehttps://api.ddog-gov.com/api/v1/integration/azurehttps://api.datadoghq.com/api/v1/integration/azurehttps://api.us3.datadoghq.com/api/v1/integration/azurehttps://api.us5.datadoghq.com/api/v1/integration/azure

概要

Datadog-Azure インテグレーションを作成します。

POST メソッドを使用すると、Datadog Organization の既存の構成に 新しい構成を追加してインテグレーション構成が更新されます。

PUT メソッドを使用すると、既存の構成を Datadog オーガニゼーションに送信された新しい構成で 置き換える形でインテグレーション構成が更新されます。

This endpoint requires the azure_configurations_manage permission.

リクエスト

Body Data (required)

Datadog アカウントのリクエスト本文に対応する Datadog-Azure インテグレーションを作成します。

Expand All

フィールド

種類

説明

app_service_plan_filters

string

Limit the Azure app service plans that are pulled into Datadog using tags. Only app service plans that match one of the defined tags are imported into Datadog.

automute

boolean

Silence monitors for expected Azure VM shutdowns.

client_id

string

Your Azure web application ID.

client_secret

string

Your Azure web application secret key.

container_app_filters

string

Limit the Azure container apps that are pulled into Datadog using tags. Only container apps that match one of the defined tags are imported into Datadog.

cspm_enabled

boolean

When enabled, Datadog’s Cloud Security Management product scans resource configurations monitored by this app registration. Note: This requires resource_collection_enabled to be set to true.

custom_metrics_enabled

boolean

Enable custom metrics for your organization.

errors

[string]

Errors in your configuration.

host_filters

string

Limit the Azure instances that are pulled into Datadog by using tags. Only hosts that match one of the defined tags are imported into Datadog.

metrics_enabled

boolean

Enable Azure metrics for your organization.

metrics_enabled_default

boolean

Enable Azure metrics for your organization for resource providers where no resource provider config is specified.

new_client_id

string

Your New Azure web application ID.

new_tenant_name

string

Your New Azure Active Directory ID.

resource_collection_enabled

boolean

When enabled, Datadog collects metadata and configuration info from cloud resources (compute instances, databases, load balancers, etc.) monitored by this app registration.

resource_provider_configs

[object]

Configuration settings applied to resources from the specified Azure resource providers.

metrics_enabled

boolean

Collect metrics for resources from this provider.

namespace

string

The provider namespace to apply this configuration to.

tenant_name

string

Your Azure Active Directory ID.

usage_metrics_enabled

boolean

Enable azure.usage metrics for your organization.

{
  "app_service_plan_filters": "key:value,filter:example",
  "automute": true,
  "client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "client_secret": "TestingRh2nx664kUy5dIApvM54T4AtO",
  "container_app_filters": "key:value,filter:example",
  "cspm_enabled": true,
  "custom_metrics_enabled": true,
  "errors": [
    "*"
  ],
  "host_filters": "key:value,filter:example",
  "new_client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "new_tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "resource_collection_enabled": true,
  "tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"
}

応答

OK

Expand All

フィールド

種類

説明

No response body

{}

Bad Request

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Authentication Error

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Too many requests

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

コード例

from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

api.AzureIntegration.create(
    tenant_name="<AZURE_TENANT_NAME>",
    host_filters="<KEY_1>:<VALUE_1>,<KEY_2>:<VALUE_2>",
    client_id="<AZURE_CLIENT_ID>",
    client_secret="<AZURE_CLIENT_SECRET>"
)

Instructions

First install the library and its dependencies and then save the example to example.py and run following commands:

    
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comddog-gov.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" python "example.py"

DELETE https://api.ap1.datadoghq.com/api/v1/integration/azurehttps://api.datadoghq.eu/api/v1/integration/azurehttps://api.ddog-gov.com/api/v1/integration/azurehttps://api.datadoghq.com/api/v1/integration/azurehttps://api.us3.datadoghq.com/api/v1/integration/azurehttps://api.us5.datadoghq.com/api/v1/integration/azure

概要

Datadog アカウントから 特定の Datadog-Azure インテグレーションを削除します。 This endpoint requires the azure_configurations_manage permission.

リクエスト

Body Data (required)

特定の Datadog-Azure インテグレーションのリクエスト本文を削除します。

Expand All

フィールド

種類

説明

app_service_plan_filters

string

Limit the Azure app service plans that are pulled into Datadog using tags. Only app service plans that match one of the defined tags are imported into Datadog.

automute

boolean

Silence monitors for expected Azure VM shutdowns.

client_id

string

Your Azure web application ID.

client_secret

string

Your Azure web application secret key.

container_app_filters

string

Limit the Azure container apps that are pulled into Datadog using tags. Only container apps that match one of the defined tags are imported into Datadog.

cspm_enabled

boolean

When enabled, Datadog’s Cloud Security Management product scans resource configurations monitored by this app registration. Note: This requires resource_collection_enabled to be set to true.

custom_metrics_enabled

boolean

Enable custom metrics for your organization.

errors

[string]

Errors in your configuration.

host_filters

string

Limit the Azure instances that are pulled into Datadog by using tags. Only hosts that match one of the defined tags are imported into Datadog.

metrics_enabled

boolean

Enable Azure metrics for your organization.

metrics_enabled_default

boolean

Enable Azure metrics for your organization for resource providers where no resource provider config is specified.

new_client_id

string

Your New Azure web application ID.

new_tenant_name

string

Your New Azure Active Directory ID.

resource_collection_enabled

boolean

When enabled, Datadog collects metadata and configuration info from cloud resources (compute instances, databases, load balancers, etc.) monitored by this app registration.

resource_provider_configs

[object]

Configuration settings applied to resources from the specified Azure resource providers.

metrics_enabled

boolean

Collect metrics for resources from this provider.

namespace

string

The provider namespace to apply this configuration to.

tenant_name

string

Your Azure Active Directory ID.

usage_metrics_enabled

boolean

Enable azure.usage metrics for your organization.

{
  "client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"
}

応答

OK

Expand All

フィールド

種類

説明

No response body

{}

Bad Request

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Authentication Error

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Too many requests

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

コード例

from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

api.AzureIntegration.delete(
    tenant_name="<AZURE_TENANT_NAME>",
    client_id="<AZURE_CLIENT_ID>"
)

Instructions

First install the library and its dependencies and then save the example to example.py and run following commands:

    
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comddog-gov.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" python "example.py"

PUT https://api.ap1.datadoghq.com/api/v1/integration/azurehttps://api.datadoghq.eu/api/v1/integration/azurehttps://api.ddog-gov.com/api/v1/integration/azurehttps://api.datadoghq.com/api/v1/integration/azurehttps://api.us3.datadoghq.com/api/v1/integration/azurehttps://api.us5.datadoghq.com/api/v1/integration/azure

概要

Datadog-Azure インテグレーションを更新します。既存の tenant_nameclient_id が必要です。 その他フィールドの既存の値は提供されたフィールドの値で上書きされます。tenant_name および client_id を上書きするには、 new_tenant_namenew_client_id を使用します。フィールドを変更しない場合は、ペイロードで該当するフィールドを提供する必要はありません。 This endpoint requires the azure_configuration_edit permission.

リクエスト

Body Data (required)

Datadog-Azure インテグレーションのリクエスト本文を更新します。

Expand All

フィールド

種類

説明

app_service_plan_filters

string

Limit the Azure app service plans that are pulled into Datadog using tags. Only app service plans that match one of the defined tags are imported into Datadog.

automute

boolean

Silence monitors for expected Azure VM shutdowns.

client_id

string

Your Azure web application ID.

client_secret

string

Your Azure web application secret key.

container_app_filters

string

Limit the Azure container apps that are pulled into Datadog using tags. Only container apps that match one of the defined tags are imported into Datadog.

cspm_enabled

boolean

When enabled, Datadog’s Cloud Security Management product scans resource configurations monitored by this app registration. Note: This requires resource_collection_enabled to be set to true.

custom_metrics_enabled

boolean

Enable custom metrics for your organization.

errors

[string]

Errors in your configuration.

host_filters

string

Limit the Azure instances that are pulled into Datadog by using tags. Only hosts that match one of the defined tags are imported into Datadog.

metrics_enabled

boolean

Enable Azure metrics for your organization.

metrics_enabled_default

boolean

Enable Azure metrics for your organization for resource providers where no resource provider config is specified.

new_client_id

string

Your New Azure web application ID.

new_tenant_name

string

Your New Azure Active Directory ID.

resource_collection_enabled

boolean

When enabled, Datadog collects metadata and configuration info from cloud resources (compute instances, databases, load balancers, etc.) monitored by this app registration.

resource_provider_configs

[object]

Configuration settings applied to resources from the specified Azure resource providers.

metrics_enabled

boolean

Collect metrics for resources from this provider.

namespace

string

The provider namespace to apply this configuration to.

tenant_name

string

Your Azure Active Directory ID.

usage_metrics_enabled

boolean

Enable azure.usage metrics for your organization.

{
  "app_service_plan_filters": "key:value,filter:example",
  "automute": true,
  "client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "client_secret": "TestingRh2nx664kUy5dIApvM54T4AtO",
  "container_app_filters": "key:value,filter:example",
  "cspm_enabled": true,
  "custom_metrics_enabled": true,
  "errors": [
    "*"
  ],
  "host_filters": "key:value,filter:example",
  "new_client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "new_tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
  "resource_collection_enabled": true,
  "tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d"
}

応答

OK

Expand All

フィールド

種類

説明

No response body

{}

Bad Request

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Authentication Error

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Too many requests

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

コード例

                          # Curl command
curl -X PUT "https://api.ap1.datadoghq.com"https://api.datadoghq.eu"https://api.ddog-gov.com"https://api.datadoghq.com"https://api.us3.datadoghq.com"https://api.us5.datadoghq.com/api/v1/integration/azure" \ -H "Accept: application/json" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}" \ -d @- << EOF { "app_service_plan_filters": "key:value,filter:example", "automute": true, "client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", "client_secret": "TestingRh2nx664kUy5dIApvM54T4AtO", "container_app_filters": "key:value,filter:example", "cspm_enabled": true, "custom_metrics_enabled": true, "errors": [ "*" ], "host_filters": "key:value,filter:example", "new_client_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", "new_tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d", "resource_collection_enabled": true, "tenant_name": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d" } EOF

POST https://api.ap1.datadoghq.com/api/v1/integration/azure/host_filtershttps://api.datadoghq.eu/api/v1/integration/azure/host_filtershttps://api.ddog-gov.com/api/v1/integration/azure/host_filtershttps://api.datadoghq.com/api/v1/integration/azure/host_filtershttps://api.us3.datadoghq.com/api/v1/integration/azure/host_filtershttps://api.us5.datadoghq.com/api/v1/integration/azure/host_filters

概要

特定の Datadog-Azure インテグレーション用に定義されたホストフィルターのリストを更新します。 This endpoint requires the azure_configuration_edit permission.

リクエスト

Body Data (required)

Datadog-Azure インテグレーションホストフィルターのリクエスト本文を更新します。

Expand All

フィールド

種類

説明

app_service_plan_filters

string

Limit the Azure app service plans that are pulled into Datadog using tags. Only app service plans that match one of the defined tags are imported into Datadog.

automute

boolean

Silence monitors for expected Azure VM shutdowns.

client_id

string

Your Azure web application ID.

client_secret

string

Your Azure web application secret key.

container_app_filters

string

Limit the Azure container apps that are pulled into Datadog using tags. Only container apps that match one of the defined tags are imported into Datadog.

cspm_enabled

boolean

When enabled, Datadog’s Cloud Security Management product scans resource configurations monitored by this app registration. Note: This requires resource_collection_enabled to be set to true.

custom_metrics_enabled

boolean

Enable custom metrics for your organization.

errors

[string]

Errors in your configuration.

host_filters

string

Limit the Azure instances that are pulled into Datadog by using tags. Only hosts that match one of the defined tags are imported into Datadog.

metrics_enabled

boolean

Enable Azure metrics for your organization.

metrics_enabled_default

boolean

Enable Azure metrics for your organization for resource providers where no resource provider config is specified.

new_client_id

string

Your New Azure web application ID.

new_tenant_name

string

Your New Azure Active Directory ID.

resource_collection_enabled

boolean

When enabled, Datadog collects metadata and configuration info from cloud resources (compute instances, databases, load balancers, etc.) monitored by this app registration.

resource_provider_configs

[object]

Configuration settings applied to resources from the specified Azure resource providers.

metrics_enabled

boolean

Collect metrics for resources from this provider.

namespace

string

The provider namespace to apply this configuration to.

tenant_name

string

Your Azure Active Directory ID.

usage_metrics_enabled

boolean

Enable azure.usage metrics for your organization.

{
  "app_service_plan_filters": "key:value,filter:example",
  "automute": true,
  "client_id": "testc7f6-1234-5678-9101-3fcbf464test",
  "client_secret": "TestingRh2nx664kUy5dIApvM54T4AtO",
  "container_app_filters": "key:value,filter:example",
  "cspm_enabled": true,
  "custom_metrics_enabled": true,
  "errors": [
    "*"
  ],
  "host_filters": "key:value,filter:example",
  "metrics_enabled": true,
  "metrics_enabled_default": true,
  "new_client_id": "new1c7f6-1234-5678-9101-3fcbf464test",
  "new_tenant_name": "new1c44-1234-5678-9101-cc00736ftest",
  "resource_collection_enabled": true,
  "resource_provider_configs": [
    {
      "metrics_enabled": true,
      "namespace": "Microsoft.Compute"
    }
  ],
  "tenant_name": "testc44-1234-5678-9101-cc00736ftest",
  "usage_metrics_enabled": true
}

応答

OK

Expand All

フィールド

種類

説明

No response body

{}

Bad Request

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Authentication Error

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

Too many requests

Error response object.

Expand All

フィールド

種類

説明

errors [required]

[string]

Array of errors returned by the API.

{
  "errors": [
    "Bad Request"
  ]
}

コード例

from datadog import initialize, api

options = {
    'api_key': '<DATADOG_API_KEY>',
    'app_key': '<DATADOG_APPLICATION_KEY>'
}

initialize(**options)

api.AzureIntegration.update_host_filters(
    tenant_name="<AZURE_TENANT_NAME>",
    host_filters="new:filters",
    client_id="<AZURE_CLIENT_ID>"
)

Instructions

First install the library and its dependencies and then save the example to example.py and run following commands:

    
DD_SITE="datadoghq.comus3.datadoghq.comus5.datadoghq.comdatadoghq.euap1.datadoghq.comddog-gov.com" DD_API_KEY="<API-KEY>" DD_APP_KEY="<APP-KEY>" python "example.py"

PREVIEWING: ashley.yip/dynamic-cost-allocation-docs