This page is not yet available in Spanish. We are working on its translation.
If you have any questions or feedback about our current translation project, feel free to reach out to us!

Gráficos integrables

Gestiona gráficos integrables a través de la API. Para obtener más información, consulta Gráficos integrables con variables de plantilla.

GET https://api.ap1.datadoghq.com/api/v1/graph/embed/{embed_id}/revokehttps://api.datadoghq.eu/api/v1/graph/embed/{embed_id}/revokehttps://api.ddog-gov.com/api/v1/graph/embed/{embed_id}/revokehttps://api.datadoghq.com/api/v1/graph/embed/{embed_id}/revokehttps://api.us3.datadoghq.com/api/v1/graph/embed/{embed_id}/revokehttps://api.us5.datadoghq.com/api/v1/graph/embed/{embed_id}/revoke

Overview

Revoca una integración específica. This endpoint requires the dashboards_public_share permission.

Arguments

Path Parameters

Name

Type

Description

embed_id [required]

string

ID of the embed.

Response

OK

A JSON object containing the success message

Expand All

Field

Type

Description

success

string

Message.

{
  "success": "Embed 00000000000 successfully enabled."
}

Authentication Error

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Not found

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Too many requests

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Code Example

                  # Path parameters
export embed_id="CHANGE_ME"
# 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/v1/graph/embed/${embed_id}/revoke" \ -H "Accept: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}"

GET https://api.ap1.datadoghq.com/api/v1/graph/embed/{embed_id}/enablehttps://api.datadoghq.eu/api/v1/graph/embed/{embed_id}/enablehttps://api.ddog-gov.com/api/v1/graph/embed/{embed_id}/enablehttps://api.datadoghq.com/api/v1/graph/embed/{embed_id}/enablehttps://api.us3.datadoghq.com/api/v1/graph/embed/{embed_id}/enablehttps://api.us5.datadoghq.com/api/v1/graph/embed/{embed_id}/enable

Overview

Habilita una integración específica. This endpoint requires the dashboards_public_share permission.

Arguments

Path Parameters

Name

Type

Description

embed_id [required]

string

ID of the embed.

Response

OK

A JSON object containing the success message

Expand All

Field

Type

Description

success

string

Message.

{
  "success": "Embed 00000000000 successfully enabled."
}

Authentication Error

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Not found

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Too many requests

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Code Example

                  # Path parameters
export embed_id="CHANGE_ME"
# 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/v1/graph/embed/${embed_id}/enable" \ -H "Accept: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}"

GET https://api.ap1.datadoghq.com/api/v1/graph/embed/{embed_id}https://api.datadoghq.eu/api/v1/graph/embed/{embed_id}https://api.ddog-gov.com/api/v1/graph/embed/{embed_id}https://api.datadoghq.com/api/v1/graph/embed/{embed_id}https://api.us3.datadoghq.com/api/v1/graph/embed/{embed_id}https://api.us5.datadoghq.com/api/v1/graph/embed/{embed_id}

Overview

Obtener el fragmento HTML de un embed generado previamente con embed_id.

Arguments

Path Parameters

Name

Type

Description

embed_id [required]

string

Token of the embed.

Response

OK

Embeddable graph.

Expand All

Field

Type

Description

dash_name

string

Name of the dashboard the graph is on (null if none).

dash_url

string

URL of the dashboard the graph is on (null if none).

embed_id

string

ID of the embed.

graph_title

string

Title of the graph.

html

string

HTML fragment for the embed (iframe).

revoked

boolean

Boolean flag for whether or not the embed is revoked.

shared_by

int64

ID of the use who shared the embed.

{
  "dash_name": "string",
  "dash_url": "string",
  "embed_id": "string",
  "graph_title": "string",
  "html": "string",
  "revoked": false,
  "shared_by": "integer"
}

Authentication Error

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Not found

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Too many requests

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Code Example

                  # Path parameters
