{
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "node-id-1",
      "name": "Google Gemini Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
      "position": [
        1424,
        592
      ],
      "parameters": {
        "options": {}
      },
      "credentials": {
        "googlePalmApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "node-id-2",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -48,
        272
      ],
      "parameters": {
        "width": 304,
        "height": 480,
        "content": "## \ud83c\udf89 Replace BillyBot: Free Slack Employee Birthday & Anniversary Automation\n\n- Runs daily at 9 AM. Fetches employee data from Google Sheets, filters today's birthdays/anniversaries, generates personalized AI messages, and posts to Slack.\n- Sheet format: NO | Name | Email | Date of Birth (YYYY-MM-DD) | Joining Date (YYYY-MM-DD)\n- AI features: 12 rotating message styles, auto-calculates tenure, Slack markdown formatting\n- Cost: $0-20/month vs BillyBot's $1/employee/month ($600-2,400/year for 50-200 employees)"
      },
      "typeVersion": 1
    },
    {
      "id": "node-id-3",
      "name": "Daily 9AM Trigger",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        368,
        416
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "triggerAtHour": 9
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "node-id-4",
      "name": "Fetch Employee Data",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        592,
        416
      ],
      "parameters": {
        "options": {},
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "SHEET_ID_PLACEHOLDER",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/GOOGLE_SHEET_DOCUMENT_ID/edit#gid=SHEET_ID_PLACEHOLDER",
          "cachedResultName": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "list",
          "value": "GOOGLE_SHEET_DOCUMENT_ID",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/GOOGLE_SHEET_DOCUMENT_ID/edit",
          "cachedResultName": "employee-data-sheet"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4.7
    },
    {
      "id": "node-id-5",
      "name": "Check Birthday or Work Anniversary",
      "type": "n8n-nodes-base.if",
      "position": [
        864,
        416
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "loose"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "condition-id-1",
              "operator": {
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $now.toFormat('MM-dd') }}",
              "rightValue": "={{ DateTime.fromISO($json['Date of Birth']).toFormat('MM-dd') }}"
            },
            {
              "id": "condition-id-2",
              "operator": {
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $now.toFormat('MM-dd') }}",
              "rightValue": "={{ DateTime.fromISO($json['Joining Date']).toFormat('MM-dd') }}"
            }
          ]
        },
        "looseTypeValidation": true
      },
      "typeVersion": 2.2
    },
    {
      "id": "node-id-6",
      "name": "Combine Today's Celebrations",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        1184,
        400
      ],
      "parameters": {
        "options": {},
        "aggregate": "aggregateAllItemData"
      },
      "typeVersion": 1
    },
    {
      "id": "node-id-7",
      "name": "Generate Personalized Slack Message",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1424,
        400
      ],
      "parameters": {
        "text": "=todays date :- {{ $now }}\n\nemp data :- {{ $json.data.toJsonString() }}",
        "options": {
          "systemMessage": "=\ud83c\udf89 Slack Celebration Message Generator\nGenerate unique, heartfelt birthday and work anniversary messages for Slack that feel genuinely human-written, never templated.\n\ud83c\udfaf Core Rules\nUniqueness: Never repeat opening phrases, sentence structures, or tones across messages. Each celebration must feel completely different.\nAuthenticity: Write like a caring colleague, not a robot. Messages should be personal, warm, and memorable.\nVariation: Rotate through different styles, emojis, and approaches systematically.\n\ud83c\udfa8 Message Styles (Rotate These)\nBirthdays:\n\nJoyful - Pure celebration and excitement\nReflective - New beginnings and fresh chapters\nGrateful - Appreciation for their presence\nPlayful - Lighthearted with gentle humor\nAchievement - Celebrate growth and contributions\nWarm - Team family togetherness\n\nWork Anniversaries:\n\nMilestone - Highlight achievements and impact\nJourney - Their evolution and growth story\nTeam Impact - How they enrich the culture\nFuture-Forward - Excitement for what's ahead\nExcellence - Innovation and expertise\nLegacy - Foundational role (5+ years)\n\n\ud83d\udcdd Format Requirements\nStructure:\n*[Unique Opening + Name + Hook]* [Emoji Combo]\n[Specific wishes/appreciation - keep brief]\n_\u2014 from the team \ud83d\udc99_\nMarkdown:\n\n*bold* for names and key phrases\n_italic_ for signature only\nProper line breaks for readability\n\nEmojis (rotate):\n\nBirthday: \ud83c\udf82\u2728, \ud83c\udf89\ud83c\udf82, \ud83c\udf82\ud83c\udf1f, \ud83c\udf88\ud83c\udf89, \ud83c\udf82\ud83c\udf8a, \ud83c\udf1f\ud83c\udf81, \ud83c\udf89\u2728, \ud83c\udf82\ud83d\udcab\nAnniversary: \ud83c\udf8a\ud83d\ude80, \ud83c\udfc6\ud83c\udf89, \ud83c\udf8a\ud83d\udcaa, \u2b50\ud83c\udf8a, \ud83d\ude80\u2728, \ud83c\udf89\ud83c\udfc5, \ud83c\udf8a\u26a1, \ud83d\udc8e\ud83c\udf8a\n\n\ud83c\udfb2 Variation Rules\n\nOpening: Never repeat within 30 days\nTone: Never use same emotional tone consecutively\nLength: 1-3 lines per person, mobile-friendly\nAnniversary Years: Adapt message to tenure length\n\n\ud83d\udca1 Writing Tips\n\nUse first names only\nVary sentence length and rhythm\nKeep culturally inclusive and professional\nMake it screenshot-worthy\nEach person gets distinctly different treatment\n\nOutput: Generate ready-to-post Slack messages that colleagues will genuinely react to and appreciate."
        },
        "promptType": "define"
      },
      "typeVersion": 2
    },
    {
      "id": "node-id-8",
      "name": "Post Celebration to Slack Channel",
      "type": "n8n-nodes-base.slack",
      "position": [
        1808,
        400
      ],
      "parameters": {
        "text": "={{ $json.output }}",
        "select": "channel",
        "channelId": {
          "__rl": true,
          "mode": "list",
          "value": "SLACK_CHANNEL_ID",
          "cachedResultName": "your-channel-name"
        },
        "otherOptions": {
          "includeLinkToWorkflow": false
        }
      },
      "credentials": {
        "slackApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.3
    }
  ],
  "connections": {
    "Daily 9AM Trigger": {
      "main": [
        [
          {
            "node": "Fetch Employee Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Employee Data": {
      "main": [
        [
          {
            "node": "Check Birthday or Work Anniversary",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Google Gemini Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Generate Personalized Slack Message",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Combine Today's Celebrations": {
      "main": [
        [
          {
            "node": "Generate Personalized Slack Message",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check Birthday or Work Anniversary": {
      "main": [
        [
          {
            "node": "Combine Today's Celebrations",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Personalized Slack Message": {
      "main": [
        [
          {
            "node": "Post Celebration to Slack Channel",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}