Create a Salesforce incident template

POST https://api.ap1.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templateshttps://api.ap2.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templateshttps://api.datadoghq.eu/api/v2/integration/salesforce-incidents/incident-templateshttps://api.ddog-gov.com/api/v2/integration/salesforce-incidents/incident-templateshttps://api.us2.ddog-gov.com/api/v2/integration/salesforce-incidents/incident-templateshttps://api.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templateshttps://api.us3.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templateshttps://api.us5.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates

Overview

Create a new Salesforce incident template for your organization. Template names must be unique within an organization. This endpoint requires the manage_integrations permission.

Request

Body Data (required)

Salesforce incident template payload.

Expand All

Field

Type

Description

data [required]

object

Salesforce incident template data for a create request.

attributes [required]

object

Salesforce incident template attributes for a create request.

description [required]

string

Long-form description body for Salesforce incidents created from this template.

name [required]

string

Human-readable name for this incident template. Must be unique within your organization.

owner_id [required]

string

The Salesforce user ID that owns incidents created from this template.

priority [required]

enum

Priority of the Salesforce incident created from this template. Allowed enum values: Critical,High,Moderate,Low

salesforce_org_id [required]

uuid

The Datadog-assigned ID of the Salesforce organization this template belongs to.

subject [required]

string

Subject line for Salesforce incidents created from this template.

type [required]

enum

Salesforce incident template resource type. Allowed enum values: salesforce-incidents-incident-template

default: salesforce-incidents-incident-template

{
  "data": {
    "attributes": {
      "description": "An incident was detected by Datadog monitors.",
      "name": "production-outage",
      "owner_id": "005000000000000",
      "priority": "High",
      "salesforce_org_id": "596da4af-0563-4097-90ff-07230c3f9db3",
      "subject": "Datadog Incident: Production Outage"
    },
    "type": "salesforce-incidents-incident-template"
  }
}

Response

CREATED

Response containing a Salesforce incident template.

Expand All

Field

Type

Description

data [required]

object

Salesforce incident template data from a response.

attributes [required]

object

Salesforce incident template attributes returned by the API.

description

string

Long-form description body for Salesforce incidents created from this template.

name

string

Human-readable name for this incident template.

owner_id

string

The Salesforce user ID that owns incidents created from this template.

priority

enum

Priority of the Salesforce incident created from this template. Allowed enum values: Critical,High,Moderate,Low

salesforce_org_id

uuid

The Datadog-assigned ID of the Salesforce organization this template belongs to.

subject

string

Subject line for Salesforce incidents created from this template.

id [required]

string

The ID of the Salesforce incident template.

type [required]

enum

Salesforce incident template resource type. Allowed enum values: salesforce-incidents-incident-template

default: salesforce-incidents-incident-template

{
  "data": {
    "attributes": {
      "description": "An incident was detected by Datadog monitors.",
      "name": "production-outage",
      "owner_id": "005000000000000",
      "priority": "High",
      "salesforce_org_id": "596da4af-0563-4097-90ff-07230c3f9db3",
      "subject": "Datadog Incident: Production Outage"
    },
    "id": "596da4af-0563-4097-90ff-07230c3f9db3",
    "type": "salesforce-incidents-incident-template"
  }
}

Bad Request

API error response.

Expand All

Field

Type

Description

errors [required]

[string]

A list of errors.

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

Forbidden

API error response.

Expand All

Field

Type

Description

errors [required]

[string]

A list of errors.

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

Not Found

API error response.

Expand All

Field

Type

Description

errors [required]

[string]

A list of errors.

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

Conflict

API error response.

Expand All

Field

Type

Description

errors [required]

[string]

A list of errors.

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

Too many requests

API error response.

Expand All

Field

Type

Description

errors [required]

[string]

A list of errors.

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

Code Example

                  ## default
# 

# Curl command
curl -X POST "https://api.ap1.datadoghq.com"https://api.ap2.datadoghq.com"https://api.datadoghq.eu"https://api.ddog-gov.com"https://api.us2.ddog-gov.com"https://api.datadoghq.com"https://api.us3.datadoghq.com"https://api.us5.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates" \ -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": { "description": "An incident was detected by Datadog monitors.", "name": "production-outage", "owner_id": "005000000000000", "priority": "High", "salesforce_org_id": "596da4af-0563-4097-90ff-07230c3f9db3", "subject": "Datadog Incident: Production Outage" }, "type": "salesforce-incidents-incident-template" } } EOF