{
  "name": "[\uc5c5\ubb34] \uc77c\uc77c \uc5c5\ubb34 \ubcf4\uace0 \uc790\ub3d9\ud654 - \uc2a4\ucf00\uc904",
  "nodes": [
    {
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "cronExpression",
              "expression": "0 17 * * 1-5"
            }
          ]
        }
      },
      "id": "schedule-trigger-node",
      "name": "\ub9e4\uc77c \uc624\ud6c4 \ubcf4\uace0",
      "type": "n8n-nodes-base.scheduleTrigger",
      "typeVersion": 1.2,
      "position": [
        250,
        300
      ]
    },
    {
      "parameters": {
        "authentication": "oAuth2",
        "resource": "channel",
        "operation": "history",
        "channelId": {
          "__rl": true,
          "value": "C_YOUR_CHANNEL_ID",
          "mode": "id"
        },
        "returnAll": true,
        "filters": {
          "oldest": "={{ Math.floor(new Date(new Date().toLocaleDateString('en-CA', { timeZone: 'Asia/Seoul' }) + 'T00:00:00+09:00').getTime() / 1000) }}"
        },
        "options": {}
      },
      "id": "slack-get-messages",
      "name": "\uc624\ub298 \uba54\uc2dc\uc9c0 \uc218\uc9d1",
      "type": "n8n-nodes-base.slack",
      "typeVersion": 2.2,
      "position": [
        450,
        300
      ],
      "credentials": {
        "slackOAuth2Api": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "mode": "runOnceForAllItems",
        "jsCode": "const messages = $input.all();\n\nconst grouped = {};\nfor (const msg of messages) {\n  const user = msg.json.user || '\uc54c \uc218 \uc5c6\uc74c';\n  if (!grouped[user]) grouped[user] = [];\n  grouped[user].push(msg.json.text || '');\n}\n\nlet summary = '';\nfor (const [user, texts] of Object.entries(grouped)) {\n  summary += `[${user}]\\n`;\n  texts.forEach(t => { summary += `- ${t}\\n`; });\n  summary += '\\n';\n}\n\nreturn [{ json: { messagesSummary: summary, messageCount: messages.length, date: new Date().toLocaleDateString('ko-KR', { timeZone: 'Asia/Seoul' }) } }];"
      },
      "id": "code-group-messages",
      "name": "\uba54\uc2dc\uc9c0 \uc815\ub9ac",
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        650,
        300
      ]
    },
    {
      "parameters": {
        "resource": "text",
        "operation": "message",
        "modelId": "gpt-4o-mini",
        "messages": {
          "values": [
            {
              "role": "system",
              "content": "\ud300\uc758 \uc624\ub298 Slack \uba54\uc2dc\uc9c0\ub97c \ubd84\uc11d\ud558\uc5ec \uc77c\uc77c \uc5c5\ubb34 \ubcf4\uace0\uc11c\ub97c \uc791\uc131\ud558\uc138\uc694. \ub2e4\uc74c \ud56d\ubaa9\uc73c\ub85c \uad6c\ubd84\ud569\ub2c8\ub2e4:\n1. \uc644\ub8cc \uc5c5\ubb34\n2. \uc9c4\ud589 \uc911 \uc5c5\ubb34\n3. \uc774\uc288 \ubc0f \ud2b9\uc774\uc0ac\ud56d\n\n\uac04\uacb0\ud558\uace0 \ud575\uc2ec\uc801\uc778 \ub0b4\uc6a9\ub9cc \ud3ec\ud568\ud558\uc138\uc694."
            },
            {
              "role": "user",
              "content": "=\uc624\ub298 \ub0a0\uc9dc: {{ $json.date }}\n\uba54\uc2dc\uc9c0 \uc218: {{ $json.messageCount }}\uac74\n\n--- \uba54\uc2dc\uc9c0 \ub0b4\uc6a9 ---\n{{ $json.messagesSummary }}"
            }
          ]
        },
        "options": {
          "temperature": 0.5
        }
      },
      "id": "openai-report",
      "name": "AI \ubcf4\uace0\uc11c \uc0dd\uc131",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "typeVersion": 1.3,
      "position": [
        850,
        300
      ],
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "resource": "databasePage",
        "operation": "create",
        "databaseId": {
          "__rl": true,
          "value": "placeholder-notion-db-id",
          "mode": "id"
        },
        "title": "={{ new Date().toLocaleDateString('ko-KR', { timeZone: 'Asia/Seoul' }) }} \uc77c\uc77c \ubcf4\uace0",
        "bodyUi": {
          "bodyValues": [
            {
              "blockUi": {
                "blockValues": [
                  {
                    "type": "paragraph",
                    "richText": true,
                    "textContent": "={{ $json.message?.content || $json.text || '' }}"
                  }
                ]
              }
            }
          ]
        },
        "options": {}
      },
      "id": "notion-save",
      "name": "\ub178\uc158 \ubcf4\uace0\uc11c \uc800\uc7a5",
      "type": "n8n-nodes-base.notion",
      "typeVersion": 2.2,
      "position": [
        1050,
        300
      ],
      "credentials": {
        "notionApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "authentication": "oAuth2",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "value": "C_YOUR_CHANNEL_ID",
          "mode": "id"
        },
        "text": "=:clipboard: \uc77c\uc77c \uc5c5\ubb34 \ubcf4\uace0\uc11c\uac00 \uc0dd\uc131\ub418\uc5c8\uc2b5\ub2c8\ub2e4!\n\ub0a0\uc9dc: {{ $('\uba54\uc2dc\uc9c0 \uc815\ub9ac').item.json.date }}\n\ub178\uc158\uc5d0\uc11c \ud655\uc778\ud558\uc138\uc694.",
        "otherOptions": {}
      },
      "id": "slack-notify",
      "name": "\ubcf4\uace0\uc11c \uc644\ub8cc \uc54c\ub9bc",
      "type": "n8n-nodes-base.slack",
      "typeVersion": 2.2,
      "position": [
        1250,
        300
      ],
      "credentials": {
        "slackOAuth2Api": {
          "name": "<your credential>"
        }
      }
    }
  ],
  "connections": {
    "\ub9e4\uc77c \uc624\ud6c4 \ubcf4\uace0": {
      "main": [
        [
          {
            "node": "\uc624\ub298 \uba54\uc2dc\uc9c0 \uc218\uc9d1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\uc624\ub298 \uba54\uc2dc\uc9c0 \uc218\uc9d1": {
      "main": [
        [
          {
            "node": "\uba54\uc2dc\uc9c0 \uc815\ub9ac",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\uba54\uc2dc\uc9c0 \uc815\ub9ac": {
      "main": [
        [
          {
            "node": "AI \ubcf4\uace0\uc11c \uc0dd\uc131",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI \ubcf4\uace0\uc11c \uc0dd\uc131": {
      "main": [
        [
          {
            "node": "\ub178\uc158 \ubcf4\uace0\uc11c \uc800\uc7a5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ub178\uc158 \ubcf4\uace0\uc11c \uc800\uc7a5": {
      "main": [
        [
          {
            "node": "\ubcf4\uace0\uc11c \uc644\ub8cc \uc54c\ub9bc",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "settings": {
    "executionOrder": "v1",
    "saveManualExecutions": true,
    "callerPolicy": "workflowsFromSameOwner",
    "errorWorkflow": "",
    "timezone": "Asia/Seoul",
    "saveExecutionProgress": true,
    "executionTimeout": 3600,
    "saveDataErrorExecution": "all",
    "saveDataSuccessExecution": "all"
  },
  "staticData": null,
  "tags": [
    {
      "createdAt": "2026-03-09T00:00:00.000Z",
      "updatedAt": "2026-03-09T00:00:00.000Z",
      "id": "hr-automation",
      "name": "HR \uc790\ub3d9\ud654"
    },
    {
      "createdAt": "2026-03-09T00:00:00.000Z",
      "updatedAt": "2026-03-09T00:00:00.000Z",
      "id": "daily-report",
      "name": "\uc77c\uc77c \ubcf4\uace0"
    }
  ],
  "triggerCount": 1,
  "updatedAt": "2026-03-09T00:00:00.000Z",
  "versionId": "1"
}