{
  "name": "Send personalized job application emails with Telegram, OpenAI, and Gmail",
  "nodes": [
    {
      "id": "b07613f6-04cc-46e2-a105-11190f1c229f",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -624,
        320
      ],
      "parameters": {
        "width": 500,
        "height": 520,
        "content": "## How it works\n\nThis workflow automates job applications through Telegram. Send a screenshot of any job posting to your Telegram bot, and AI will extract the job details, match them to your resume, a"
      }
    },
    {
      "id": "7230dd49-f98e-4659-8562-109582963196",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -64,
        320
      ],
      "parameters": {
        "width": 347,
        "height": 220,
        "content": "## Input routing\n\nReceives job post images or callback confirmations from Telegram and routes to the appropriate path"
      }
    },
    {
      "id": "a0a21348-1d90-406b-bfb2-dcd1329f5121",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        432,
        256
      ],
      "parameters": {
        "width": 492,
        "height": 140,
        "content": "## AI analysis and email generation\n\nExtracts job details from image, matches with resume, and generates personalized application email"
      }
    },
    {
      "id": "bd5b5afa-1233-4223-b10d-f4d3b411513d",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1104,
        256
      ],
      "parameters": {
        "width": 480,
        "height": 140,
        "content": "## Draft storage and user confirmation\n\nStores email draft in Redis and sends preview to user with approval button"
      }
    },
    {
      "id": "a76700c9-8fcb-46d0-8de3-4196a198f273",
      "name": "Telegram Trigger",
      "type": "n8n-nodes-base.telegramTrigger",
      "position": [
        -48,
        624
      ]
    },
    {
      "id": "68bcb3ea-c5fa-4618-b5d9-8d1438d61e6c",
      "name": "Build AI request payload",
      "type": "n8n-nodes-base.code",
      "position": [
        624,
        432
      ]
    },
    {
      "id": "dda0833a-5fbd-46d1-b36b-34833f30042f",
      "name": "Call OpenAI API",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        848,
        432
      ]
    },
    {
      "id": "4cc46606-de4f-402f-beb6-76ea7a433e18",
      "name": "Parse AI response",
      "type": "n8n-nodes-base.code",
      "position": [
        1072,
        432
      ]
    },
    {
      "id": "993f7770-de8b-404a-91f7-8da9f28a6e66",
      "name": "Store draft in Redis",
      "type": "n8n-nodes-base.redis",
      "position": [
        1296,
        432
      ]
    },
    {
      "id": "1f2c1707-3320-4117-acf3-ffb0a90201b7",
      "name": "Send preview to Telegram",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1520,
        432
      ]
    },
    {
      "id": "bc21e92c-3f22-4e2c-bc6d-466fe42c624f",
      "name": "Retrieve draft from Redis",
      "type": "n8n-nodes-base.redis",
      "position": [
        400,
        720
      ]
    },
    {
      "id": "6e490fa8-825f-4cf9-bc6d-17009186db01",
      "name": "Parse draft data",
      "type": "n8n-nodes-base.code",
      "position": [
        624,
        720
      ]
    },
    {
      "id": "687dd808-e352-48ef-b1e6-39752e8df277",
      "name": "Download resume from Drive",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        848,
        720
      ]
    },
    {
      "id": "0b57006e-2e50-40dd-b03d-74f7837d89f5",
      "name": "Notify immediate send",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1072,
        624
      ]
    },
    {
      "id": "1e37adf5-fa37-4433-9996-2f468bf99efb",
      "name": "Send email via Gmail",
      "type": "n8n-nodes-base.gmail",
      "position": [
        1744,
        816
      ]
    },
    {
      "id": "8f5b6d41-3b35-4033-b8f4-bbfc9e19cdc7",
      "name": "Wait before scheduled send",
      "type": "n8n-nodes-base.wait",
      "position": [
        1296,
        816
      ]
    },
    {
      "id": "c98f6140-35b6-4132-b08f-21a8f25ccfb9",
      "name": "Prepare scheduled send",
      "type": "n8n-nodes-base.code",
      "position": [
        1072,
        816
      ]
    },
    {
      "id": "56eb9b23-db15-4f41-9df5-90df54e778ff",
      "name": "Download resume for scheduled send",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        1520,
        816
      ]
    },
    {
      "id": "51ccaa4d-c3dc-4cff-b8df-68ff9d2a7214",
      "name": "Update Telegram status",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1296,
        624
      ]
    },
    {
      "id": "6c21800e-3510-43e0-9d2d-48767fb61426",
      "name": "Notify scheduled send complete",
      "type": "n8n-nodes-base.telegram",
      "position": [
        1968,
        816
      ]
    },
    {
      "id": "e4a80d39-4ec0-4230-9423-4fc5dc965e09",
      "name": "Route by message type",
      "type": "n8n-nodes-base.switch",
      "position": [
        176,
        624
      ]
    },
    {
      "id": "4ba5aaeb-8dc2-4ad4-b3ce-808faa8e16ce",
      "name": "Show typing indicator",
      "type": "n8n-nodes-base.telegram",
      "position": [
        400,
        432
      ]
    }
  ],
  "connections": {
    "Call OpenAI API": {
      "main": [
        [
          {
            "node": "Parse AI response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse draft data": {
      "main": [
        [
          {
            "node": "Download resume from Drive",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Telegram Trigger": {
      "main": [
        [
          {
            "node": "Route by message type",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse AI response": {
      "main": [
        [
          {
            "node": "Store draft in Redis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send email via Gmail": {
      "main": [
        [
          {
            "node": "Notify scheduled send complete",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Store draft in Redis": {
      "main": [
        [
          {
            "node": "Send preview to Telegram",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Notify immediate send": {
      "main": [
        [
          {
            "node": "Update Telegram status",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Route by message type": {
      "main": [
        [
          {
            "node": "Show typing indicator",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Retrieve draft from Redis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Show typing indicator": {
      "main": [
        [
          {
            "node": "Build AI request payload",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Prepare scheduled send": {
      "main": [
        [
          {
            "node": "Wait before scheduled send",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Build AI request payload": {
      "main": [
        [
          {
            "node": "Call OpenAI API",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Retrieve draft from Redis": {
      "main": [
        [
          {
            "node": "Parse draft data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download resume from Drive": {
      "main": [
        [
          {
            "node": "Notify immediate send",
            "type": "main",
            "index": 0
          },
          {
            "node": "Prepare scheduled send",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait before scheduled send": {
      "main": [
        [
          {
            "node": "Download resume for scheduled send",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download resume for scheduled send": {
      "main": [
        [
          {
            "node": "Send email via Gmail",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}