{
  "name": "Create AI newsletters from YouTube with LangChain, Gemini, Apify & Gmail",
  "nodes": [
    {
      "id": "3e73c364-46f3-4c9f-8a63-a1f60ee491f9",
      "name": "Structured Output Parser1",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        3456,
        608
      ]
    },
    {
      "id": "ba883af4-bb38-452b-94e8-1970cf1a1ead",
      "name": "Convert Newsletter to HTML (AI)",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        3312,
        400
      ]
    },
    {
      "id": "f4a8e7b1-004f-4912-90f7-080d21d5c9b6",
      "name": "Sending Emails to all the Subscribers",
      "type": "n8n-nodes-base.gmail",
      "position": [
        3680,
        480
      ]
    },
    {
      "id": "0f3bdc82-1eac-4f73-a78d-4f0a7ad93cb0",
      "name": "On form submission",
      "type": "n8n-nodes-base.formTrigger",
      "position": [
        928,
        416
      ]
    },
    {
      "id": "07a77200-990c-4db6-8281-c417994090fb",
      "name": "HTTP Request2",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1488,
        128
      ]
    },
    {
      "id": "a67fcffa-eaa3-49e5-b5a2-5fc1415d3762",
      "name": "Merge",
      "type": "n8n-nodes-base.merge",
      "position": [
        2400,
        352
      ]
    },
    {
      "id": "03af34d4-125d-476a-abef-aaadb973285f",
      "name": "Aggregate",
      "type": "n8n-nodes-base.aggregate",
      "position": [
        2624,
        368
      ]
    },
    {
      "id": "8b6c2b24-7b82-402c-9fd5-beaa4afa6723",
      "name": "Structured Output Parser2",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        1840,
        320
      ]
    },
    {
      "id": "f7e10755-4e35-47fe-81e2-2b4e6a925779",
      "name": "Loop Over Items",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        3056,
        384
      ]
    },
    {
      "id": "414424e3-9640-4ac9-b2f8-e53b6f123f95",
      "name": "Get row(s) in sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        2848,
        368
      ]
    },
    {
      "id": "c42d0232-6dcf-4a01-88cd-4b8bba157f1e",
      "name": "AI Agent1",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1680,
        128
      ]
    },
    {
      "id": "0059f930-9451-4e7b-99b0-fc90f2766a16",
      "name": "Code in JavaScript",
      "type": "n8n-nodes-base.code",
      "position": [
        1536,
        576
      ]
    },
    {
      "id": "08ae6e3f-c665-424e-94a7-f93b25d497e8",
      "name": "AI Agent2",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1808,
        576
      ]
    },
    {
      "id": "42584ede-9c8f-4c4c-8584-d6328a71a3fd",
      "name": "Edit Fields",
      "type": "n8n-nodes-base.set",
      "position": [
        1536,
        816
      ]
    },
    {
      "id": "40c76cbc-ff4b-4579-9cdf-85863586676e",
      "name": "You Tube Transcript Scraper",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1344,
        576
      ]
    },
    {
      "id": "499f5c94-822f-4e47-8704-3c7effafd19c",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        272,
        48
      ],
      "parameters": {
        "width": 534,
        "height": 928,
        "content": "# Video → Newsletter AI Agent\n\nThis n8n workflow converts a YouTube video into a polished, email-ready newsletter. It scrapes the transcript, extracts a thumbnail/logo and brand color theme, uses mult"
      }
    },
    {
      "id": "9dcde39b-9e42-4783-a293-a7b64783b214",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        832,
        256
      ],
      "parameters": {
        "width": 294,
        "height": 384,
        "content": "## Workflow Input (Form Trigger)\nThis section collects the required inputs from the user through a form submission."
      }
    },
    {
      "id": "5bccab58-f443-47d7-994a-d303978c7d5e",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1152,
        -160
      ],
      "parameters": {
        "width": 1190,
        "height": 608,
        "content": "## Extract Brand Style & Colors\nThis block analyzes the provided brand website to determine the brand’s visual identity."
      }
    },
    {
      "id": "287201ba-2b24-40ed-967c-b1f70d8536be",
      "name": "You Tube Thumbnail Scraper",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1344,
        816
      ]
    },
    {
      "id": "ecd1c08a-7936-470b-a383-5c46cd26c5a4",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1152,
        464
      ],
      "parameters": {
        "width": 1190,
        "height": 544,
        "content": "## Fetch YouTube Transcript\nThis section retrieves the transcript and thumbnail from the YouTube video."
      }
    },
    {
      "id": "9b457210-34aa-4936-ab2b-ec8a27b58f05",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2368,
        208
      ],
      "parameters": {
        "width": 1478,
        "height": 592,
        "content": "## AI Processing, HTML Generation & Email Delivery\nThis section handles the core content generation and delivery of the newsletter."
      }
    },
    {
      "id": "97699901-a961-438e-b33a-b334a005a9bf",
      "name": "Google Gemini Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
      "position": [
        1792,
        768
      ]
    },
    {
      "id": "5f23ca4b-f0fd-441f-9304-460cde581ebe",
      "name": "Google Gemini Chat Model1",
      "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
      "position": [
        3312,
        624
      ]
    },
    {
      "id": "f3c78fce-5e7d-4cda-bd0f-9d534c1d2d3c",
      "name": "Information Extractor",
      "type": "@n8n/n8n-nodes-langchain.informationExtractor",
      "position": [
        1664,
        -32
      ]
    },
    {
      "id": "9c0f0a8a-18a0-41bc-96ca-2ff465f19d12",
      "name": "HTTP Request5",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        1488,
        -32
      ]
    },
    {
      "id": "d51b5ac2-ba70-405b-8264-bb67a2e2c7db",
      "name": "Save Newsletter Draft in Google Sheet1",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        3664,
        288
      ]
    }
  ],
  "connections": {
    "Merge": {
      "main": [
        [
          {
            "node": "Aggregate",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent1": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "AI Agent2": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 2
          }
        ]
      ]
    },
    "Aggregate": {
      "main": [
        [
          {
            "node": "Get row(s) in sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Edit Fields": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 3
          }
        ]
      ]
    },
    "HTTP Request2": {
      "main": [
        [
          {
            "node": "AI Agent1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "HTTP Request5": {
      "main": [
        [
          {
            "node": "Information Extractor",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items": {
      "main": [
        [],
        [
          {
            "node": "Convert Newsletter to HTML (AI)",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Code in JavaScript": {
      "main": [
        [
          {
            "node": "AI Agent2",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "On form submission": {
      "main": [
        [
          {
            "node": "HTTP Request2",
            "type": "main",
            "index": 0
          },
          {
            "node": "You Tube Transcript Scraper",
            "type": "main",
            "index": 0
          },
          {
            "node": "You Tube Thumbnail Scraper",
            "type": "main",
            "index": 0
          },
          {
            "node": "HTTP Request5",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get row(s) in sheet": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Information Extractor": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Google Gemini Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_languageModel",
            "index": 0
          },
          {
            "node": "AI Agent2",
            "type": "ai_languageModel",
            "index": 0
          },
          {
            "node": "Information Extractor",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Google Gemini Chat Model1": {
      "ai_languageModel": [
        [
          {
            "node": "Convert Newsletter to HTML (AI)",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser1": {
      "ai_outputParser": [
        [
          {
            "node": "Convert Newsletter to HTML (AI)",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser2": {
      "ai_outputParser": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "You Tube Thumbnail Scraper": {
      "main": [
        [
          {
            "node": "Edit Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "You Tube Transcript Scraper": {
      "main": [
        [
          {
            "node": "Code in JavaScript",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Convert Newsletter to HTML (AI)": {
      "main": [
        [
          {
            "node": "Sending Emails to all the Subscribers",
            "type": "main",
            "index": 0
          },
          {
            "node": "Save Newsletter Draft in Google Sheet1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Sending Emails to all the Subscribers": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}