スマートサポート分類器-最終版-V140525.9

中級

これはSupport, AI分野の自動化ワークフローで、8個のノードを含みます。主にSet, Wait, Gmail, GoogleSheets, ManualTriggerなどのノードを使用、AI技術を活用したスマート自動化を実現。 Gmail、OpenAI GPT-3.5とGoogleスプレッドシートで顧客サポートメールを自動処理

前提条件
  • Googleアカウント + Gmail API認証情報
  • Google Sheets API認証情報
  • OpenAI API Key
ワークフロープレビュー
ノード接続関係を可視化、ズームとパンをサポート
ワークフローをエクスポート
以下のJSON設定をn8nにインポートして、このワークフローを使用できます
{
  "id": "PBL0Vnp0dTenhlDm",
  "meta": {
    "instanceId": "0c91cd2a3133931f13781d4dcd6db321515413596b36e6bddb494176726841a7"
  },
  "name": "Smart-Support-Classifier-Final-V140525.9",
  "tags": [
    {
      "id": "a6b41kNUtX65uzIo",
      "name": "tuguidragos.com",
      "createdAt": "2025-05-14T18:52:56.055Z",
      "updatedAt": "2025-05-14T18:52:56.055Z"
    }
  ],
  "nodes": [
    {
      "id": "20a686b8-bcb3-4b1e-82c4-777ff21702d4",
      "name": "ワークフロー開始",
      "type": "n8n-nodes-base.manualTrigger",
      "position": [
        480,
        40
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "9297e730-ce96-48bc-af9c-140713730e5f",
      "name": "新規サポートメールを取得",
      "type": "n8n-nodes-base.gmail",
      "position": [
        660,
        40
      ],
      "webhookId": "90228d6b-baee-4dcc-a2fb-a16931c8d298",
      "parameters": {
        "filters": {
          "labelIds": [
            "Label_7360154076951125746"
          ]
        },
        "operation": "getAll",
        "authentication": "serviceAccount"
      },
      "typeVersion": 2.1
    },
    {
      "id": "9607cc7a-f74c-447c-a094-bce30ce384e3",
      "name": "AI: カスタマーリクエストの分類",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        840,
        40
      ],
      "parameters": {
        "modelId": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-3.5-turbo",
          "cachedResultName": "GPT-3.5-TURBO"
        },
        "options": {},
        "messages": {
          "values": [
            {
              "content": "=You are a customer support specialist for a premium streetwear brand.\n\nYour task is:\n1. Read the customer message below.\n2. Reply in a helpful, friendly and clear tone (do NOT include category or tone in your reply).\n3. Return a JSON object like this:\n\n{\n  \"reply\": \"...\",\n  \"category\": \"...\",   // one of: Complaint, Return, Exchange, Refund, General\n  \"tone\": \"...\"        // one of: calm, happy, confused, nervous, angry, urgent\n}\n\nCustomer message: \"{{ $json[\"snippet\"] }}\""
            }
          ]
        }
      },
      "typeVersion": 1.8
    },
    {
      "id": "0f44581f-cb39-4c7b-90b2-ffe5000a12c6",
      "name": "AI応答待ち",
      "type": "n8n-nodes-base.wait",
      "position": [
        1200,
        40
      ],
      "webhookId": "2e4019c7-4a7a-4613-ae2b-0d83c8ac2258",
      "parameters": {
        "amount": 60
      },
      "typeVersion": 1.1
    },
    {
      "id": "a67f020c-c5c8-4d3d-be3b-eff344025afe",
      "name": "スプレッドシート用データを準備",
      "type": "n8n-nodes-base.set",
      "position": [
        1400,
        40
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "id": "a0f2548d-b19f-4571-885a-fcd1d9717859",
              "name": "reply",
              "type": "string",
              "value": "={{ JSON.parse($json[\"message\"][\"content\"]).reply}}"
            },
            {
              "id": "a5dda8a1-824d-4e70-be86-c7f26762efa6",
              "name": "category",
              "type": "string",
              "value": "={{ JSON.parse($json[\"message\"][\"content\"]).category }}"
            },
            {
              "id": "500684d5-d743-4612-a32f-33a07303a3a7",
              "name": "tone",
              "type": "string",
              "value": "={{ JSON.parse($json[\"message\"][\"content\"]).tone }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "be051cca-de6b-4a22-84ba-7acddf9fb549",
      "name": "Googleスプレッドシートに記録",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1600,
        40
      ],
      "parameters": {
        "columns": {
          "value": {
            "Tone": "={{ $json[\"tone\"] }}",
            "Email": "={{ $node[\"Fetch New Support Email\"].json[\"From\"].match(/<(.+)>/)?.[1] || $node[\"Fetch New Support Email\"].json[\"From\"] }}",
            "Reply": "={{ $json[\"reply\"] }}",
            "Subject": "={{ $node[\"Fetch New Support Email\"].json[\"Subject\"] }}",
            "Category": "={{ $json[\"category\"] }}",
            "Timestamp": "={{ $now }}"
          },
          "schema": [
            {
              "id": "Timestamp",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Timestamp",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Email",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Subject",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Subject",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Reply",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Reply",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Category",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Category",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Tone",
              "type": "string",
              "display": true,
              "required": false,
              "displayName": "Tone",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "gid=0",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1UtGOIpiTxYyAOIj_8-u8k0mWaEgCmAIzfKcvd0bGZsY/edit#gid=0",
          "cachedResultName": "log"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "1UtGOIpiTxYyAOIj_8-u8k0mWaEgCmAIzfKcvd0bGZsY",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1UtGOIpiTxYyAOIj_8-u8k0mWaEgCmAIzfKcvd0bGZsY/edit?usp=drivesdk",
          "cachedResultName": "Support_Log_SmartClassifier"
        },
        "authentication": "serviceAccount"
      },
      "typeVersion": 4.5
    },
    {
      "id": "7bf39ed5-5633-4fb4-b938-0523cc56d539",
      "name": "顧客に自動返信",
      "type": "n8n-nodes-base.gmail",
      "position": [
        1800,
        40
      ],
      "webhookId": "bf7651d5-9da5-4c0a-8651-d160f0446e6f",
      "parameters": {
        "sendTo": "={{ $node[\"Fetch New Support Email\"].json[\"From\"].match(/<(.*)>/)?.[1] || $node[\"Fetch New Support Email\"].json[\"From\"] }}",
        "message": "={{ $node[\"Log Request in Google Sheets\"].json[\"Reply\"] }}",
        "options": {},
        "subject": "=RE: {{ $node[\"Fetch New Support Email\"].json[\"Subject\"] }}",
        "emailType": "text",
        "authentication": "serviceAccount"
      },
      "typeVersion": 2.1
    },
    {
      "id": "1b529682-bdd3-48c1-ac13-f696d75013ef",
      "name": "付箋",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        0,
        0
      ],
      "parameters": {
        "color": 4,
        "width": 2060,
        "height": 680,
        "content": "---\n\n## 📌 Sticky Notes\n\n### 1. Step 1 – Trigger the Workflow\nStarts the automation manually or on a schedule.\n\n### 2. Step 2 – Fetch New Emails\nUses Gmail to retrieve incoming emails with a specific label or filter.\n\n### 3. Step 3 – Classify Email with OpenAI\nSends the email content to GPT-3.5 to detect the category and suggested response.\n\n### 4. Step 4 – Generate Smart Reply\nUses OpenAI to generate a friendly, clear, and personalized email response.\n\n### 5. Step 5 – Send Email to Customer\nReplies to the customer via Gmail with the AI-generated message.\n\n### 6. Step 6 – Log Interaction to Google Sheets\nLogs all data including timestamp, email address, subject, category, and reply.\n\n### 7. Step 7 – Optional Enhancements\nAdd-ons like Slack notifications, translations, webhook triggers, or error handling.\n\n---\n"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "6b515165-fa86-46aa-96cb-dc51f5beb393",
  "connections": {
    "20a686b8-bcb3-4b1e-82c4-777ff21702d4": {
      "main": [
        [
          {
            "node": "9297e730-ce96-48bc-af9c-140713730e5f",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "0f44581f-cb39-4c7b-90b2-ffe5000a12c6": {
      "main": [
        [
          {
            "node": "a67f020c-c5c8-4d3d-be3b-eff344025afe",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9297e730-ce96-48bc-af9c-140713730e5f": {
      "main": [
        [
          {
            "node": "9607cc7a-f74c-447c-a094-bce30ce384e3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "be051cca-de6b-4a22-84ba-7acddf9fb549": {
      "main": [
        [
          {
            "node": "7bf39ed5-5633-4fb4-b938-0523cc56d539",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "a67f020c-c5c8-4d3d-be3b-eff344025afe": {
      "main": [
        [
          {
            "node": "be051cca-de6b-4a22-84ba-7acddf9fb549",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "9607cc7a-f74c-447c-a094-bce30ce384e3": {
      "main": [
        [
          {
            "node": "0f44581f-cb39-4c7b-90b2-ffe5000a12c6",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
よくある質問

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

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

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

中級 - サポート, 人工知能

有料ですか?

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

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

経験者向け、6-15ノードの中程度の複雑さのワークフロー

作成者
Țugui Dragoș

Țugui Dragoș

@tuguidragos

I create no-code workflows that feel human, think smart, and close leads automatically.

外部リンク
n8n.ioで表示

このワークフローを共有

カテゴリー

カテゴリー: 34