Intégration PagerDuty
Rapport de recherche Datadog : Bilan sur l'adoption de l'informatique sans serveur Rapport : Bilan sur l'adoption de l'informatique sans serveur

Intégration PagerDuty

Configurez votre intégration Datadog/PagerDuty directement via l’API Datadog.

Create a new service object

POST https://api.datadoghq.comhttps://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services

Présentation

Create a new service object in the PagerDuty integration.

Requête

Body Data (required)

Create a new service object request body.

Expand All

Champ

Type

Description

service_key [required]

string

Your service key in PagerDuty.

service_name [required]

string

Your service name associated with a service key in PagerDuty.

{
  "service_key": "",
  "service_name": ""
}

Réponse

OK

PagerDuty service object name.

Expand All

Champ

Type

Description

service_name [required]

string

Your service name associated service key in PagerDuty.

{
  "service_name": ""
}

Bad Request

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Authentication error

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Exemple de code


                                        # Curl command
curl -X POST "https://api.datadoghq.com"https://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services" \
-H "Content-Type: application/json" \
-H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \
-H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}" \
-d @- << EOF
{
  "service_key": "",
  "service_name": ""
}
EOF

Delete a single service object

DELETE https://api.datadoghq.comhttps://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services/{service_name}

Présentation

Delete a single service object in the Datadog-PagerDuty integration.

Arguments

Paramètres du chemin

Nom

Type

Description

service_name [required]

string

The service name

Réponse

OK

Authentication error

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Item Not Found

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Exemple de code


                                        # Path parameters
export service_name="CHANGE_ME"
# Curl command curl -X DELETE "https://api.datadoghq.com"https://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services/${service_name}" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}"

Get a single service object

GET https://api.datadoghq.comhttps://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services/{service_name}

Présentation

Get service name in the Datadog-PagerDuty integration.

Arguments

Paramètres du chemin

Nom

Type

Description

service_name [required]

string

The service name.

Réponse

OK

PagerDuty service object name.

Expand All

Champ

Type

Description

service_name [required]

string

Your service name associated service key in PagerDuty.

{
  "service_name": ""
}

Authentication error

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Item Not Found

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Exemple de code


                                        # Path parameters
export service_name="CHANGE_ME"
# Curl command curl -X GET "https://api.datadoghq.com"https://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services/${service_name}" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}"

Update a single service object

PUT https://api.datadoghq.comhttps://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services/{service_name}

Présentation

Update a single service object in the Datadog-PagerDuty integration.

Arguments

Paramètres du chemin

Nom

Type

Description

service_name [required]

string

The service name

Requête

Body Data (required)

Update an existing service object request body.

Expand All

Champ

Type

Description

service_key [required]

string

Your service key in PagerDuty.

{
  "service_key": ""
}

Réponse

OK

Bad Request

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Authentication error

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Item Not Found

Error response object.

Expand All

Champ

Type

Description

errors [required]

[string]

Array of errors returned by the API.

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

Exemple de code


                                        # Path parameters
export service_name="CHANGE_ME"
# Curl command curl -X PUT "https://api.datadoghq.com"https://api.datadoghq.eu/api/v1/integration/pagerduty/configuration/services/${service_name}" \ -H "Content-Type: application/json" \ -H "DD-API-KEY: ${DD_CLIENT_API_KEY}" \ -H "DD-APPLICATION-KEY: ${DD_CLIENT_APP_KEY}" \ -d @- << EOF { "service_key": "" } EOF