Domain Allowlist API

이 페이지는 아직 한국어로 제공되지 않으며 번역 작업 중입니다. 번역에 관한 질문이나 의견이 있으시면 언제든지 저희에게 연락해 주십시오.
Join the Beta!

Domain Allowlist is available in private beta for customers with Enterprise plans. If you're interested in this feature, complete the form to request access.

Request Access

Domain Allowlist enables you to restrict the email domains to which notifications can be sent.

This document describes how to access and configure Domain Allowlist through the API. To use the UI instead, see Domain Allowlist.

Get Domain Allowlist

Return the Domain Allowlist and its enabled or disabled state.

GET https://api.datadoghq.com/api/v2/domain_allowlist

Request

Example

curl -X GET "https://api.datadoghq.com/api/v2/domain_allowlist" \
-H "Accept: application/json" \
-H "DD-API-KEY: ${DD_API_KEY}" \
-H "DD-APPLICATION-KEY: ${DD_APP_KEY}"

Response

OK

Model

FieldTypeDescription
dataobjectDomain Allowlist email data
data.typeenumDomain Allowlist type. Allowed enum values: domain_allowlist. Default: domain_allowlist.
data.attributesobjectAttributes of Domain Allowlist
data.attributes.enabledBooleanIf true, Domain Allowlist is enabled
data.attributes.domains[string]List of domains in Domain Allowlist

Forbidden

Model

FieldTypeDescription
errors [required][string]List of errors

Not Found

Model

FieldTypeDescription
errors [required][string]List of errors

Too many requests

Model

FieldTypeDescription
errors [required][string]List of errors

Example

{
  "data": {
    "type": "domain_allowlist",
    "attributes": {
      "enabled": true,
      "domains": [
        "@aol.com",
        "@yahoo.com",
        "@gmail.com"
      ]
    }
  }
}

Modify Domain Allowlist

Enable/disable Domain Allowlist and rewrite the entire allowlist with a given list of email domains.

PATCH https://api.datadoghq.com/api/v2/domain_allowlist

Request

Example

curl -X PATCH "https://api.datadog.com/api/v2/domain_allowlist" \
-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

{
  "data": {
    "type": "domain_allowlist",
    "attributes": {
      "enabled": true,
      "domains": [
        "@datadoghq.com",
        "@yahoo.com",
        "@gmail.com"
      ]
    }
  }
}

EOF

Response

OK

Model

FieldTypeDescription
dataobjectDomain Allowlist email data
data.typeenumDomain Allowlist type. Allowed enum values: domain_allowlist. Default: domain_allowlist.
data.attributesobjectAttributes of Domain Allowlist
data.attributes.enabledBooleanIf true, Domain Allowlist is enabled
data.attributes.domains[string]List of domains in Domain Allowlist

Forbidden

Model

FieldTypeDescription
errors [required][string]List of errors

Not Found

Model

FieldTypeDescription
errors [required][string]List of errors

Too many requests

Model

FieldTypeDescription
errors [required][string]List of errors

Example

{
  "data": {
    "type": "domain_allowlist",
    "attributes": {
      "enabled": true,
      "domains": [
        "@datadoghq.com",
        "@yahoo.com",
        "@gmail.com"
      ]
    }
  }
}

Further Reading

추가 유용한 문서, 링크 및 기사: