{
  "name": "Sales intelligence - operational error handler",
  "nodes": [
    {
      "id": "e41dfee2-43f0-5016-b397-d907bf8e5109",
      "name": "Production failure",
      "type": "n8n-nodes-base.errorTrigger",
      "typeVersion": 1,
      "position": [
        0,
        0
      ],
      "parameters": {}
    },
    {
      "id": "884e450e-a620-5a2a-a3d2-01d5e1e6be5f",
      "name": "Record failure and alert administrator",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.5,
      "position": [
        300,
        0
      ],
      "parameters": {
        "method": "POST",
        "url": "http://digest-service:8080/v1/alert",
        "authentication": "genericCredentialType",
        "genericAuthType": "httpTemplatedCustomAuth",
        "sendBody": true,
        "contentType": "json",
        "specifyBody": "json",
        "jsonBody": "={{ JSON.stringify({ run_id: \"n8n:\" + ($json.execution?.id || \"trigger\"), stage: \"n8n_execution\" }) }}",
        "options": {
          "timeout": 300000,
          "response": {
            "response": {
              "responseFormat": "json"
            }
          },
          "redirect": {
            "redirect": {
              "followRedirects": false
            }
          }
        }
      },
      "credentials": {
        "httpTemplatedCustomAuth": {
          "name": "Digest service - configure Bearer token"
        }
      },
      "retryOnFail": true,
      "maxTries": 3,
      "waitBetweenTries": 5000
    }
  ],
  "connections": {
    "Production failure": {
      "main": [
        [
          {
            "node": "Record failure and alert administrator",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "settings": {
    "executionOrder": "v1",
    "timezone": "Asia/Tbilisi",
    "saveDataSuccessExecution": "none",
    "saveDataErrorExecution": "none",
    "saveManualExecutions": false,
    "executionTimeout": 1800
  },
  "active": false,
  "pinData": {},
  "tags": []
}
