IP Allowlist

The IP allowlist API is used to manage the IP addresses that can access the Datadog API and web UI. It does not block access to intake APIs or public dashboards.

This is an enterprise-only feature. Request access by contacting Datadog support, or see the IP Allowlist page for more information.

GET https://api.ap1.datadoghq.com/api/v2/ip_allowlisthttps://api.datadoghq.eu/api/v2/ip_allowlisthttps://api.ddog-gov.com/api/v2/ip_allowlisthttps://api.datadoghq.com/api/v2/ip_allowlisthttps://api.us3.datadoghq.com/api/v2/ip_allowlisthttps://api.us5.datadoghq.com/api/v2/ip_allowlist

Información general

Returns the IP allowlist and its enabled or disabled state. This endpoint requires the org_management permission.

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

Respuesta

OK

Response containing information about the IP allowlist.

Expand All

Campo

Tipo

Descripción

data

object

IP allowlist data.

attributes

object

Attributes of the IP allowlist.

enabled

boolean

Whether the IP allowlist logic is enabled or not.

entries

[object]

Array of entries in the IP allowlist.

data [required]

object

Data of the IP allowlist entry object.

attributes

object

Attributes of the IP allowlist entry.

cidr_block

string

The CIDR block describing the IP range of the entry.

created_at

date-time

Creation time of the entry.

modified_at

date-time

Time of last entry modification.

note

string

A note describing the IP allowlist entry.

id

string

The unique identifier of the IP allowlist entry.

type [required]

enum

IP allowlist Entry type. Allowed enum values: ip_allowlist_entry

default: ip_allowlist_entry

id

string

The unique identifier of the org.

type [required]

enum

IP allowlist type. Allowed enum values: ip_allowlist

default: ip_allowlist

{
  "data": {
    "attributes": {
      "enabled": false,
      "entries": [
        {
          "data": {
            "attributes": {
              "cidr_block": "string",
              "created_at": "2019-09-19T10:00:00.000Z",
              "modified_at": "2019-09-19T10:00:00.000Z",
              "note": "string"
            },
            "id": "string",
            "type": "ip_allowlist_entry"
          }
        }
      ]
    },
    "id": "string",
    "type": "ip_allowlist"
  }
}

Forbidden

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Not Found

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Too many requests

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Ejemplo de código

                  # Curl command
curl -X GET "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/v2/ip_allowlist" \ -H "Accept: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}"

PATCH https://api.ap1.datadoghq.com/api/v2/ip_allowlisthttps://api.datadoghq.eu/api/v2/ip_allowlisthttps://api.ddog-gov.com/api/v2/ip_allowlisthttps://api.datadoghq.com/api/v2/ip_allowlisthttps://api.us3.datadoghq.com/api/v2/ip_allowlisthttps://api.us5.datadoghq.com/api/v2/ip_allowlist

Información general

Edit the entries in the IP allowlist, and enable or disable it. This endpoint requires the org_management permission.

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

Solicitud

Body Data (required)

Expand All

Campo

Tipo

Descripción

data [required]

object

IP allowlist data.

attributes

object

Attributes of the IP allowlist.

enabled

boolean

Whether the IP allowlist logic is enabled or not.

entries

[object]

Array of entries in the IP allowlist.

data [required]

object

Data of the IP allowlist entry object.

attributes

object

Attributes of the IP allowlist entry.

cidr_block

string

The CIDR block describing the IP range of the entry.

created_at

date-time

Creation time of the entry.

modified_at

date-time

Time of last entry modification.

note

string

A note describing the IP allowlist entry.

id

string

The unique identifier of the IP allowlist entry.

type [required]

enum

IP allowlist Entry type. Allowed enum values: ip_allowlist_entry

default: ip_allowlist_entry

id

string

The unique identifier of the org.

type [required]

enum

IP allowlist type. Allowed enum values: ip_allowlist

default: ip_allowlist

{
  "data": {
    "attributes": {
      "entries": [
        {
          "data": {
            "attributes": {
              "note": "Example-IP-Allowlist",
              "cidr_block": "127.0.0.1"
            },
            "type": "ip_allowlist_entry"
          }
        }
      ],
      "enabled": false
    },
    "type": "ip_allowlist"
  }
}

Respuesta

OK

Response containing information about the IP allowlist.

Expand All

Campo

Tipo

Descripción

data

object

IP allowlist data.

attributes

object

Attributes of the IP allowlist.

enabled

boolean

Whether the IP allowlist logic is enabled or not.

entries

[object]

Array of entries in the IP allowlist.

data [required]

object

Data of the IP allowlist entry object.

attributes

object

Attributes of the IP allowlist entry.

cidr_block

string

The CIDR block describing the IP range of the entry.

created_at

date-time

Creation time of the entry.

modified_at

date-time

Time of last entry modification.

note

string

A note describing the IP allowlist entry.

id

string

The unique identifier of the IP allowlist entry.

type [required]

enum

IP allowlist Entry type. Allowed enum values: ip_allowlist_entry

default: ip_allowlist_entry

id

string

The unique identifier of the org.

type [required]

enum

IP allowlist type. Allowed enum values: ip_allowlist

default: ip_allowlist

{
  "data": {
    "attributes": {
      "enabled": false,
      "entries": [
        {
          "data": {
            "attributes": {
              "cidr_block": "string",
              "created_at": "2019-09-19T10:00:00.000Z",
              "modified_at": "2019-09-19T10:00:00.000Z",
              "note": "string"
            },
            "id": "string",
            "type": "ip_allowlist_entry"
          }
        }
      ]
    },
    "id": "string",
    "type": "ip_allowlist"
  }
}

Bad Request

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Forbidden

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Not Found

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Too many requests

API error response.

Expand All

Campo

Tipo

Descripción

errors [required]

[string]

A list of errors.

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

Ejemplo de código

                          # Curl command
curl -X PATCH "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/v2/ip_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": { "attributes": { "entries": [ { "data": { "attributes": { "note": "Example-IP-Allowlist", "cidr_block": "127.0.0.1" }, "type": "ip_allowlist_entry" } } ], "enabled": false }, "type": "ip_allowlist" } } EOF

PREVIEWING: emmett.butler/dd-trace-api