발행일: 2026-10-06(화) 11:44
← 목차로 돌아가기|하루 30분 n8n 시리즈 ② 실무 자동화 레시피 100
RECIPE 038

웨비나 참석자 → 영업 리드 자동 분류

  • ▸Google Forms 응답 데이터를 자동으로 집계할 수 있다
  • ▸객관식/주관식 응답을 분류해 통계 데이터를 만들 수 있다
  • ▸집계 결과를 시각화 준비 상태의 Sheets 포맷으로 저장할 수 있다

✅사전 준비

  • □Google Sheets 자격증명 연결 완료 (Forms 응답 연결된 시트)
  • □집계 결과 저장용 시트 생성 (요약 탭)
  • □Schedule Trigger: 매주 금요일 오후 6시 (Cron: 0 18 * * 5)

객관식 응답 집계 — Code 노드

const items = $input.all().map(i => i.json);
const field = '만족도'; // 집계할 컬럼명

const counts = items.reduce((acc, item) => {
  const val = item[field] ?? '무응답';
  acc[val] = (acc[val] ?? 0) + 1;
  return acc;
}, {});

const total = items.length;
return Object.entries(counts).map(([option, count]) => ({
  json: {
    항목: field,
    선택지: option,
    응답수: count,
    비율: ((count / total) * 100).toFixed(1) + '%',
  }
}));

주관식 응답 — OpenAI 키워드 추출

Model: gpt-4o-mini

Prompt:
다음 주관식 응답들에서 반복되는 키워드 Top 5를 추출해줘.
결과는 JSON 배열로만 응답해: ["키워드1", "키워드2", ...]

응답 목록:
{{ $input.all().map(i => i.json.주관식답변).join('\n') }}
💡 TIPGoogle Charts와 연동하면 Sheets 데이터를 바탕으로 차트를 자동 생성할 수 있어요. Sheets에 COUNTIF, QUERY 함수를 미리 설정해두면 n8n이 데이터만 넣어도 차트가 자동 갱신됩니다.
⚡

워크플로우 JSON

아래 JSON을 복사해 n8n에 바로 임포트하세요

📥 n8n 임포트 방법
n8n 화면 우측 상단 메뉴 (⋮) → Import from JSON → 아래 JSON 전체 복사 후 붙여넣기 → Import 클릭
{
  "recipeId": "recipe038",
  "title": "웨비나 참석자 → 영업 리드 자동 분류",
  "chapter": 3,
  "category": "영업 & 리드 관리 자동화",
  "difficulty": "⭐⭐",
  "estimatedTime": "35분",
  "description": "웨비나 종료 후 Zoom API로 참석자 목록을 가져와 HubSpot에 Upsert하고, 참석 시간 30분 이상인 적극 관심 리드를 별도 분류하여 영업팀에 알림을 보냅니다.",
  "apps": [
    "Zoom API",
    "HubSpot",
    "Slack"
  ],
  "nodes": [
    {
      "id": "trigger_schedule",
      "type": "trigger",
      "name": "Schedule Trigger - 웨비나 종료 직후 실행",
      "service": "scheduleTrigger",
      "config": {
        "rule": "0 15 * * *"
      }
    },
    {
      "id": "zoom_participants",
      "type": "action",
      "name": "HTTP Request - Zoom 참석자 목록 수집",
      "service": "httpRequest",
      "config": {
        "method": "GET",
        "url": "https://api.zoom.us/v2/meetings/{{ $env.ZOOM_MEETING_ID }}/participants",
        "headers": {
          "Authorization": "Bearer {{ $env.ZOOM_ACCESS_TOKEN }}"
        }
      }
    },
    {
      "id": "hubspot_upsert",
      "type": "action",
      "name": "HubSpot - Contact Upsert",
      "service": "hubspot",
      "config": {
        "operation": "upsert",
        "contactFields": {
          "email": "={{ $json[\"user_email\"] }}",
          "firstname": "={{ $json[\"name\"].split(\" \")[0] }}",
          "lastname": "={{ $json[\"name\"].split(\" \")[1] }}",
          "webinar_attendee": "true",
          "webinar_duration_min": "={{ $json[\"duration\"] }}"
        }
      }
    },
    {
      "id": "if_hot_lead",
      "type": "condition",
      "name": "30분 이상 참석 여부",
      "config": {
        "conditions": [
          {
            "field": "={{ $json[\"duration\"] }}",
            "operator": "gte",
            "value": 30
          }
        ]
      }
    },
    {
      "id": "slack_hot_lead",
      "type": "action",
      "name": "Slack - 우선 연락 리드 알림",
      "service": "slack",
      "config": {
        "channel": "={{ $env.SLACK_SALES_CHANNEL }}",
        "message": "🔥 웨비나 우선 연락 리드!\n이름: {{ $json[\"name\"] }}\n이메일: {{ $json[\"user_email\"] }}\n참석 시간: {{ $json[\"duration\"] }}분\n→ 지금 바로 연락하세요!"
      }
    }
  ],
  "connections": [
    {
      "from": "trigger_schedule",
      "to": "zoom_participants"
    },
    {
      "from": "zoom_participants",
      "to": "hubspot_upsert"
    },
    {
      "from": "hubspot_upsert",
      "to": "if_hot_lead"
    },
    {
      "from": "if_hot_lead",
      "to": "slack_hot_lead",
      "branch": "true"
    }
  ],
  "envVars": [
    {
      "key": "ZOOM_MEETING_ID",
      "description": "Zoom 웨비나 미팅 ID"
    },
    {
      "key": "ZOOM_ACCESS_TOKEN",
      "description": "Zoom API Access Token"
    },
    {
      "key": "SLACK_SALES_CHANNEL",
      "description": "영업팀 Slack 채널 ID"
    }
  ],
  "qrCodeUrl": "https://www.koreaaitimes.com/books/n8n-vol2/recipe038"
}
← 이전 레시피☰ 목차다음 레시피 →