Update an incoming e-mail integration

Update an e-mail integration's channels, escalation policy, or extraction. Only provide the fields you want to change. An extraction field or list you send replaces the current one.

PATCH https://incidents.betterstack.com/api/v3/incoming-email-integrations/{id}

URL parameters

id
required string

Query parameters

team_id
string

Headers

Authorization
required string
Content-Type
string

Body parameters

name
string or null
escalation_policy_id
string or null
paused
boolean
call
boolean
sms
boolean
email
boolean
push
boolean
critical_alert
boolean
team_wait
integer or null
recovery_period
integer
started_rule_type
string
acknowledged_rule_type
string
resolved_rule_type
string
cause_field
object or null
cause_field.name
string or null
cause_field.special_type
string or null
cause_field.field_target
required string
cause_field.match_type
required string
cause_field.content
string or null
cause_field.content_before
string or null
cause_field.content_after
string or null
title_field
object or null
started_alert_id_field
object or null
acknowledged_alert_id_field
object or null
resolved_alert_id_field
object or null
other_started_fields
array of objects or null
other_started_fields[].name
required string or null
other_started_fields[].special_type
string or null
other_started_fields[].field_target
required string
other_started_fields[].match_type
required string
other_started_fields[].content
string or null
other_started_fields[].content_before
string or null
other_started_fields[].content_after
string or null
other_acknowledged_fields
array of objects or null
other_acknowledged_fields[].name
required string or null
other_acknowledged_fields[].special_type
string or null
other_acknowledged_fields[].field_target
required string
other_acknowledged_fields[].match_type
required string
other_acknowledged_fields[].content
string or null
other_acknowledged_fields[].content_before
string or null
other_acknowledged_fields[].content_after
string or null
other_resolved_fields
array of objects or null
other_resolved_fields[].name
required string or null
other_resolved_fields[].special_type
string or null
other_resolved_fields[].field_target
required string
other_resolved_fields[].match_type
required string
other_resolved_fields[].content
string or null
other_resolved_fields[].content_before
string or null
other_resolved_fields[].content_after
string or null
started_rules
array of objects
started_rules[].rule_target
required string
started_rules[].match_type
required string
started_rules[].content
required string
acknowledged_rules
array of objects
resolved_rules
array of objects
metadata
object
metadata.<key>[].type
string
metadata.<key>[].value
string
metadata.<key>[].item_id
string
metadata.<key>[].name
string or null
metadata.<key>[].email
string
200

Response body

{
  "data": {
    "id": "123456789",
    "type": "email_integration",
    "attributes": {
      "name": "Production e-mail alerts",
      "escalation_policy_id": "73",
      "email_address": "pdqshpdxj3@incidents.uptime.betterstack.com",
      "paused": false,
      "call": false,
      "sms": false,
      "email": true,
      "push": true,
      "critical_alert": false,
      "team_wait": 180,
      "recovery_period": 0,
      "started_rule_type": "any",
      "acknowledged_rule_type": "any",
      "resolved_rule_type": "any",
      "cause_field": {
        "name": null,
        "special_type": "cause",
        "field_target": "subject",
        "match_type": "match_everything",
        "content": null,
        "content_before": null,
        "content_after": null
      },
      "title_field": {
        "name": null,
        "special_type": "title",
        "field_target": "subject",
        "match_type": "match_after",
        "content": "Alert: ",
        "content_before": null,
        "content_after": null
      },
      "started_alert_id_field": {
        "name": null,
        "special_type": "alert_id",
        "field_target": "body",
        "match_type": "match_between",
        "content": null,
        "content_before": "Alert ID: ",
        "content_after": "\n"
      },
      "acknowledged_alert_id_field": {
        "name": null,
        "special_type": "alert_id",
        "field_target": "body",
        "match_type": "match_between",
        "content": null,
        "content_before": "Alert ID: ",
        "content_after": "\n"
      },
      "resolved_alert_id_field": {
        "name": null,
        "special_type": "alert_id",
        "field_target": "body",
        "match_type": "match_between",
        "content": null,
        "content_before": "Alert ID: ",
        "content_after": "\n"
      },
      "other_started_fields": [
        {
          "name": "Service",
          "special_type": null,
          "field_target": "body",
          "match_type": "match_regex",
          "content": "Service: (\\w+)",
          "content_before": null,
          "content_after": null
        }
      ],
      "other_acknowledged_fields": [
        {
          "name": "Service",
          "special_type": null,
          "field_target": "body",
          "match_type": "match_regex",
          "content": "Service: (\\w+)",
          "content_before": null,
          "content_after": null
        }
      ],
      "other_resolved_fields": [
        {
          "name": "Service",
          "special_type": null,
          "field_target": "body",
          "match_type": "match_regex",
          "content": "Service: (\\w+)",
          "content_before": null,
          "content_after": null
        }
      ],
      "started_rules": [
        {
          "rule_target": "subject",
          "match_type": "contains",
          "content": "[FIRING]"
        }
      ],
      "acknowledged_rules": [
        {
          "rule_target": "subject",
          "match_type": "contains",
          "content": "[ACKNOWLEDGED]"
        }
      ],
      "resolved_rules": [
        {
          "rule_target": "subject",
          "match_type": "contains",
          "content": "[RESOLVED]"
        }
      ],
      "created_at": "2026-09-09T10:06:12.418Z",
      "updated_at": "2026-09-09T10:06:31.902Z",
      "team_id": "t123",
      "team_name": "Production",
      "metadata": {
        "Service": [
          {
            "type": "String",
            "value": "Checkout"
          }
        ]
      }
    }
  }
}
401

