AI および MCP ツールを使用したウェサイトの監視と分析

上級

これはDevOps, AI Summarization分野の自動化ワークフローで、19個のノードを含みます。主にIf, Set, Merge, Slack, Switchなどのノードを使用。 GPT-4 Mini、MCP ツール、マルチチャネルアラートを使ったサイトモニタリングの自動化

前提条件
  • Slack Bot Token または Webhook URL
  • Google Sheets API認証情報
  • OpenAI API Key

カテゴリー

ワークフロープレビュー
ノード接続関係を可視化、ズームとパンをサポート
ワークフローをエクスポート
以下のJSON設定をn8nにインポートして、このワークフローを使用できます
{
  "id": "h8LUhXgUTopnys7n",
  "meta": {
    "instanceId": "f31c8cf0f30c343fde4e229f596b53099ee0496367bfd39c53458e5afe95e91e"
  },
  "name": "Monitor websites with AI analysis and MCP tools",
  "tags": [],
  "nodes": [
    {
      "id": "95d1b83e-a5d1-4604-a052-cebe570bf35b",
      "name": "ウェブサイト監視トリガー",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -560,
        736
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "minutes"
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "2ec72ca1-0e51-4ed5-ac71-7daba88af146",
      "name": "設定変数",
      "type": "n8n-nodes-base.set",
      "position": [
        -336,
        736
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "0b5e5e4a-7429-438e-a5e0-fa8d7b8b5be5",
              "name": "config",
              "type": "object",
              "value": {
                "websites": [
                  "https://example.com",
                  "https://example.org"
                ],
                "mcpServers": {
                  "mcpRecon": "={{$env.MCP_RECON_URL || 'http://localhost:8002'}}",
                  "browserTools": "={{$env.MCP_BROWSER_TOOLS_URL || 'http://localhost:8001'}}"
                },
                "monitoring": {
                  "batchSize": 10,
                  "responseTimeWarning": 3000,
                  "responseTimeCritical": 5000,
                  "sslExpiryWarningDays": 30,
                  "performanceScoreThreshold": 80
                },
                "notifications": {
                  "fromEmail": "={{$env.FROM_EMAIL}}",
                  "alertEmail": "={{$env.ALERT_EMAIL}}",
                  "enableEmail": true,
                  "enableSlack": true,
                  "slackChannel": "={{$env.SLACK_CHANNEL || '#alerts'}}"
                }
              }
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "86441b58-b62b-4e41-a236-0444500ecd2c",
      "name": "ウェブサイトリストの読み込み",
      "type": "n8n-nodes-base.googleSheets",
      "onError": "continueRegularOutput",
      "position": [
        -112,
        736
      ],
      "parameters": {
        "options": {},
        "filtersUI": {
          "values": []
        },
        "sheetName": {
          "mode": "name",
          "value": "Websites"
        },
        "documentId": {
          "mode": "id",
          "value": "={{$env.GOOGLE_SHEET_ID}}"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "UD5OjKiVkvWF1KEV",
          "name": "Google Sheets account"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "8553b2d7-bc89-4e8f-a1cc-3101477cb5ae",
      "name": "分析結果の結合",
      "type": "n8n-nodes-base.merge",
      "position": [
        1248,
        736
      ],
      "parameters": {
        "mode": "combine",
        "options": {},
        "combineBy": "combineAll"
      },
      "typeVersion": 3
    },
    {
      "id": "dd498eee-406a-4539-82ca-944e1049852c",
      "name": "アラート重要度ルーター",
      "type": "n8n-nodes-base.switch",
      "position": [
        1472,
        720
      ],
      "parameters": {
        "rules": {
          "values": [
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "ccba5bef-efa2-49f8-9a88-e1bdd4c90f13",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.severity }}",
                    "rightValue": "critical"
                  }
                ]
              }
            },
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "91721c80-38de-4443-9bba-72d2fc5cbbdb",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.severity }}",
                    "rightValue": "warning"
                  }
                ]
              }
            },
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "80702517-1472-4b88-b503-1df62fe22572",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.severity }}",
                    "rightValue": "info"
                  }
                ]
              }
            }
          ]
        },
        "options": {}
      },
      "typeVersion": 3.2
    },
    {
      "id": "b0feb330-f6b7-4f36-9822-5a6744bd2689",
      "name": "重大なSlackアラート",
      "type": "n8n-nodes-base.slack",
      "onError": "continueRegularOutput",
      "position": [
        1696,
        448
      ],
      "webhookId": "a32f458a-16f3-4aef-8ccc-e0a1e065e3fd",
      "parameters": {
        "text": "=🚨 **CRITICAL WEBSITE ISSUE** 🚨\n\n**Website:** {{ $json.url }}\n**Severity:** CRITICAL\n**Performance Score:** {{ $json.performanceScore }}%\n**Response Time:** {{ $json.responseTime }}ms\n**SSL Status:** {{ $json.sslStatus }}\n\n**Issues Found:**\n{{ $json.issues.map(issue => '• ' + issue).join('\\n') }}\n\n**Security Score:** {{ $json.securityScore || 'N/A' }}\n\n_Generated by n8n MCP Monitoring System_",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "name",
          "value": "={{$('Configuration Variables').item.json.config.notifications.slackChannel}}"
        },
        "otherOptions": {}
      },
      "typeVersion": 2.3
    },
    {
      "id": "1c703878-ad45-4a94-97d1-b2ae7ece6a36",
      "name": "重大なメールアラート",
      "type": "n8n-nodes-base.emailSend",
      "onError": "continueRegularOutput",
      "position": [
        1696,
        640
      ],
      "webhookId": "e234630d-efc3-41d4-bc08-2574da0c5c10",
      "parameters": {
        "html": "=<h2>🚨 Critical Website Issue Detected</h2>\n<p><strong>Website:</strong> {{ $json.url }}</p>\n<p><strong>Severity:</strong> CRITICAL</p>\n\n<h3>Issues Detected:</h3>\n<ul>\n{{ $json.issues.map(issue => '<li>' + issue + '</li>').join('') }}\n</ul>\n\n<h3>Performance Metrics:</h3>\n<ul>\n<li><strong>Performance Score:</strong> {{ $json.performanceScore }}%</li>\n<li><strong>Response Time:</strong> {{ $json.responseTime }}ms</li>\n<li><strong>SSL Status:</strong> {{ $json.sslStatus || 'Unknown' }}</li>\n<li><strong>Security Score:</strong> {{ $json.securityScore || 'N/A' }}</li>\n</ul>\n\n<p><em>Generated by n8n MCP Monitoring System at {{ new Date().toISOString() }}</em></p>",
        "options": {},
        "subject": "🚨 CRITICAL: Website Issue - {{ $json.url }}",
        "toEmail": "={{$('Configuration Variables').item.json.config.notifications.alertEmail}}",
        "fromEmail": "={{$('Configuration Variables').item.json.config.notifications.fromEmail}}"
      },
      "typeVersion": 2.1
    },
    {
      "id": "a29080d1-68fd-4bef-97c5-89feebb4cc01",
      "name": "警告Slackアラート",
      "type": "n8n-nodes-base.slack",
      "onError": "continueRegularOutput",
      "position": [
        1696,
        1024
      ],
      "webhookId": "6a3af096-566b-4c09-b6ac-7a2861e529ec",
      "parameters": {
        "text": "=⚠️ **Website Warning** ⚠️  **Website:** {{ $json.url }} **Severity:** WARNING **Performance Score:** {{ $json.performanceScore }}% **Response Time:** {{ $json.responseTime }}ms **SSL Status:** {{ $json.sslStatus }}  **Issues Found:** {{ $json.issues.map(issue => '• ' + issue).join('\\n') }}  _Generated by n8n MCP Monitoring System_",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "name",
          "value": "={{$('Configuration Variables').item.json.config.notifications.slackChannel}}"
        },
        "otherOptions": {}
      },
      "typeVersion": 2.3
    },
    {
      "id": "b373b04d-4c21-49aa-a584-96a1b6e515c9",
      "name": "Googleスプレッドシートへのログ記録",
      "type": "n8n-nodes-base.googleSheets",
      "onError": "continueRegularOutput",
      "position": [
        2064,
        992
      ],
      "parameters": {
        "columns": {
          "value": {
            "url": "={{ $json.url }}",
            "issues": "={{ $json.issues.join(', ') }}",
            "severity": "={{ $json.severity }}",
            "sslStatus": "={{ $json.sslStatus }}",
            "timestamp": "={{ new Date().toISOString() }}",
            "responseTime": "={{ $json.responseTime }}",
            "securityScore": "={{ $json.securityScore }}",
            "recommendations": "={{ $json.recommendations ? $json.recommendations.join(', ') : '' }}",
            "performanceScore": "={{ $json.performanceScore }}"
          },
          "mappingMode": "defineBelow"
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "mode": "name",
          "value": "Monitoring Log"
        },
        "documentId": {
          "mode": "id",
          "value": "={{$env.GOOGLE_SHEET_ID}}"
        },
        "authentication": "serviceAccount"
      },
      "credentials": {
        "googleApi": {
          "id": "UD5OjKiVkvWF1KEV",
          "name": "Google Sheets account"
        }
      },
      "typeVersion": 4.6
    },
    {
      "id": "e5fe4dce-b766-4f90-8a62-8e822e1d9804",
      "name": "ウェブサイトソースの確認",
      "type": "n8n-nodes-base.if",
      "position": [
        112,
        736
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
              "operator": {
                "type": "object",
                "operation": "empty",
                "singleValue": true
              },
              "leftValue": "={{ $('Load Website List').item.json }}",
              "rightValue": ""
            }
          ]
        },
        "looseTypeValidation": true
      },
      "typeVersion": 2.1
    },
    {
      "id": "f9c90d31-261b-42d6-afe2-ee559f32c722",
      "name": "デフォルトウェブサイトのフォーマット",
      "type": "n8n-nodes-base.set",
      "position": [
        336,
        816
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "website-urls",
              "name": "url",
              "type": "string",
              "value": "={{ $item }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "848b85ae-eaf0-4fa3-a87a-e8711becbee0",
      "name": "ウェブサイトURLのバッチ処理",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        560,
        736
      ],
      "parameters": {
        "options": {},
        "batchSize": "={{$('Configuration Variables').item.json.config.monitoring.batchSize}}"
      },
      "typeVersion": 3
    },
    {
      "id": "cde9e03b-6090-45cd-9b00-60c2c0e13f45",
      "name": "ウェブサイト分析エージェント",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        816,
        624
      ],
      "parameters": {
        "text": "=Analyze the following websites for performance and security issues. For each website in the batch:\n\nWebsites to analyze:\n{{ $json.url }}\n\nUse the available MCP tools to:\n1. Run browser-tools-mcp to analyze performance, SEO, and accessibility\n2. Run mcp-recon to check SSL certificates and security headers\n\nBased on the analysis, determine the severity level:\n- CRITICAL: Site down, SSL expired/invalid, performance score <50%, response time >{{ $('Configuration Variables').item.json.config.monitoring.responseTimeCritical }}ms\n- WARNING: SSL expiring within {{ $('Configuration Variables').item.json.config.monitoring.sslExpiryWarningDays }} days, performance score <{{ $('Configuration Variables').item.json.config.monitoring.performanceScoreThreshold }}%, response time >{{ $('Configuration Variables').item.json.config.monitoring.responseTimeWarning }}ms, missing critical security headers\n- INFO: Minor issues or optimization suggestions\n\nReturn a JSON object for each website with this structure:\n{\n  \"url\": \"website URL\",\n  \"severity\": \"critical|warning|info\",\n  \"performanceScore\": number (0-100),\n  \"responseTime\": number (milliseconds),\n  \"sslStatus\": \"valid|expiring|expired|invalid\",\n  \"securityScore\": number (0-100),\n  \"issues\": [\"array of specific issues found\"],\n  \"recommendations\": [\"array of improvement suggestions\"]\n}\n\nFocus on actionable issues that require immediate attention. Be concise but specific about problems found.",
        "options": {},
        "promptType": "define"
      },
      "typeVersion": 2.1
    },
    {
      "id": "56992e24-7b12-4113-aff4-e36665dd8947",
      "name": "Browser-Tools-MCP",
      "type": "@n8n/n8n-nodes-langchain.mcpClientTool",
      "position": [
        960,
        848
      ],
      "parameters": {
        "sseEndpoint": "http://localhost:8001"
      },
      "typeVersion": 1
    },
    {
      "id": "f67ff2bb-f799-46b3-961b-3f449b2ca519",
      "name": "mcp-recon",
      "type": "@n8n/n8n-nodes-langchain.mcpClientTool",
      "position": [
        1104,
        848
      ],
      "parameters": {
        "sseEndpoint": "http://localhost:8002"
      },
      "typeVersion": 1
    },
    {
      "id": "98f9489d-30c4-4ef4-9154-e6c488572b2f",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        784,
        848
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4.1-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "M2qgdRuw59w2LPE1",
          "name": "OpenAi account 2"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "5d997a64-b0e2-4648-aa9d-f443a8d2fca8",
      "name": "付箋1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1920,
        528
      ],
      "parameters": {
        "width": 400,
        "height": 624,
        "content": "📊 Google Sheets Configuration\n\n**Sheet 1: \"Websites\"**\nRequired Headers:\n- url - Website URLs to monitor\n\n**Sheet 2: \"Monitoring Log\"**\nAuto-populated Headers:\n- timestamp - Analysis timestamp\n- url - Website analyzed\n- severity - critical/warning/info\n- performanceScore - Performance rating (0-100)\n- responseTime - Response time in ms\n- sslStatus - SSL certificate status\n- securityScore - Security rating (0-100)\n- issues - Detected problems\n- recommendations - Improvement suggestions\n\n🔗 Service Account Permissions:\nGrant \"Editor\" access to your Google Sheets service account"
      },
      "typeVersion": 1
    },
    {
      "id": "404d6215-ebd1-42c2-908d-fdab20957aaf",
      "name": "付箋2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -640,
        32
      ],
      "parameters": {
        "color": 5,
        "width": 496,
        "height": 592,
        "content": "🛠️ AI-Powered Website Monitoring System\n\nThis workflow monitors multiple websites using AI analysis and MCP tools for comprehensive performance and security monitoring.\n\n✅ **Step 1: Install Required MCP Servers**\n- Install browser-tools-mcp for performance analysis\n- Install mcp-recon for security and SSL monitoring\n- Configure server endpoints in environment variables\n\n✅ **Step 2: Setup Google Sheets Integration**\n- Create \"Websites\" sheet with URL column\n- Create \"Monitoring Log\" sheet for results tracking\n- Set GOOGLE_SHEET_ID environment variable\n\n✅ **Step 3: Configure Notifications**\n- Set up Slack webhook/bot for alerts\n- Configure SMTP settings for email notifications\n- Set SLACK_CHANNEL, ALERT_EMAIL, FROM_EMAIL variables\n\n✅ **Step 4: Customize Monitoring Settings**\n- Update monitoring thresholds in Configuration Variables\n- Add your websites to monitor\n- Adjust batch processing and alert severity rules\n\n🧪 **Final Step: Test Complete System**\nTrigger manually to verify MCP servers, analysis, and notifications work properly"
      },
      "typeVersion": 1
    },
    {
      "id": "2db4a3c7-17af-410a-bbf6-2a2a9bfaff47",
      "name": "付箋3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -32,
        32
      ],
      "parameters": {
        "color": 2,
        "width": 528,
        "height": 592,
        "content": "### 🔧 Required MCP Servers\n\n### Browser Tools MCP\n📂 **GitHub:** [AgentDeskAI/browser-tools-mcp](https://github.com/AgentDeskAI/browser-tools-mcp)\n🌐 **Docs:** [Installation Guide](https://browsertools.agentdesk.ai/installation)\n\n**What it does:** Website performance analysis, SEO scoring, accessibility checks\n\n### MCP Recon\n📂 **GitHub:** [nickpending/mcp-recon](https://github.com/nickpending/mcp-recon)\n\n**What it does:** SSL certificate validation, security headers, domain analysis\n\n\n**Installation:**\n1. Install Node.js if you haven't already\n2. Download both repositories from GitHub\n3. Follow each repository's README for setup\n4. Start both servers before running this workflow\n\n**Default Server URLs:**\n- Browser Tools: http://localhost:8001\n- MCP Recon: http://localhost:8002"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "7f54edc1-cbf3-4654-b986-edc06518d77c",
  "connections": {
    "f67ff2bb-f799-46b3-961b-3f449b2ca519": {
      "ai_tool": [
        [
          {
            "node": "cde9e03b-6090-45cd-9b00-60c2c0e13f45",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "56992e24-7b12-4113-aff4-e36665dd8947": {
      "ai_tool": [
        [
          {
            "node": "cde9e03b-6090-45cd-9b00-60c2c0e13f45",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "86441b58-b62b-4e41-a236-0444500ecd2c": {
      "main": [
        [
          {
            "node": "e5fe4dce-b766-4f90-8a62-8e822e1d9804",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "98f9489d-30c4-4ef4-9154-e6c488572b2f": {
      "ai_languageModel": [
        [
          {
            "node": "cde9e03b-6090-45cd-9b00-60c2c0e13f45",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "848b85ae-eaf0-4fa3-a87a-e8711becbee0": {
      "main": [
        [
          {
            "node": "cde9e03b-6090-45cd-9b00-60c2c0e13f45",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "8553b2d7-bc89-4e8f-a1cc-3101477cb5ae",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "e5fe4dce-b766-4f90-8a62-8e822e1d9804": {
      "main": [
        [
          {
            "node": "f9c90d31-261b-42d6-afe2-ee559f32c722",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "848b85ae-eaf0-4fa3-a87a-e8711becbee0",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "dd498eee-406a-4539-82ca-944e1049852c": {
      "main": [
        [
          {
            "node": "b0feb330-f6b7-4f36-9822-5a6744bd2689",
            "type": "main",
            "index": 0
          },
          {
            "node": "1c703878-ad45-4a94-97d1-b2ae7ece6a36",
            "type": "main",
            "index": 0
          },
          {
            "node": "b373b04d-4c21-49aa-a584-96a1b6e515c9",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "a29080d1-68fd-4bef-97c5-89feebb4cc01",
            "type": "main",
            "index": 0
          },
          {
            "node": "b373b04d-4c21-49aa-a584-96a1b6e515c9",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "b373b04d-4c21-49aa-a584-96a1b6e515c9",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "cde9e03b-6090-45cd-9b00-60c2c0e13f45": {
      "main": [
        [
          {
            "node": "8553b2d7-bc89-4e8f-a1cc-3101477cb5ae",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2ec72ca1-0e51-4ed5-ac71-7daba88af146": {
      "main": [
        [
          {
            "node": "86441b58-b62b-4e41-a236-0444500ecd2c",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "f9c90d31-261b-42d6-afe2-ee559f32c722": {
      "main": [
        [
          {
            "node": "848b85ae-eaf0-4fa3-a87a-e8711becbee0",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "95d1b83e-a5d1-4604-a052-cebe570bf35b": {
      "main": [
        [
          {
            "node": "2ec72ca1-0e51-4ed5-ac71-7daba88af146",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "8553b2d7-bc89-4e8f-a1cc-3101477cb5ae": {
      "main": [
        [
          {
            "node": "dd498eee-406a-4539-82ca-944e1049852c",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
よくある質問

このワークフローの使い方は?

上記のJSON設定コードをコピーし、n8nインスタンスで新しいワークフローを作成して「JSONからインポート」を選択、設定を貼り付けて認証情報を必要に応じて変更してください。

このワークフローはどんな場面に適していますか?

上級 - DevOps, AI要約

有料ですか?

このワークフローは完全無料です。ただし、ワークフローで使用するサードパーティサービス(OpenAI APIなど)は別途料金が発生する場合があります。

ワークフロー情報
難易度
上級
ノード数19
カテゴリー2
ノードタイプ13
難易度説明

上級者向け、16ノード以上の複雑なワークフロー

外部リンク
n8n.ioで表示

このワークフローを共有

カテゴリー

カテゴリー: 34