export embed_id="CHANGE_ME"
# 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/v1/graph/embed/${embed_id}" \ -H "Accept: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}"

POST https://api.ap1.datadoghq.com/api/v1/graph/embedhttps://api.datadoghq.eu/api/v1/graph/embedhttps://api.ddog-gov.com/api/v1/graph/embedhttps://api.datadoghq.com/api/v1/graph/embedhttps://api.us3.datadoghq.com/api/v1/graph/embedhttps://api.us5.datadoghq.com/api/v1/graph/embed

Overview

Crea un nuevo gráfico integrable.

Nota: Si ya existe una integración para la misma consulta exacta en una organización determinada, se devuelve la integración más antigua, en lugar de crear una nueva.

Si te interesa utilizar variables de plantilla, consulta Gráficos integrables con variables de plantilla.

This endpoint requires the dashboards_public_share permission.

Request

Body Data (required)

Cuerpo del gráfico integrable

Expand All

Field

Type

Description

graph_json [required]

string

The graph definition in JSON.

Same format that is available on the JSON tab of the graph editor.

legend

enum

The flag determining if the graph includes a legend. Allowed enum values: yes,no

default: no

size

enum

The size of the graph. Allowed enum values: small,medium,large,xlarge

default: medium

timeframe

enum

The timeframe for the graph. Allowed enum values: 1_hour,4_hours,1_day,2_days,1_week

default: 1_hour

title

string

Determines graph title. Must be at least 1 character.

default: Embed created through API

{
  "graph_json": "",
  "legend": "string",
  "size": "string",
  "timeframe": "string",
  "title": "string"
}

Response

Payload accepted

Embeddable graph.

Expand All

Field

Type

Description

dash_name

string

Name of the dashboard the graph is on (null if none).

dash_url

string

URL of the dashboard the graph is on (null if none).

embed_id

string

ID of the embed.

graph_title

string

Title of the graph.

html

string

HTML fragment for the embed (iframe).

revoked

boolean

Boolean flag for whether or not the embed is revoked.

shared_by

int64

ID of the use who shared the embed.

{
  "dash_name": "string",
  "dash_url": "string",
  "embed_id": "string",
  "graph_title": "string",
  "html": "string",
  "revoked": false,
  "shared_by": "integer"
}

Bad Request

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Authentication Error

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Too many requests

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Code Example

                  # Curl command
curl -X POST "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/graph/embed" \ -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 { "graph_json": "" } EOF

GET https://api.ap1.datadoghq.com/api/v1/graph/embedhttps://api.datadoghq.eu/api/v1/graph/embedhttps://api.ddog-gov.com/api/v1/graph/embedhttps://api.datadoghq.com/api/v1/graph/embedhttps://api.us3.datadoghq.com/api/v1/graph/embedhttps://api.us5.datadoghq.com/api/v1/graph/embed

Overview

Obtiene una lista de gráficos previamente creados que se pueden insertar.

Response

OK

Response with embeddable graphs.

Expand All

Field

Type

Description

embedded_graphs

[object]

List of embeddable graphs.

dash_name

string

Name of the dashboard the graph is on (null if none).

dash_url

string

URL of the dashboard the graph is on (null if none).

embed_id

string

ID of the embed.

graph_title

string

Title of the graph.

html

string

HTML fragment for the embed (iframe).

revoked

boolean

Boolean flag for whether or not the embed is revoked.

shared_by

int64

ID of the use who shared the embed.

{
  "embedded_graphs": [
    {
      "dash_name": "string",
      "dash_url": "string",
      "embed_id": "string",
      "graph_title": "string",
      "html": "string",
      "revoked": false,
      "shared_by": "integer"
    }
  ]
}

Authentication Error

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Too many requests

Error response object.

Expand All

Field

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Code Example

                  # 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/v1/graph/embed" \ -H "Accept: application/json" \ -H "DD-API-KEY: ${DD_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_APP_KEY}"