Response body

{
  "errors": "Invalid Team API token. How to find your Team API token: https://betterstack.com/docs/uptime/api/getting-started-with-uptime-api/#get-an-incidents-api-token"
}
403

Response body

{
  "errors": "This API token is read-only and cannot be used for write operations."
}
404
422

Response body

{
  "errors": "Please upgrade your account before using these attributes",
  "unauthorized_attributes": [
    "escalation_policy_id"
  ]
}

Response attributes

id
string
type
string
name
string or null
escalation_policy_id
string or null
email_address
string
paused
boolean
call
boolean
sms
boolean
email
boolean
push
boolean
critical_alert
boolean
team_wait
integer or null
recovery_period
integer
started_rule_type
string
acknowledged_rule_type
string
resolved_rule_type
string
cause_field
object or null
cause_field.name
string or null
cause_field.special_type
string or null
cause_field.field_target
string
cause_field.match_type
string
cause_field.content
string or null
cause_field.content_before
string or null
cause_field.content_after
string or null
title_field
object or null
started_alert_id_field
object or null
acknowledged_alert_id_field
object or null
resolved_alert_id_field
object or null
other_started_fields
array of objects or null
other_started_fields[].name
string or null
other_started_fields[].special_type
string or null
other_started_fields[].field_target
string
other_started_fields[].match_type
string
other_started_fields[].content
string or null
other_started_fields[].content_before
string or null
other_started_fields[].content_after
string or null
other_acknowledged_fields
array of objects or null
other_acknowledged_fields[].name
string or null
other_acknowledged_fields[].special_type
string or null
other_acknowledged_fields[].field_target
string
other_acknowledged_fields[].match_type
string
other_acknowledged_fields[].content
string or null
other_acknowledged_fields[].content_before
string or null
other_acknowledged_fields[].content_after
string or null
other_resolved_fields
array of objects or null
other_resolved_fields[].name
string or null
other_resolved_fields[].special_type
string or null
other_resolved_fields[].field_target
string
other_resolved_fields[].match_type
string
other_resolved_fields[].content
string or null
other_resolved_fields[].content_before
string or null
other_resolved_fields[].content_after
string or null
started_rules
array of objects
started_rules[].rule_target
string
started_rules[].match_type
string
started_rules[].content
string
started_rules[].created_at
datetime
started_rules[].updated_at
datetime
acknowledged_rules
array of objects
resolved_rules
array of objects
created_at
datetime
updated_at
datetime
team_id
string
team_name
string
metadata
object
metadata.<key>[].type
string
metadata.<key>[].value
string
metadata.<key>[].item_id
string
metadata.<key>[].name
string or null
metadata.<key>[].email
string

Example cURL

Update an incoming e-mail integration
curl --request PATCH \
  --url https://incidents.betterstack.com/api/v3/incoming-email-integrations/13755 \
  --header "Authorization: Bearer $TOKEN" \
  --header "Content-Type: application/json" \
  --data '{
  "name": "Production e-mail alerts"
}'