PUT
/
v1
/
alert_sources
/
{id}
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>",
      "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>"
        }
      ],
      "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_json_path": "<string>",
        "identifier_value_regex": "<string>",
        "conditions_attributes": [
          {
            "field": "<string>",
            "operator": "is",
            "value": "<string>"
          }
        ]
      },
      "alert_source_fields_attributes": [
        {
          "alert_field_id": "<string>",
          "template_body": "<string>"
        }
      ]
    }
  }
}'
{
  "data": {
    "id": "23778b2e-9090-4e2e-abe7-df0b96a2b35a",
    "type": "alert_sources",
    "attributes": {
      "name": "GW 2",
      "source_type": "generic_webhook",
      "status": "setup_incomplete",
      "secret": "8363d0b75195a0cacbc58780921f0db020ea72f8ad4dcc54316f7d8c04f6e4fd",
      "alert_urgency_id": "2b6a5a37-c2e5-4783-80a5-7ad99f5c846e",
      "created_at": "2025-06-19T02:16:49.562-07:00",
      "updated_at": "2025-06-19T02:16:49.693-07:00",
      "webhook_endpoint": "http://localhost:3001/webhooks/incoming/generic_webhooks/notify/<TYPE>/<ID>",
      "owner_group_ids": [],
      "alert_source_urgency_rules_attributes": [
        {
          "id": "fa4dcd94-a62d-4602-999b-cf8e3dac6347",
          "json_path": "$.alert.status",
          "operator": "is",
          "value": "Critical",
          "alert_urgency_id": "0270b364-5a05-4d3e-8bfb-fe0dd6b3b5ee",
          "alerts_source_id": "23778b2e-9090-4e2e-abe7-df0b96a2b35a",
          "created_at": "2025-06-19T02:16:49.694-07:00",
          "updated_at": "2025-06-19T02:16:49.694-07:00"
        }
      ],
      "alert_source_fields_attributes": [],
      "sourceable_attributes": {
        "id": "7aa425db-c50f-4cc3-bd37-7e57b7632215",
        "auto_resolve": false,
        "resolve_state": null,
        "created_at": "2025-06-19T02:16:49.550-07:00",
        "updated_at": "2025-06-19T02:16:49.550-07:00",
        "field_mappings_attributes": [],
        "field_mappings": []
      },
      "alert_template_attributes": null,
      "resolution_rule_attributes": null
    },
    "relationships": {
      "alert_source_urgency_rules": {
        "data": [
          {
            "id": "fa4dcd94-a62d-4602-999b-cf8e3dac6347",
            "alerts_source_id": "23778b2e-9090-4e2e-abe7-df0b96a2b35a",
            "alert_urgency_id": "0270b364-5a05-4d3e-8bfb-fe0dd6b3b5ee",
            "json_path": "$.alert.status",
            "operator": "is",
            "value": "Critical",
            "deleted_at": null,
            "created_at": "2025-06-19T02:16:49.694-07:00",
            "updated_at": "2025-06-19T02:16:49.694-07:00"
          }
        ]
      },
      "alert_source_fields": {
        "data": []
      }
    }
  }
}

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

Response

200
application/vnd.api+json

alert source updated

The response is of type object.