---
title: Update a Salesforce incident template
description: Datadog, the leading service for cloud-scale monitoring.
breadcrumbs: Docs > API Reference > Salesforce Integration
---

# Update a Salesforce incident template{% #update-a-salesforce-incident-template %}
Copy pageCopied
{% tab title="v2" %}

| Datadog site      | API endpoint                                                                                                          |
| ----------------- | --------------------------------------------------------------------------------------------------------------------- |
| ap1.datadoghq.com | PATCH https://api.ap1.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id} |
| ap2.datadoghq.com | PATCH https://api.ap2.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id} |
| app.datadoghq.eu  | PATCH https://api.datadoghq.eu/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id}      |
| app.ddog-gov.com  | PATCH https://api.ddog-gov.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id}      |
| us2.ddog-gov.com  | PATCH https://api.us2.ddog-gov.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id}  |
| app.datadoghq.com | PATCH https://api.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id}     |
| us3.datadoghq.com | PATCH https://api.us3.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id} |
| us5.datadoghq.com | PATCH https://api.us5.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates/{incident_template_id} |

### Overview

Update a single Salesforce incident template in your organization. This endpoint requires the `manage_integrations` permission.

### Arguments

#### Path Parameters

| Name                                   | Type   | Description                                 |
| -------------------------------------- | ------ | ------------------------------------------- |
| incident_template_id [*required*] | string | The ID of the Salesforce incident template. |

### Request

#### Body Data (required)

Salesforce incident template payload.

{% tab title="Model" %}

| Parent field | Field                        | Type   | Description                                                                                                       |
| ------------ | ---------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
|              | data [*required*]       | object | Salesforce incident template data for an update request.                                                          |
| data         | attributes [*required*] | object | Salesforce incident template attributes for an update request.                                                    |
| attributes   | description                  | string | Long-form description body for Salesforce incidents created from this template.                                   |
| attributes   | name                         | string | Human-readable name for this incident template.                                                                   |
| attributes   | owner_id                     | string | The Salesforce user ID that owns incidents created from this template.                                            |
| attributes   | priority                     | enum   | Priority of the Salesforce incident created from this template. Allowed enum values: `Critical,High,Moderate,Low` |
| attributes   | salesforce_org_id            | uuid   | The Datadog-assigned ID of the Salesforce organization this template belongs to.                                  |
| attributes   | subject                      | string | Subject line for Salesforce incidents created from this template.                                                 |
| data         | id [*required*]         | string | The ID of the Salesforce incident template being updated. Must match the path parameter.                          |
| data         | type [*required*]       | enum   | Salesforce incident template resource type. Allowed enum values: `salesforce-incidents-incident-template`         |

{% /tab %}

{% tab title="Example" %}

```json
{
  "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"
  }
}
```

{% /tab %}

### Response

{% tab title="200" %}
OK
{% tab title="Model" %}
Response containing a Salesforce incident template.

| Parent field | Field                        | Type   | Description                                                                                                       |
| ------------ | ---------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------- |
|              | data [*required*]       | object | Salesforce incident template data from a response.                                                                |
| data         | attributes [*required*] | object | Salesforce incident template attributes returned by the API.                                                      |
| attributes   | description                  | string | Long-form description body for Salesforce incidents created from this template.                                   |
| attributes   | name                         | string | Human-readable name for this incident template.                                                                   |
| attributes   | owner_id                     | string | The Salesforce user ID that owns incidents created from this template.                                            |
| attributes   | priority                     | enum   | Priority of the Salesforce incident created from this template. Allowed enum values: `Critical,High,Moderate,Low` |
| attributes   | salesforce_org_id            | uuid   | The Datadog-assigned ID of the Salesforce organization this template belongs to.                                  |
| attributes   | subject                      | string | Subject line for Salesforce incidents created from this template.                                                 |
| data         | id [*required*]         | string | The ID of the Salesforce incident template.                                                                       |
| data         | type [*required*]       | enum   | Salesforce incident template resource type. Allowed enum values: `salesforce-incidents-incident-template`         |

{% /tab %}

{% tab title="Example" %}

```json
{
  "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"
  }
}
```

{% /tab %}

{% /tab %}

{% tab title="400" %}
Bad Request
{% tab title="Model" %}
API error response.

| Field                    | Type     | Description       |
| ------------------------ | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |

{% /tab %}

{% tab title="Example" %}

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

{% /tab %}

{% /tab %}

{% tab title="403" %}
Forbidden
{% tab title="Model" %}
API error response.

| Field                    | Type     | Description       |
| ------------------------ | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |

{% /tab %}

{% tab title="Example" %}

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

{% /tab %}

{% /tab %}

{% tab title="404" %}
Not Found
{% tab title="Model" %}
API error response.

| Field                    | Type     | Description       |
| ------------------------ | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |

{% /tab %}

{% tab title="Example" %}

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

{% /tab %}

{% /tab %}

{% tab title="409" %}
Conflict
{% tab title="Model" %}
API error response.

| Field                    | Type     | Description       |
| ------------------------ | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |

{% /tab %}

{% tab title="Example" %}

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

{% /tab %}

{% /tab %}

{% tab title="429" %}
Too many requests
{% tab title="Model" %}
API error response.

| Field                    | Type     | Description       |
| ------------------------ | -------- | ----------------- |
| errors [*required*] | [string] | A list of errors. |

{% /tab %}

{% tab title="Example" %}

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

{% /tab %}

{% /tab %}

### Code Example

##### 
                  \## default
# 
 \# Path parameters export incident_template_id="CHANGE_ME" \# Curl command curl -X PATCH "https://api.datadoghq.com/api/v2/integration/salesforce-incidents/incident-templates/${incident_template_id}" \
-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": {
      "name": "production-outage-renamed"
    },
    "id": "596da4af-0563-4097-90ff-07230c3f9db3",
    "type": "salesforce-incidents-incident-template"
  }
}
EOF 
                
{% /tab %}
