Skip to main content
PUT
/
v1
/
alert_sources
/
{id}
Update an alert source
curl --request PUT \
  --url https://api.rootly.com/v1/alert_sources/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/vnd.api+json' \
  --data '
{
  "data": {
    "type": "alert_sources",
    "attributes": {
      "name": "<string>",
      "source_type": "email",
      "alert_urgency_id": "<string>",
      "deduplicate_alerts_by_key": true,
      "deduplication_key_kind": "payload",
      "deduplication_key_path": "<string>",
      "deduplication_key_regexp": "<string>",
      "owner_group_ids": [
        "<string>"
      ],
      "alert_template_attributes": {
        "title": "<string>",
        "description": "<string>",
        "external_url": "<string>"
      },
      "alert_source_urgency_rules_attributes": [
        {
          "json_path": "<string>",
          "operator": "is",
          "value": "<string>",
          "conditionable_type": "AlertField",
          "conditionable_id": "<string>",
          "kind": "payload",
          "alert_urgency_id": "<string>"
        }
      ],
      "sourceable_attributes": {
        "auto_resolve": true,
        "resolve_state": "<string>",
        "accept_threaded_emails": true,
        "field_mappings_attributes": [
          {
            "field": "external_id",
            "json_path": "<string>"
          }
        ]
      },
      "resolution_rule_attributes": {
        "enabled": true,
        "condition_type": "all",
        "identifier_matchable_type": "AlertField",
        "identifier_matchable_id": "<string>",
        "identifier_reference_kind": "payload",
        "identifier_json_path": "<string>",
        "identifier_value_regex": "<string>",
        "conditions_attributes": [
          {
            "field": "<string>",
            "operator": "is",
            "value": "<string>",
            "conditionable_type": "AlertField",
            "conditionable_id": "<string>",
            "kind": "payload"
          }
        ]
      },
      "alert_source_fields_attributes": [
        {
          "alert_field_id": "<string>",
          "template_body": "<string>"
        }
      ]
    }
  }
}
'
{
  "data": {
    "id": "5f6bc062-f18e-4135-aec7-ce3d0914a214",
    "type": "alert_sources",
    "attributes": {
      "name": "GW 2",
      "source_type": "generic_webhook",
      "status": "setup_incomplete",
      "secret": "ab7faf3b60a3c2125dc5f7eb99075a1a4dc214e51c3d01facee5b8ca9825a2f9",
      "alert_urgency_id": "74031304-7d5f-4ffe-a66a-e98398f07909",
      "created_at": "2026-02-11T15:06:21.879-08:00",
      "updated_at": "2026-02-11T15:06:21.995-08:00",
      "webhook_endpoint": "http://localhost:3001/webhooks/incoming/generic_webhooks/notify/<TYPE>/<ID>",
      "owner_group_ids": [],
      "alert_source_urgency_rules_attributes": [
        {
          "id": "aa7132df-a2cf-4f66-9de1-8aafb7aa821b",
          "json_path": "$.alert.status",
          "operator": "is",
          "value": "Critical",
          "alert_urgency_id": "35f966c3-4fcc-4d73-bafd-798f1992003e",
          "alerts_source_id": "5f6bc062-f18e-4135-aec7-ce3d0914a214",
          "created_at": "2026-02-11T15:06:21.996-08:00",
          "updated_at": "2026-02-11T15:06:21.996-08:00",
          "conditionable_type": null,
          "conditionable_id": null,
          "kind": "payload"
        }
      ],
      "alert_source_fields_attributes": [
        {
          "template_body": null,
          "created_at": "2026-02-11T15:06:21.886-08:00",
          "updated_at": "2026-02-11T15:06:21.886-08:00",
          "alert_field_id": "94ceac1f-b60a-4eee-9369-1fb6943222a5",
          "alert_field": {
            "id": "94ceac1f-b60a-4eee-9369-1fb6943222a5",
            "slug": "description-field",
            "name": "Description Field",
            "kind": "description",
            "created_at": "2026-02-11T15:06:18.053-08:00",
            "updated_at": "2026-02-11T15:06:18.053-08:00"
          }
        },
        {
          "template_body": null,
          "created_at": "2026-02-11T15:06:21.893-08:00",
          "updated_at": "2026-02-11T15:06:21.893-08:00",
          "alert_field_id": "d0bb6b30-8b9a-4267-b6e1-4712b0e5ee25",
          "alert_field": {
            "id": "d0bb6b30-8b9a-4267-b6e1-4712b0e5ee25",
            "slug": "external-url-field",
            "name": "External URL Field",
            "kind": "external_url",
            "created_at": "2026-02-11T15:06:18.065-08:00",
            "updated_at": "2026-02-11T15:06:18.065-08:00"
          }
        },
        {
          "template_body": null,
          "created_at": "2026-02-11T15:06:21.900-08:00",
          "updated_at": "2026-02-11T15:06:21.900-08:00",
          "alert_field_id": "cb84eee9-557a-4afd-96f2-48642ffc0a11",
          "alert_field": {
            "id": "cb84eee9-557a-4afd-96f2-48642ffc0a11",
            "slug": "title-field",
            "name": "Title Field",
            "kind": "title",
            "created_at": "2026-02-11T15:06:18.046-08:00",
            "updated_at": "2026-02-11T15:06:18.046-08:00"
          }
        }
      ],
      "sourceable_attributes": {
        "id": "86dfe3b9-9993-473e-80fc-89a834a218cc",
        "auto_resolve": false,
        "resolve_state": null,
        "created_at": "2026-02-11T15:06:21.860-08:00",
        "updated_at": "2026-02-11T15:06:21.860-08:00",
        "field_mappings_attributes": [],
        "field_mappings": []
      },
      "alert_template_attributes": null,
      "resolution_rule_attributes": null
    },
    "relationships": {
      "alert_source_urgency_rules": {
        "data": [
          {
            "id": "aa7132df-a2cf-4f66-9de1-8aafb7aa821b",
            "alert_urgency_id": "35f966c3-4fcc-4d73-bafd-798f1992003e",
            "alerts_source_id": "5f6bc062-f18e-4135-aec7-ce3d0914a214",
            "conditionable_id": null,
            "conditionable_type": null,
            "created_at": "2026-02-11T15:06:21.996-08:00",
            "deleted_at": null,
            "json_path": "$.alert.status",
            "kind": "payload",
            "operator": "is",
            "position": 1,
            "updated_at": "2026-02-11T15:06:21.996-08:00",
            "value": "Critical"
          }
        ]
      },
      "alert_source_fields": {
        "data": [
          {
            "id": "1dd86ed5-0ac1-468c-9700-bd2ee40ee6a1",
            "alert_field_id": "94ceac1f-b60a-4eee-9369-1fb6943222a5",
            "alerts_source_id": "5f6bc062-f18e-4135-aec7-ce3d0914a214",
            "created_at": "2026-02-11T15:06:21.886-08:00",
            "deleted_at": null,
            "position": 1,
            "template_body": null,
            "updated_at": "2026-02-11T15:06:21.886-08:00"
          },
          {
            "id": "95032555-04cf-40cb-9c3f-7efccc099093",
            "alert_field_id": "d0bb6b30-8b9a-4267-b6e1-4712b0e5ee25",
            "alerts_source_id": "5f6bc062-f18e-4135-aec7-ce3d0914a214",
            "created_at": "2026-02-11T15:06:21.893-08:00",
            "deleted_at": null,
            "position": 2,
            "template_body": null,
            "updated_at": "2026-02-11T15:06:21.893-08:00"
          },
          {
            "id": "7a61547b-6197-417b-a30d-7972c204731e",
            "alert_field_id": "cb84eee9-557a-4afd-96f2-48642ffc0a11",
            "alerts_source_id": "5f6bc062-f18e-4135-aec7-ce3d0914a214",
            "created_at": "2026-02-11T15:06:21.900-08:00",
            "deleted_at": null,
            "position": 3,
            "template_body": null,
            "updated_at": "2026-02-11T15:06:21.900-08:00"
          }
        ]
      }
    }
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

Body

application/vnd.api+json
data
object
required

Response

alert source updated

data
object
required