8
n8n 中文网amn8n.com

自动化依赖更新跟踪

高级

这是一个DevOps, AI Summarization领域的自动化工作流,包含 23 个节点。主要使用 If, Set, Code, Jira, Slack 等节点。 使用 GPT-4o、Slack、Jira 和 Google Sheets 进行依赖更新风险分析

前置要求
  • Slack Bot Token 或 Webhook URL
  • Google Sheets API 凭证
  • OpenAI API Key
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "id": "KplaPbnfu8G4ZiCK",
  "meta": {
    "instanceId": "8443f10082278c46aa5cf3acf8ff0f70061a2c58bce76efac814b16290845177",
    "templateCredsSetupCompleted": true
  },
  "name": "自动化依赖更新跟踪",
  "tags": [],
  "nodes": [
    {
      "id": "713381f3-700f-4a63-9d45-1fcb875c89dc",
      "name": "当点击“执行工作流”时",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        -1136,
        -16
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "b1a86cf1-b4c7-43ff-8da0-b4ca32b90744",
      "name": "便签",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        864,
        144
      ],
      "parameters": {
        "width": 288,
        "height": 384,
        "content": "## 🧩 解析 AI 响应为结构化数据"
      },
      "typeVersion": 1
    },
    {
      "id": "a340ed6c-85ca-48c5-b7ae-a0a4dd93042b",
      "name": "便签1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        384,
        432
      ],
      "parameters": {
        "width": 368,
        "height": 320,
        "content": "## ⚙️ GPT-4o 模型配置"
      },
      "typeVersion": 1
    },
    {
      "id": "b57a7811-2418-482e-94a1-bb48f79c32ba",
      "name": "便签2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        544,
        -480
      ],
      "parameters": {
        "width": 272,
        "height": 400,
        "content": "## 🧠 AI 驱动的风险评估分析器"
      },
      "typeVersion": 1
    },
    {
      "id": "45410e03-c687-4c4c-a833-42d1de6433be",
      "name": "便签3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        208,
        -432
      ],
      "parameters": {
        "width": 288,
        "height": 384,
        "content": "## 🔵 在 Slack 中提醒 DevOps 团队"
      },
      "typeVersion": 1
    },
    {
      "id": "29918ceb-631e-4463-9bb1-d40da0eb3e09",
      "name": "便签4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1248,
        160
      ],
      "parameters": {
        "width": 304,
        "height": 384,
        "content": "## 💬 将 AI 风险评估发布到 Jira 工单"
      },
      "typeVersion": 1
    },
    {
      "id": "ac6ebd0e-fc6e-4896-9a8c-75eb0d1b816a",
      "name": "便签5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -16,
        160
      ],
      "parameters": {
        "height": 464,
        "content": "## 🟠 提取相关工单元数据"
      },
      "typeVersion": 1
    },
    {
      "id": "c81ab400-953c-4860-8069-bd335fae4a55",
      "name": "便签6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -352,
        -464
      ],
      "parameters": {
        "width": 304,
        "height": 416,
        "content": "## 🔴 识别依赖更新问题"
      },
      "typeVersion": 1
    },
    {
      "id": "e5c13a32-8fb8-4a2e-b6da-c40c0cf377b7",
      "name": "便签7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -688,
        -544
      ],
      "parameters": {
        "height": 512,
        "content": "## ✅ 验证 Jira 查询响应"
      },
      "typeVersion": 1
    },
    {
      "id": "d2ce051d-8fb3-47c3-b4f0-333d75a038ae",
      "name": "便签8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -400,
        432
      ],
      "parameters": {
        "width": 304,
        "height": 336,
        "content": "## 🟡 将 Jira 查询失败记录到错误表格"
      },
      "typeVersion": 1
    },
    {
      "id": "f2107f52-9a8a-4cee-bf2e-fdd85b6ba1e2",
      "name": "便签9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -960,
        144
      ],
      "parameters": {
        "width": 304,
        "height": 336,
        "content": "## 🟣 获取所有活跃 Jira 工单"
      },
      "typeVersion": 1
    },
    {
      "id": "3f725293-56f6-43ee-9aa5-1f5cb72e065e",
      "name": "便签10",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1168,
        -752
      ],
      "parameters": {
        "width": 336,
        "height": 400,
        "content": "## 📈 将依赖更新记录到跟踪仪表板"
      },
      "typeVersion": 1
    },
    {
      "id": "16c0a63e-1eeb-4408-94f2-11e4b6b74e30",
      "name": "获取所有活跃 Jira 工单",
      "type": "n8n-nodes-base.jira",
      "position": [
        -864,
        -16
      ],
      "parameters": {
        "options": {},
        "operation": "getAll"
      },
      "credentials": {
        "jiraSoftwareCloudApi": {
          "id": "199LdjjU3PhhL8xb",
          "name": "saurabh jira"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "44a7ac98-cc74-465e-986c-e757963f64fd",
      "name": "验证 Jira 查询响应",
      "type": "n8n-nodes-base.if",
      "position": [
        -592,
        -16
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "ef3f0536-f084-4c2b-9bf6-7cd172f90035",
              "operator": {
                "type": "boolean",
                "operation": "true",
                "singleValue": true
              },
              "leftValue": "={{ $input.all().length > 0 }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "5103029f-44a5-401c-ab8a-0376fbdd8216",
      "name": "将 Jira 查询失败记录到错误表格",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -320,
        256
      ],
      "parameters": {
        "columns": {
          "value": {},
          "schema": [
            {
              "id": "error_id",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "error_id",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "error",
              "type": "string",
              "display": true,
              "removed": false,
              "required": false,
              "displayName": "error",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [
            "error_id"
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1338537721,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1Uldk_4BxWbdZTDZxFUeohIfeBmGHHqVEl9Ogb0l6R8Y/edit#gid=1338537721",
          "cachedResultName": "error log sheet"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1Uldk_4BxWbdZTDZxFUeohIfeBmGHHqVEl9Ogb0l6R8Y",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1Uldk_4BxWbdZTDZxFUeohIfeBmGHHqVEl9Ogb0l6R8Y/edit?usp=drivesdk",
          "cachedResultName": "Interviewer Brief Pack "
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "kpPEOLCGn963qpoh",
          "name": "automations@techdome.ai"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "b4b6612d-e0c1-41e6-9a16-b0a47bdbcee4",
      "name": "识别依赖更新问题",
      "type": "n8n-nodes-base.filter",
      "position": [
        -256,
        -16
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "loose"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "c5a26c9f-55d8-4368-9941-2a90ed537287",
              "operator": {
                "type": "boolean",
                "operation": "true",
                "singleValue": true
              },
              "leftValue": "=(\n  ($json.fields.summary && (\n    $json.fields.summary.toLowerCase().includes(\"update\") ||\n    $json.fields.summary.toLowerCase().includes(\"dependency\") ||\n    $json.fields.summary.toLowerCase().includes(\"bump\") ||\n    $json.fields.summary.toLowerCase().includes(\"package\") ||\n    $json.fields.summary.toLowerCase().includes(\"library\")\n  )) ||\n  ($json.fields.description && (\n    $json.fields.description.toLowerCase().includes(\"update\") ||\n    $json.fields.description.toLowerCase().includes(\"dependency\") ||\n    $json.fields.description.toLowerCase().includes(\"bump\") ||\n    $json.fields.description.toLowerCase().includes(\"package\") ||\n    $json.fields.description.toLowerCase().includes(\"library\")\n  ))\n)\n",
              "rightValue": ""
            }
          ]
        },
        "looseTypeValidation": true
      },
      "typeVersion": 2.2
    },
    {
      "id": "f3d4484f-23ad-4034-8c6e-aa006a9a28e4",
      "name": "提取相关工单元数据",
      "type": "n8n-nodes-base.set",
      "position": [
        48,
        -16
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "c7c7c164-5365-44d7-884a-0fe7a607adca",
              "name": "key",
              "type": "string",
              "value": "={{ $json.key }}"
            },
            {
              "id": "aa50207e-78bd-4eff-9fc6-1f8004a225df",
              "name": "fields.summary",
              "type": "string",
              "value": "={{ $json.fields.summary }}"
            },
            {
              "id": "2ec071da-e5da-41be-9d20-c78b391bdc97",
              "name": "fields.status",
              "type": "object",
              "value": "={{ $json.fields.status }}"
            },
            {
              "id": "14963da2-aaf5-44b3-b9c5-14bf919ee1da",
              "name": "fields.priority",
              "type": "object",
              "value": "={{ $json.fields.priority }}"
            },
            {
              "id": "92b47242-2b11-4f0c-852b-56cda94c6194",
              "name": "fields.assignee",
              "type": "object",
              "value": "={{ $json.fields.assignee }}"
            },
            {
              "id": "01721dff-85df-4376-93d6-55c549085c41",
              "name": "fields.created",
              "type": "string",
              "value": "={{ $json.fields.created }}"
            },
            {
              "id": "c470eb6c-b48f-43bd-97dc-2b35832fb956",
              "name": "fields.issuelinks",
              "type": "array",
              "value": "={{ $json.fields.issuelinks }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "ffb64563-2919-4c1d-845c-7dc6e4b19506",
      "name": "在 Slack 中提醒 DevOps 团队",
      "type": "n8n-nodes-base.slack",
      "position": [
        320,
        -16
      ],
      "webhookId": "ddaa7632-9e35-4bd3-82d6-572d5cae84cc",
      "parameters": {
        "text": "=*New Dependency Update Found in Jira!*\n*Issue:* {{ $json.fields.summary }}\n*Key:* {{$json[\"key\"]}}\n*Status:* {{$json[\"fields\"][\"status\"][\"name\"]}}\n*Priority:* {{$json[\"fields\"][\"priority\"][\"name\"]}}\n*Assignee:* {{$json[\"fields\"][\"assignee\"][\"displayName\"]}}\n*URL:* {{$json[\"fields\"][\"status\"][\"self\"].replace(\"/rest/api/2/status/\" + $json[\"fields\"][\"status\"][\"id\"], \"/browse/\" + $json[\"key\"])}}\n*Created:* {{$json[\"fields\"][\"created\"]}}",
        "user": {
          "__rl": true,
          "mode": "list",
          "value": "U09HMPVD466",
          "cachedResultName": "newscctv22"
        },
        "select": "user",
        "otherOptions": {}
      },
      "credentials": {
        "slackApi": {
          "id": "rNqvWj9TfChPVRYY",
          "name": "Slack account vivek"
        }
      },
      "typeVersion": 2.3
    },
    {
      "id": "83956de1-806c-4022-82d3-b61ee76bf685",
      "name": "AI 驱动的风险评估分析器",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        576,
        -16
      ],
      "parameters": {
        "text": "=You are Techdome’s AI DevOps assistant.\nAnalyze this Jira issue update and assign a risk level (Low, Medium, High) with a short reasoning.\n\nHere’s the issue data in JSON:\n{{ JSON.stringify($json) }}\n\nReturn the response only in this JSON format:\n{\n  \"risk_level\": \"\",\n  \"impact_summary\": \"\"\n}\n",
        "options": {
          "systemMessage": "="
        },
        "promptType": "define"
      },
      "typeVersion": 2.1
    },
    {
      "id": "5320a5e4-a76f-4a2b-ad4e-d6233ac6b047",
      "name": "GPT-4o 语言模型配置",
      "type": "@n8n/n8n-nodes-langchain.lmChatAzureOpenAi",
      "position": [
        496,
        288
      ],
      "parameters": {
        "model": "gpt-4o",
        "options": {}
      },
      "credentials": {
        "azureOpenAiApi": {
          "id": "C3WzT18XqF8OdVM6",
          "name": "Azure Open AI account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "74e29a6b-182b-425f-8969-861ddf2becff",
      "name": "解析 AI 响应为结构化数据",
      "type": "n8n-nodes-base.code",
      "position": [
        976,
        -16
      ],
      "parameters": {
        "jsCode": "return items.map(item => {\n  try {\n    const parsed = JSON.parse(item.json.output.replace(/```json|```/g, \"\").trim());\n    return {\n      json: {\n        ...item.json,\n        risk_level: parsed.risk_level,\n        impact_summary: parsed.impact_summary\n      }\n    };\n  } catch (error) {\n    return {\n      json: {\n        ...item.json,\n        risk_level: \"Unknown\",\n        impact_summary: \"Failed to parse AI output\"\n      }\n    };\n  }\n});\n"
      },
      "typeVersion": 2
    },
    {
      "id": "5fa12a2e-d3c5-496b-820d-d4dad8d9485a",
      "name": "将 AI 风险评估发布到 Jira 工单",
      "type": "n8n-nodes-base.jira",
      "position": [
        1312,
        -16
      ],
      "parameters": {
        "comment": "=🤖 *AI Risk Assessment Report*  *Risk Level:* {{$json[\"risk_level\"]}}   *Impact Summary:* {{$json[\"impact_summary\"]}}  ✅ *Next Steps:*   - [ ] Review dependency changelog   - [ ] Run regression tests   - [ ] Verify compatibility with core modules   - [ ] QA sign-off before merge",
        "options": {},
        "issueKey": "={{ $('Extract Relevant Issue Metadata').item.json.key }}",
        "resource": "issueComment"
      },
      "credentials": {
        "jiraSoftwareCloudApi": {
          "id": "199LdjjU3PhhL8xb",
          "name": "saurabh jira"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "04aead69-71ed-4dd0-90d8-f4a0dcb09000",
      "name": "将依赖更新记录到跟踪仪表板",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1312,
        -320
      ],
      "parameters": {
        "columns": {
          "value": {
            "Key": "={{ $('Extract Relevant Issue Metadata').item.json.key }}",
            "Date": "={{$now}}",
            "Status": "={{ $('Extract Relevant Issue Metadata').item.json.fields.status }}",
            "Summary": "={{ $('Extract Relevant Issue Metadata').item.json.fields.summary }}",
            "Assignee": "={{ $('Extract Relevant Issue Metadata').item.json.fields.assignee }}",
            "Risk Level": "={{ $json.risk_level }}",
            "Impact Summary": "={{ $json.impact_summary }}"
          },
          "schema": [
            {
              "id": "Date",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Date",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Key",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Key",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Summary",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Summary",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Risk Level",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Risk Level",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Impact Summary",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Impact Summary",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Assignee",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Assignee",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Status",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Status",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": 1144654801,
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1Uldk_4BxWbdZTDZxFUeohIfeBmGHHqVEl9Ogb0l6R8Y/edit#gid=1144654801",
          "cachedResultName": "Automated Dependency Update Tracking"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1Uldk_4BxWbdZTDZxFUeohIfeBmGHHqVEl9Ogb0l6R8Y",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1Uldk_4BxWbdZTDZxFUeohIfeBmGHHqVEl9Ogb0l6R8Y/edit?usp=drivesdk",
          "cachedResultName": "Interviewer Brief Pack "
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "id": "kpPEOLCGn963qpoh",
          "name": "automations@techdome.ai"
        }
      },
      "typeVersion": 4.6
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "ad77cf1a-4cea-497d-81f5-c22142cc0bd0",
  "connections": {
    "Alert DevOps Team in Slack": {
      "main": [
        [
          {
            "node": "AI-Powered Risk Assessment Analyzer",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch All Active Jira Issues": {
      "main": [
        [
          {
            "node": "Validate Jira Query Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Validate Jira Query Response": {
      "main": [
        [
          {
            "node": "Identify Dependency Update Issues ",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Log Jira Query Failures to Error Sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Relevant Issue Metadata": {
      "main": [
        [
          {
            "node": "Alert DevOps Team in Slack",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Identify Dependency Update Issues ": {
      "main": [
        [
          {
            "node": "Extract Relevant Issue Metadata",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI-Powered Risk Assessment Analyzer": {
      "main": [
        [
          {
            "node": " Parse AI Response to Structured Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "GPT-4o Language Model Configuration": {
      "ai_languageModel": [
        [
          {
            "node": "AI-Powered Risk Assessment Analyzer",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "When clicking ‘Execute workflow’": {
      "main": [
        [
          {
            "node": "Fetch All Active Jira Issues",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    " Parse AI Response to Structured Data": {
      "main": [
        [
          {
            "node": "Post AI Risk Assessment to Jira Ticket",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log Dependency Updates to Tracking Dashboard",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Post AI Risk Assessment to Jira Ticket": {
      "main": [
        []
      ]
    }
  }
}
常见问题

如何使用这个工作流?

复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。

这个工作流适合什么场景?

高级 - 开发运维, AI 摘要总结

需要付费吗?

本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。

工作流信息
难度等级
高级
节点数量23
分类2
节点类型11
难度说明

适合高级用户,包含 16+ 个节点的复杂工作流

作者
Rahul Joshi

Rahul Joshi

@rahul08

Rahul Joshi is a seasoned technology leader specializing in the n8n automation tool and AI-driven workflow automation. With deep expertise in building open-source workflow automation and self-hosted automation platforms, he helps organizations eliminate manual processes through intelligent n8n ai agent automation solutions.

外部链接
在 n8n.io 查看

分享此工作流