AWS 自动化 SSL/TLS 证书过期报告
高级
这是一个AI Summarization, Multimodal AI领域的自动化工作流,包含 23 个节点。主要使用 Set, Code, Slack, SendGrid, GoogleDrive 等节点。 使用 AWS ACM 和 AI 为 Slack 和邮件生成 SSL/TLS 证书过期报告
前置要求
- •Slack Bot Token 或 Webhook URL
- •Google Drive API 凭证
- •可能需要目标 API 的认证凭证
- •AWS Access Key 和 Secret
- •OpenAI API Key
使用的节点 (23)
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "TK91m9bEjdq5Nlgu",
"meta": {
"instanceId": "4a2e6764ba7a6bc9890d9225f4b21d570ce88fc9bd57549c89057fcee58fed0f",
"templateCredsSetupCompleted": true
},
"name": "AWS 自动化 SSL/TLS 证书过期报告",
"tags": [
{
"id": "ZWDTpzMgM2j0ZGMO",
"name": "acm",
"createdAt": "2025-08-20T04:24:13.252Z",
"updatedAt": "2025-08-20T04:24:13.252Z"
},
{
"id": "hvp6nueQ4hpIJWbY",
"name": "aws",
"createdAt": "2025-08-17T05:47:27.209Z",
"updatedAt": "2025-08-17T05:47:27.209Z"
}
],
"nodes": [
{
"id": "72c7e0a7-e1bf-40da-b946-f7bc2261bbae",
"name": "获取多个证书",
"type": "n8n-nodes-base.awsCertificateManager",
"position": [
224,
48
],
"parameters": {
"options": {},
"operation": "getMany"
},
"credentials": {
"aws": {
"id": "IZYsJuHhfVJ3PIrC",
"name": "ap-southeast-1"
}
},
"typeVersion": 1
},
{
"id": "8de106a8-5abb-4194-9179-b3310cd99ede",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1136,
-800
],
"parameters": {
"color": 4,
"width": 928,
"height": 2080,
"content": "# AWS 自动化 SSL/TLS 证书过期报告"
},
"typeVersion": 1
},
{
"id": "cdd46941-248b-4f54-8bb1-6be5e6147d95",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-96,
240
],
"parameters": {
"width": 272,
"content": "### 1. ⏰ 每周计划触发器"
},
"typeVersion": 1
},
{
"id": "2ccee042-087a-44e2-8682-c005948885d4",
"name": "便签2",
"type": "n8n-nodes-base.stickyNote",
"position": [
112,
-160
],
"parameters": {
"width": 272,
"content": "### 2. 📥 检索 ACM 证书"
},
"typeVersion": 1
},
{
"id": "2307a17b-c03d-494a-91ce-e16122cd6886",
"name": "便签3",
"type": "n8n-nodes-base.stickyNote",
"position": [
256,
240
],
"parameters": {
"width": 352,
"content": "### 3. 🧮 解析和格式化证书数据"
},
"typeVersion": 1
},
{
"id": "ccc49d5b-c69a-4b4e-918a-bd758a9adf8c",
"name": "便签说明4",
"type": "n8n-nodes-base.stickyNote",
"position": [
656,
-464
],
"parameters": {
"width": 304,
"content": "### 4. 📝 生成 Markdown 报告"
},
"typeVersion": 1
},
{
"id": "929c84a2-d3d0-4acf-9034-b7754d8e1fea",
"name": "便签说明5",
"type": "n8n-nodes-base.stickyNote",
"position": [
656,
624
],
"parameters": {
"width": 304,
"height": 144,
"content": "### 5. 🗂️ 将 Markdown 转换为 PDF"
},
"typeVersion": 1
},
{
"id": "c4e22b44-9389-4886-a76c-ea38726ad617",
"name": "便签 6",
"type": "n8n-nodes-base.stickyNote",
"position": [
1552,
192
],
"parameters": {
"width": 912,
"height": 240,
"content": ""
},
"typeVersion": 1
},
{
"id": "dbfbb8b8-e683-4f8e-9566-e1a45e5442e1",
"name": "便签 7",
"type": "n8n-nodes-base.stickyNote",
"position": [
1120,
528
],
"parameters": {
"width": 400,
"height": 112,
"content": "### 7. 📧 发送每周电子邮件摘要"
},
"typeVersion": 1
},
{
"id": "f4bdc2d2-bc98-4eca-9886-1dd303091150",
"name": "每周计划触发器",
"type": "n8n-nodes-base.scheduleTrigger",
"position": [
0,
48
],
"parameters": {
"rule": {
"interval": [
{
"field": "weeks",
"triggerAtDay": [
1
]
}
]
}
},
"typeVersion": 1.2
},
{
"id": "a736e395-58bb-4263-b42d-aded26afc6b2",
"name": "OpenAI 聊天模型",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
768,
472
],
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-5-mini",
"cachedResultName": "gpt-5-mini"
},
"options": {}
},
"credentials": {
"openAiApi": {
"id": "PPSwAKeLQYgAPobT",
"name": "OpenAi account"
}
},
"typeVersion": 1.2
},
{
"id": "bca5adc0-9afe-4a4f-ac72-30501fd2b0d8",
"name": "解析 ACM 数据",
"type": "n8n-nodes-base.code",
"position": [
448,
48
],
"parameters": {
"jsCode": "const items = await $input.all();\nconst certificates = [];\n\nfor (const item of items) {\n const certs = Array.isArray(item.json) ? item.json : [item.json];\n\n for (const cert of certs) {\n certificates.push({\n CertificateArn: cert.CertificateArn,\n DomainName: cert.DomainName,\n Status: cert.Status,\n InUse: cert.InUse ? 'Yes' : 'No',\n CreatedAt: new Date(cert.CreatedAt * 1000).toISOString(),\n IssuedAt: new Date(cert.IssuedAt * 1000).toISOString(),\n NotBefore: new Date(cert.NotBefore * 1000).toISOString(),\n NotAfter: new Date(cert.NotAfter * 1000).toISOString(),\n RenewalEligibility: cert.RenewalEligibility,\n SubjectAlternativeNames: (cert.SubjectAlternativeNameSummaries || []).join(', '),\n KeyAlgorithm: cert.KeyAlgorithm,\n KeyUsages: (cert.KeyUsages || []).join(', '),\n ExtendedKeyUsages: (cert.ExtendedKeyUsages || []).join(', '),\n Type: cert.Type,\n Exported: cert.Exported ? 'Yes' : 'No',\n });\n }\n}\n\nreturn [\n {\n json: {\n certificates,\n total: certificates.length,\n expiredCount: certificates.filter(c => c.Status === 'EXPIRED').length,\n inUseCount: certificates.filter(c => c.InUse === 'Yes').length,\n }\n }\n];"
},
"typeVersion": 2
},
{
"id": "7d2d2fa6-2737-4577-bb13-5d776a9a0a5b",
"name": "OpenAI 聊天模型1",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
768,
-32
],
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4.1-mini"
},
"options": {}
},
"credentials": {
"openAiApi": {
"id": "PPSwAKeLQYgAPobT",
"name": "OpenAi account"
}
},
"typeVersion": 1.2
},
{
"id": "4f123f70-a491-4201-a2f7-6069cbd735c2",
"name": "创建文档文件",
"type": "n8n-nodes-base.httpRequest",
"position": [
1296,
-152
],
"parameters": {
"url": "https://www.googleapis.com/upload/drive/v3/files?uploadType=multipart&supportsAllDrives=true",
"body": "=--foo_bar_baz\nContent-Type: application/json; charset=UTF-8\n\n{\n \"name\": \"ACM Certificate Weekly Report {{ $today.format('yyyy-MM-dd-hhmm') }}\",\n \"mimeType\": \"application/vnd.google-apps.document\",\n \"parents\": [\"{{ $json['Drive Folder ID'] }}\"]\n}\n\n--foo_bar_baz\nContent-Type: text/markdown; charset=UTF-8\n\n{{ $json['Document Content'] }}\n--foo_bar_baz--",
"method": "POST",
"options": {},
"sendBody": true,
"sendQuery": true,
"contentType": "raw",
"sendHeaders": true,
"authentication": "predefinedCredentialType",
"rawContentType": "multipart/related; boundary=foo_bar_baz",
"queryParameters": {
"parameters": [
{
"name": "uploadType",
"value": "multipart"
},
{
"name": "supportsAllDrives",
"value": "true"
}
]
},
"headerParameters": {
"parameters": [
{
"name": "boundary",
"value": "foo_bar_baz"
}
]
},
"nodeCredentialType": "googleDriveOAuth2Api"
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "fC471es5gk5Mm900",
"name": "Google Drive account"
}
},
"typeVersion": 4.2
},
{
"id": "1ee4f8f4-1e4b-4977-a090-b350e69e6fd8",
"name": "配置元数据",
"type": "n8n-nodes-base.set",
"position": [
1072,
-152
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "1ff0b9a4-7d60-44ec-b047-e49252f1ace9",
"name": "Drive Folder ID",
"type": "string",
"value": "1IPcko8bzogO3W4mxhrW2Q017QA0Lc5MI"
},
{
"id": "75ab39ab-44d0-4272-bceb-fe63bd72a5ba",
"name": "Document Content",
"type": "string",
"value": "={{ $json.output }}"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "44bc4988-b569-4eeb-bee6-af4897743939",
"name": "转换为 PDF",
"type": "n8n-nodes-base.googleDrive",
"position": [
1520,
-152
],
"parameters": {
"fileId": {
"__rl": true,
"mode": "id",
"value": "={{ $json.id }}"
},
"options": {
"googleFileConversion": {
"conversion": {
"docsToFormat": "application/pdf"
}
}
},
"operation": "download"
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "fC471es5gk5Mm900",
"name": "Google Drive account"
}
},
"typeVersion": 3
},
{
"id": "cf420f55-0b0e-44a7-84c9-d4ec1b5220d0",
"name": "发送每周 ACM 报告 PDF",
"type": "n8n-nodes-base.slack",
"position": [
1744,
-152
],
"webhookId": "b4d5b0ca-b166-4000-abf8-df943fe711ae",
"parameters": {
"options": {
"channelId": "C097VAKKPUP",
"initialComment": "📄 The ACM Certificate Weekly Report is ready! Please find the generated PDF file attached for review and next steps. "
},
"resource": "file",
"authentication": "oAuth2"
},
"credentials": {
"slackOAuth2Api": {
"id": "4JSKt9sIRV1KGswQ",
"name": "Slack account"
}
},
"typeVersion": 2.3
},
{
"id": "00e56531-89a5-447b-b99f-e1946c63eba5",
"name": "发送每周 ACM 报告电子邮件",
"type": "n8n-nodes-base.sendGrid",
"disabled": true,
"position": [
1296,
248
],
"parameters": {
"subject": "Weekly ACM Report",
"toEmail": "={{ $json.RecepientEmail }}",
"fromName": "={{ $json.SenderName }}",
"resource": "mail",
"fromEmail": "={{ $json.SenderEmail }}",
"contentType": "text/html",
"contentValue": "={{ $('Certificate Summary HTML Agent').item.json.output }}",
"additionalFields": {}
},
"credentials": {
"sendGridApi": {
"id": "O1IzegT4JdKjrzrj",
"name": "SendGrid account"
}
},
"typeVersion": 1
},
{
"id": "cc91cae2-3dd0-4a16-ba4d-30034521582d",
"name": "证书摘要 Markdown 代理",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
672,
-256
],
"parameters": {
"text": "=Here is the list of AWS ACM certificate metadata in JSON format. Please generate a Markdown report including:\n\n- A summary of:\n - Total number of certificates\n - Number of expired certificates\n - Number currently in use\n\n- A table with the following columns:\n - Domain Name\n - Expiry Date (NotAfter)\n - Status (add ⚠️ if expired)\n - In Use\n - Renewal Eligibility\n - Subject Alternative Names\n - Key Algorithm\n\nEnsure the Markdown is readable and ready to be saved as a `.md` file for Slack.\n\nHere is the input data: {{ $json.certificates.toJsonString() }}",
"options": {
"systemMessage": "You are a reporting assistant that converts AWS Certificate Manager (ACM) metadata into a clean, readable, and professional Markdown report.\n\nYour job is to:\n- Generate a summary at the top: total certificates, number expired, number in use\n- Present certificate data as a Markdown table\n- Include key fields: Domain Name, Expiry Date, Status, In Use, Renewal Eligibility, Subject Alternative Names, Key Algorithm\n- Highlight expired certificates with ⚠️ in the Status column\n- Sort the table by expiration date descending (nearest expiry at the top)\n- Output only Markdown content (no explanations or extra comments)"
},
"promptType": "define"
},
"typeVersion": 2.1
},
{
"id": "bb2cdcf1-8e34-4b01-9f79-ad2d8efaafae",
"name": "证书摘要 HTML 代理",
"type": "@n8n/n8n-nodes-langchain.agent",
"disabled": true,
"position": [
672,
248
],
"parameters": {
"text": "=Here is a list of AWS ACM certificates in JSON format. Please generate a summary HTML report with the following fields for each certificate:\n\n- Domain Name \n- Expiry Date \n- Status (highlight if EXPIRED or FAILED) \n- In Use (Yes/No) \n- Renewal Eligibility \n- Subject Alternative Names \n- Key Algorithm \n\nAlso include a summary at the top showing:\n- Total certificates\n- Number of expired certificates\n- Number of in-use certificates\n\nOutput only HTML with a simple table layout.\n\nHere is the data: {{ $json.certificates.toJsonString() }}",
"options": {
"systemMessage": "You are an expert assistant specialized in generating concise, clear, and visually structured HTML reports based on AWS Certificate Manager (ACM) metadata. \n\nYour goal is to help DevOps teams quickly understand the status of their certificates by extracting key information from the given certificate JSON array.\n\nAlways format the output as a valid HTML table, include appropriate headings and summary, and sort certificates by expiration date descending (most urgent first). Use red or orange for expired or ineligible certificates to improve visibility. You do not need to explain the data—just output the HTML for embedding in Slack or email messages."
},
"promptType": "define"
},
"typeVersion": 2.1
},
{
"id": "cf045865-814e-4301-9c73-de39bd3c6585",
"name": "## 为什么选择 4o 模型?👆",
"type": "n8n-nodes-base.stickyNote",
"position": [
1296,
-624
],
"parameters": {
"width": 912,
"height": 416,
"content": ""
},
"typeVersion": 1
},
{
"id": "e35484f2-223c-449a-9609-433a04a96109",
"name": "便签 9",
"type": "n8n-nodes-base.stickyNote",
"position": [
1984,
-160
],
"parameters": {
"width": 336,
"height": 144,
"content": "### 6. 💬 将 PDF 报告发送到 Slack"
},
"typeVersion": 1
},
{
"id": "5a303f6d-00f4-4668-9b7e-c6bce6187f99",
"name": "设置工作流数据",
"type": "n8n-nodes-base.set",
"disabled": true,
"position": [
1072,
248
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "0869e141-3255-4268-ad3b-cb88173b6079",
"name": "SenderEmail",
"type": "string",
"value": "it@emesoft.net"
},
{
"id": "6c2047bb-ff37-45c2-a30c-6b00b6aed409",
"name": "SenderName",
"type": "string",
"value": "IT Support"
},
{
"id": "8b5c7afb-3ac0-4be9-ada8-4488d5acf402",
"name": "RecepientEmail",
"type": "string",
"value": "trung.tran@emesoft.net"
}
]
}
},
"typeVersion": 3.4
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "6985d393-0373-4095-b053-76348faa6904",
"connections": {
"Convert to PDF": {
"main": [
[
{
"node": "Send Weekly ACM Report PDF",
"type": "main",
"index": 0
}
]
]
},
"Parse ACM Data": {
"main": [
[
{
"node": "Certificate Summary HTML Agent",
"type": "main",
"index": 0
},
{
"node": "Certificate Summary Markdown Agent",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Chat Model": {
"ai_languageModel": [
[
{
"node": "Certificate Summary HTML Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Set Workflow Data": {
"main": [
[
{
"node": "Send Weekly ACM Report Email",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Chat Model1": {
"ai_languageModel": [
[
{
"node": "Certificate Summary Markdown Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Configure metadata ": {
"main": [
[
{
"node": "Create document file",
"type": "main",
"index": 0
}
]
]
},
"Create document file": {
"main": [
[
{
"node": "Convert to PDF",
"type": "main",
"index": 0
}
]
]
},
"Get many certificates": {
"main": [
[
{
"node": "Parse ACM Data",
"type": "main",
"index": 0
}
]
]
},
"Weekly schedule trigger": {
"main": [
[
{
"node": "Get many certificates",
"type": "main",
"index": 0
}
]
]
},
"Certificate Summary HTML Agent": {
"main": [
[
{
"node": "Set Workflow Data",
"type": "main",
"index": 0
}
]
]
},
"Certificate Summary Markdown Agent": {
"main": [
[
{
"node": "Configure metadata ",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
高级 - AI 摘要总结, 多模态 AI
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
Decodo爬虫API工作流模板(n8n自动化亚马逊图书购买报告)
使用Decodo爬虫和GPT 4.1 mini提取亚马逊图书数据并生成购买报告
Set
Code
Slack
+7
22 节点Trung Tran
AI 摘要总结
用于更智能BRD(业务需求文档)编写的多Agent RAG系统
使用多Agent GPT和Google Workspace生成业务需求文档
Set
Code
Merge
+14
37 节点Trung Tran
AI RAG 检索增强
AI驱动的YouTube自动标签工作流(SEO自动化)
使用GPT和Slack通知自动化YouTube视频SEO标签
Set
Slack
You Tube
+5
19 节点Trung Tran
AI 摘要总结
构建用于Slack候选人评估的AI驱动聊天机器人
AI简历分析与候选人评估:Slack和Google表格集成
If
Code
Slack
+12
29 节点Trung Tran
AI 聊天机器人
HireMind – AI驱动的简历智能处理流程
HR AI简历筛选与评估:GPT-4和Google Workspace
If
Code
Slack
+10
26 节点Trung Tran
人力资源
🎧 IT语音支持自动化机器人 – Telegram语音消息转JIRA工单(使用OpenAI Whisper)
通过Whisper和GPT-4.1 Mini将Telegram语音消息自动转换为JIRA工单
If
Set
Code
+11
25 节点Trung Tran
工单管理
工作流信息
难度等级
高级
节点数量23
分类2
节点类型11
作者
Trung Tran
@trungtranEmpowering small and medium businesses with smart automation and practical AI, no big tech team required.
外部链接
在 n8n.io 查看 →
分享此工作流