{
  "id": "nWQ4mxLIgIk7eipH",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "4 Viral News to AI Avatar Videos",
  "tags": [],
  "nodes": [
    {
      "id": "c340145f-6843-41a9-ac3a-27adf4fe1abf",
      "name": "Schedule Trigger",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -2224,
        976
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "triggerAtHour": 10
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "24fc9cb6-00eb-47f4-938e-6c895d55f930",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2288,
        560
      ],
      "parameters": {
        "color": 5,
        "width": 940,
        "height": 868,
        "content": "# Research Industry News using Perplexity\n\n- Sign up for Perplexity, setup billing, and create API key: https://www.perplexity.ai/account/api/keys\n- Update your niche/industry in the Perplexity prompt"
      },
      "typeVersion": 1
    },
    {
      "id": "5a6e58be-ddc5-46b2-bde0-b0ad59789136",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2032,
        -432
      ],
      "parameters": {
        "color": 6,
        "width": 864,
        "height": 944,
        "content": "# FULL TUTORIAL\n\n## Tutorial\n\nhttps://help.blotato.com/api/templates/3-hackernews-to-ai-clone-videos\n\n## Description\n\nThis fully automated AI Avatar Viral News system researches the latest trending news in your niche or industry, then generates talking head AI clone videos, WITHOUT having to film or edit yourself. It combines ChatGPT, Perplexity, HeyGen, and Blotato to research, create, and auto-post talking head AI avatar videos to every social media platform, every single day.\n\n## Overview\n\n**1. Trigger: Schedule**\n- Configured to run once daily at 10am\n\n**2. AI Researcher**\n- Call Perplexity to research the top 10 latest news in your industry\n- Select news story most likely to go viral\n- Compile detailed factual report on selected news story\n\n**3. AI Writer**\n- AI writes monologue script, video caption, and short title\n\n**4. Create Avatar Video**\n- Call Heygen API (requires paid API plan), specifying your avatar ID and voice ID\n- Create avatar video, optionally passing in an image/video background if you have a green screen avatar\n\n**5. Get Video**\n- Wait awhile, then fetch completed avatar video\n- Upload video to Blotato\n\n**6. Publish to Social Media via Blotato**\n- Connect your Blotato account\n- Choose your social accounts\n- Either post immediately or schedule for later"
      },
      "typeVersion": 1
    },
    {
      "id": "dd96ed83-e655-4514-9edf-369a48eb67f6",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2080,
        800
      ],
      "parameters": {
        "color": 2,
        "width": 182,
        "height": 148,
        "content": "# Setup 1\n\nEdit prompt for your niche/industry"
      },
      "typeVersion": 1
    },
    {
      "id": "2d14361b-3535-48e9-98dc-a87bb1da09a6",
      "name": "AI Writer",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        -1616,
        976
      ],
      "parameters": {
        "modelId": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-5",
          "cachedResultName": "GPT-5"
        },
        "options": {},
        "messages": {
          "values": [
            {
              "role": "system",
              "content": "=# TASK\n1. Analyze the following viral news story:\n<news>\n{{ $('AI Research - Report').item.json.message }}\n</news>\n\n2. Write a conversational monologue script for an AI avatar video, following these guidelines:\n   - The script should be approximately 30 seconds when spoken aloud.\n   - Include lots of factual details and statistics from the article.\n   - Use 6th grade reading level.\n   - Balanced viewpoint.\n   - First sentence should create an irresistible curiosity gap to hook viewers.\n   - Replace the last sentence with this CTA: \"Hit follow to stay up to date!\"\n   - ONLY output the exact video script. Do not output anything else. NEVER include intermediate thoughts, notes, or formatting.\n\n3. Write an SEO-optimized caption that will accompany the video, following a similar structure as the EXAMPLE below, max 5 hashtags:\n\n<example>\nMany people have recently asked me about ask engine optimization, which is all about optimizing your website and existing content, so it can be pulled into ChatGPT and other generative AI tools. Consider that generative AI tools tend to be more conversational in nature and have a Q&A type format, so search engines will want to pull in snippets that concisely answer a user\u2019s question.\n\n- what is ask engine optimization in the age of AI?\n- How does traditional SEO compare to ask engine optimization today?\n- top tips and tricks to get started with ask engine optimization?\n\n#ai #askengineoptimization #chatgpt #seo\n</example>\n\n4. Write 1 viral sentence, max 8 words, summarizing the content, use 6th grade language, balanced neutral perspective, no emojis, no punctuation except `?` or `!`.\n\n# OUTPUT\n\nYou will output structured JSON in the following format, where `script` is the output of step 2, `caption` is the output of step 3, and `title` is the output of step 4:\n\n```\n{\n  \"script\": \"Monologue script to be spoken by AI avatar\",\n  \"caption\": \"Long SEO-optimized video caption\",\n  \"title\": \"Short video title\"\n}\n```"
            }
          ]
        },
        "simplify": false,
        "jsonOutput": true
      },
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.8
    },
    {
      "id": "66a341d1-04be-46bd-a084-ba9aaa1cda7e",
      "name": "AI Research - Report",
      "type": "n8n-nodes-base.perplexity",
      "position": [
        -1824,
        976
      ],
      "parameters": {
        "model": "sonar-pro",
        "options": {},
        "messages": {
          "message": [
            {
              "content": "=# INSTRUCTIONS\n\nComplete the following tasks, in order:\n\n1. Out of the 10 news stories listed below, select the ONE top news story that is most likely to go viral on social media. It should have broad appeal and contain something unique, controversial, or vitally important information that millions of people should know.\n\n<news>\n{{ $('AI Research - Top 10').item.json.message }}\n</news>\n\n2. Research more information about the top news story you selected in step 2.\n\n3. Your final output should be a detailed report of the top story you've selected. It should be dense with factual data, statistics, sources, and key information based on your research. Include reasons why this story would perform well on social media. Include why a \"normal person\" in this industry should care about this news."
            }
          ]
        },
        "simplify": true,
        "requestOptions": {}
      },
      "credentials": {
        "perplexityApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "4e2476d1-930d-4194-8143-a0eab762720a",
      "name": "AI Research - Top 10",
      "type": "n8n-nodes-base.perplexity",
      "position": [
        -2032,
        976
      ],
      "parameters": {
        "model": "sonar-pro",
        "options": {
          "searchRecency": "day"
        },
        "messages": {
          "message": [
            {
              "content": "Research the top 10 trending news items in my industry from the past 24 hours.\n\n- Industry: real estate"
            }
          ]
        },
        "simplify": true,
        "requestOptions": {}
      },
      "credentials": {
        "perplexityApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "e6048a83-57ff-48c1-b2bd-761dd1b9b596",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        944,
        1312
      ],
      "parameters": {
        "color": 7,
        "width": 288,
        "height": 192,
        "content": "# Error Report\n\n\ud83d\udc49 View run logs and results.\n\n\ud83d\udc49 API Dashboard:\n https://my.blotato.com/api-dashboard"
      },
      "typeVersion": 1
    },
    {
      "id": "ba1eded1-5f8d-4b2d-a493-829595aa6b74",
      "name": "Error Report",
      "type": "n8n-nodes-base.merge",
      "position": [
        1024,
        928
      ],
      "parameters": {
        "numberInputs": 9
      },
      "notesInFlow": false,
      "typeVersion": 3.2
    },
    {
      "id": "06af15ae-55bf-42d0-850f-1033bc8ce545",
      "name": "Sticky Note8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1344,
        160
      ],
      "parameters": {
        "color": 7,
        "width": 608,
        "height": 1632,
        "content": "# Platform Specific Notes\n\n## Tiktok\nYou can post images, videos, and slideshows. Your Tiktok account must be warmed up before using Blotato, otherwise you'll get low views. [Follow this warm up guide](https://help.blotato.com/platforms/tiktok/brand-new-accounts). \n\nCheck out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/tiktok\n\n## Linkedin\nYou can post text, images, videos, and PDF carousels. Check out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/linkedin\n\n## Facebook\nYou can post text, images, regular videos, and reels. Check out best practices and troubleshooting FAQs\nhttps://help.blotato.com/platforms/facebook\n\n## Instagram\nYou can post images, reels, stories, and slideshows. Check out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/instagram\n\n## Twitter\nYou can post text, images, and videos. You can post a long-form thread by clicking \"Show Advanced Settings\". Check out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/twitter\n\n## Threads\nYou can post text, images, and videos. You can post a long-form thread by clicking \"Show Advanced Settings\". Check out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/threads\n\n## Bluesky\nYou can post text, images, and videos. You can post a long-form thread by clicking \"Show Advanced Settings\". Check out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/bluesky\n\n## Youtube\nYou can post Youtube shorts and long-form videos. You don't need to do anything. Youtube automatically posts Shorts if your video is <2 minutes and 9:16 aspect ratio.\n\nBrand new Youtube accounts are limited to a few posts per day via API. You can still upload manually through Youtube website. This restriction is directly from Youtube and is gradually lifted as you post consistently.\n\nCheck out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/youtube\n\n## Pinterest\nYou can post image and video pins. You must warm up your Pinterest account by posting a few pins per day, gradually ramping up.\n\nHow to Get Your Pinterest Board ID:\nGo to Blotato, create a Pinterest post, click Publish, and you'll see your board IDs. Copy board ID to here.\n\nCheck out best practices and troubleshooting FAQs:\nhttps://help.blotato.com/platforms/pinterest\n\n## Need More Help?\n\nLog into Blotato.com\nClick support button in bottom right corner.\nSabrina Ramonov\ud83c\udf44 replies within 24 hours most weekdays."
      },
      "typeVersion": 1
    },
    {
      "id": "c16ccf28-4f72-46fb-b5c9-f49f7af39236",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        480,
        240
      ],
      "parameters": {
        "color": 2,
        "width": 320,
        "height": 176,
        "content": "# Setup 2\n1. Open each node\n2. Select your social account\n3. Deactivate platforms you don't need\n3. \ud83d\udc49 **You don't need to do anything else!**"
      },
      "typeVersion": 1
    },
    {
      "id": "46c34ea2-6536-4496-bc4c-d1ff0b952d67",
      "name": "Sticky Note10",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        352,
        -48
      ],
      "parameters": {
        "color": 4,
        "width": 912,
        "height": 1968,
        "content": "# Post Everywhere\n\n## IMPORTANT\nDo not post the same image/video over and over again, otherwise it will be flagged as spam. Make sure to disclose AI generated content if you're using avatars.\n\n\ud83d\udc49  **Blotato API Docs**: https://help.blotato.com/api\n\u2705  **Troubleshoot Errors**: https://my.blotato.com/api-dashboard\n\ud83d\udcf7  **Media Requirements**: https://help.blotato.com/api/media\n\ud83d\udee0\ufe0f  **Contact help**: log into blotato > click support button in bottom right corner"
      },
      "typeVersion": 1
    },
    {
      "id": "2a607887-2c28-4bb8-9f6d-22ce8a5e17ad",
      "name": "Sticky Note11",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -368,
        1200
      ],
      "parameters": {
        "color": 7,
        "width": 320,
        "content": "## Troubleshooting Checklist\n- HeyGen API paid plan\n- make sure you copied your avatar ID correctly, not the group avatar ID\n- If your script is long, it takes more time for your video to finish"
      },
      "typeVersion": 1
    },
    {
      "id": "6f3a7aa9-e65d-4078-8e67-0635462739eb",
      "name": "Sticky Note12",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1264,
        560
      ],
      "parameters": {
        "color": 3,
        "width": 1536,
        "height": 868,
        "content": "# Create AI Clone Video Using HeyGen\n\n- This requires HeyGen API plan (paid); the free plan is insufficient: https://www.heygen.com/api-pricing\n- If you have a long script, you may need to increase the WAIT time.\n- You can use a custom Elevenlabs voice by integrating Elevenlabs within HeyGen web app.\n- Tutorial on how to create a high-quality avatar and voice clone: https://youtu.be/_jogmHuuKXk\n- If you want a background video playing behind your avatar: (1) ensure you have an avatar with background removed which requires a higher tier plan; (2) open SETUP HEYGEN node and set parameter 'has_background_video' to true; (3) open SETUP HEYGEN node and replace video URL in parameter 'background_video_url'"
      },
      "typeVersion": 1
    },
    {
      "id": "fc580f31-1a48-4b75-b1a2-10778459d271",
      "name": "Sticky Note13",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1232,
        1136
      ],
      "parameters": {
        "color": 2,
        "width": 182,
        "height": 116,
        "content": "# Setup 1\n\nFill out \"Setup Heygen\""
      },
      "typeVersion": 1
    },
    {
      "id": "b61a4fed-6aa7-4fb1-b604-cc3086515afc",
      "name": "Sticky Note14",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1040,
        -144
      ],
      "parameters": {
        "color": 6,
        "width": 896,
        "height": 640,
        "content": "# Setup\n\n- Sign up for Perplexity.ai and setup your API Billing.\n- Generate your Perplexity API Key: https://www.perplexity.ai/account/api/keys\n- Sign up for Blotato.com\n- Generate Blotato API Key by going to Settings > API > Generate API Key (paid feature only)\n- If you're using n8n, ensure you have \"Verified Community Nodes\" enabled in your n8n Admin Panel. Then, install \"Blotato\" verified community node.\n- Create Blotato credential\n- Sign up for Heygen web plan and API plan\n- Paste your Heygen API key\n- Paste your Heygen avatar ID\n- Paste your Heygen voice ID\n- Complete the 2 setup steps in BROWN sticky notes in this template\n- If you want a background image/video behind your avatar: (1) ensure you have an avatar with background removed which requires a higher tier plan; (2) open SETUP HEYGEN node and set parameter 'has_background_video' to `true`; (3) open SETUP HEYGEN node and replace video URL in parameter 'background_video_url'. I only recommend doing this AFTER the full workflow is operational.\n\n## Tips and Tricks\n\n- While testing: enable only 1 social platform, and deactivate the rest for testing purposes. Update the AI agent node\u2019s prompt to return a 5-second script, rather than 30 seconds, to reduce the processing duration.\n- Go to Heygen and check that your avatar video is being processed.\n- After the workflow finishes, check your social media account for the final post.\n- If successful, then enable another social media node, and continue testing."
      },
      "typeVersion": 1
    },
    {
      "id": "5bc4de30-adf9-487b-8a00-e3e7955b4aa3",
      "name": "Setup Heygen",
      "type": "n8n-nodes-base.set",
      "position": [
        -1184,
        976
      ],
      "parameters": {
        "mode": "raw",
        "options": {},
        "jsonOutput": "{\n  \"heygen_api_key\": \"\",\n  \"avatar_id\": \"\",\n  \"voice_id\": \"\",\n  \"has_background_video\": false,\n  \"background_video_url\": \"https://database.blotato.io/storage/v1/object/public/public_media/4ddd33eb-e811-4ab5-93e1-2cd0b7e8fb3f/videogen2-render-e6b398a2-5859-4a77-88ef-2345bcefdc98.mp4\"\n}\n"
      },
      "typeVersion": 3.4
    },
    {
      "id": "901cf3d9-9393-49a1-abaa-d9b05e657c64",
      "name": "If",
      "type": "n8n-nodes-base.if",
      "position": [
        -1024,
        976
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "73001c6b-fae2-48cd-b0a6-aa453b837902",
              "operator": {
                "type": "boolean",
                "operation": "true",
                "singleValue": true
              },
              "leftValue": "={{ $('Setup Heygen').item.json.has_background_video }}",
              "rightValue": ""
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "da150126-3920-44f1-89ad-b529e96b0969",
      "name": "Create Avatar Video WITH Background Video",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -816,
        864
      ],
      "parameters": {
        "url": "https://api.heygen.com/v2/video/generate",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"video_inputs\": [\n    {\n      \"character\": {\n        \"type\": \"avatar\",\n        \"avatar_id\": \"{{ $('Setup Heygen').item.json.avatar_id }}\",\n        \"avatar_style\": \"normal\",\n        \"scale\": 1.0,\n        \"offset\": {\n          \"x\": 0.15,\n          \"y\": 0.15\n        },\n        \"matting\": true\n      },\n      \"voice\": {\n        \"type\": \"text\",\n        \"input_text\":  {{ $('AI Writer').item.json.choices[0].message.content.script.toJsonString() }},\n        \"voice_id\": \"{{ $('Setup Heygen').item.json.voice_id }}\",\n        \"speed\": 1.1,\n        \"pitch\": 50,\n        \"emotion\": \"Excited\"\n      },\n      \"background\": {\n        \"type\": \"video\",\n        \"url\": \"{{ $('Setup Heygen').item.json.background_video_url }}\",\n        \"play_style\": \"loop\",\n        \"fit\": \"cover\"\n      }\n    }\n  ],\n  \"dimension\": {\n    \"width\": 720,\n    \"height\": 1280\n  },\n  \"aspect_ratio\": \"9:16\",\n  \"caption\": false,\n  \"title\": \"{{ $('AI Writer').item.json.choices[0].message.content.title }}\"\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "headerParameters": {
          "parameters": [
            {
              "name": "X-Api-Key",
              "value": "={{ $('Setup Heygen').item.json.heygen_api_key }}"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "b3916543-e72d-4601-92eb-538e50c65daf",
      "name": "Create Avatar Video WITHOUT Background Video",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -816,
        1088
      ],
      "parameters": {
        "url": "https://api.heygen.com/v2/video/generate",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"video_inputs\": [\n    {\n      \"character\": {\n        \"type\": \"avatar\",\n        \"avatar_id\": \"{{ $('Setup Heygen').item.json.avatar_id }}\",\n        \"avatar_style\": \"normal\",\n        \"scale\": 1.0\n      },\n      \"voice\": {\n        \"type\": \"text\",\n        \"input_text\": {{ $('AI Writer').item.json.choices[0].message.content.script.toJsonString() }},\n        \"voice_id\": \"{{ $('Setup Heygen').item.json.voice_id }}\",\n        \"speed\": 1.1,\n        \"pitch\": 50,\n        \"emotion\": \"Excited\"\n      }\n    }\n  ],\n  \"dimension\": {\n    \"width\": 720,\n    \"height\": 1280\n  },\n  \"aspect_ratio\": \"9:16\",\n  \"caption\": false,\n  \"title\": \"{{ $('AI Writer').item.json.choices[0].message.content.title }}\"\n}",
        "sendBody": true,
        "sendHeaders": true,
        "specifyBody": "json",
        "headerParameters": {
          "parameters": [
            {
              "name": "X-Api-Key",
              "value": "={{ $('Setup Heygen').item.json.heygen_api_key }}"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "24d099e6-c4bc-4028-99f6-47a29352c6cc",
      "name": "Merge",
      "type": "n8n-nodes-base.merge",
      "position": [
        -608,
        976
      ],
      "parameters": {},
      "typeVersion": 3.2
    },
    {
      "id": "dd17bf15-6d98-4208-8db8-f82487038e9d",
      "name": "Wait",
      "type": "n8n-nodes-base.wait",
      "position": [
        -400,
        976
      ],
      "parameters": {
        "unit": "minutes",
        "amount": 1
      },
      "typeVersion": 1.1,
      "alwaysOutputData": false
    },
    {
      "id": "7a8c4319-4fd8-41cc-a769-ab672bc27839",
      "name": "Get Avatar Video",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -272,
        976
      ],
      "parameters": {
        "url": "https://api.heygen.com/v1/video_status.get",
        "options": {},
        "sendQuery": true,
        "sendHeaders": true,
        "queryParameters": {
          "parameters": [
            {
              "name": "video_id",
              "value": "={{ $('Merge').item.json.data.video_id }}"
            }
          ]
        },
        "headerParameters": {
          "parameters": [
            {
              "name": "X-Api-Key",
              "value": "={{ $('Setup Heygen').item.json.heygen_api_key }}"
            }
          ]
        }
      },
      "typeVersion": 4.2
    },
    {
      "id": "cd28cb8f-6fa4-4ebe-889a-9a596fb58e94",
      "name": "If Video Done",
      "type": "n8n-nodes-base.if",
      "position": [
        -144,
        976
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 2,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "loose"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "e511deb8-8e4c-45db-aa35-18f43a0552b6",
              "operator": {
                "name": "filter.operator.equals",
                "type": "string",
                "operation": "equals"
              },
              "leftValue": "={{ $('Get Avatar Video').item.json.data.status }}",
              "rightValue": "completed"
            }
          ]
        },
        "looseTypeValidation": true
      },
      "typeVersion": 2.2
    },
    {
      "id": "bca4e4bc-05a0-4cf5-a472-9647f958212a",
      "name": "Upload media",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "position": [
        112,
        976
      ],
      "parameters": {
        "mediaUrl": "={{ $('Get Avatar Video').item.json.data.video_url }}",
        "resource": "media"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "1374d8d1-fbd1-4d58-a46d-1c171bb79339",
      "name": "Tiktok [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "maxTries": 2,
      "position": [
        592,
        448
      ],
      "parameters": {
        "options": {},
        "platform": "tiktok",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "199",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/199",
          "cachedResultName": "sabrina_ramonov"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.caption }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}",
        "postCreateTiktokOptionIsAiGenerated": true
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "retryOnFail": false,
      "typeVersion": 2,
      "waitBetweenTries": 3000
    },
    {
      "id": "0c693f35-a5ad-4b8f-bb36-7e6012a862a9",
      "name": "Linkedin [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        608
      ],
      "parameters": {
        "options": {},
        "platform": "linkedin",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "4590",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/4590",
          "cachedResultName": "Sabrina Ramonov \ud83c\udf44"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.caption }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "f7fa456f-f887-4fa9-9fe5-ede1741e6388",
      "name": "Facebook [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        768
      ],
      "parameters": {
        "options": {},
        "platform": "facebook",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "369",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/369",
          "cachedResultName": "Sabrina Ramonov"
        },
        "facebookPageId": {
          "__rl": true,
          "mode": "list",
          "value": "161711670360847",
          "cachedResultUrl": "https://backend.blotato.com/v2/YOUR_AWS_SECRET_KEY_HERE",
          "cachedResultName": "Blotato"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.caption }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "f5f64e19-83ae-4122-85fd-ae759c5a7b93",
      "name": "Instagram [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "maxTries": 2,
      "position": [
        592,
        928
      ],
      "parameters": {
        "options": {},
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "28",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/28",
          "cachedResultName": "sabrina_ramonov"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.caption }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "retryOnFail": true,
      "typeVersion": 2,
      "waitBetweenTries": 5000
    },
    {
      "id": "23c3b5e8-b7a5-44d3-9223-dd537be2caf0",
      "name": "Twitter [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        1088
      ],
      "parameters": {
        "options": {},
        "platform": "twitter",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "38",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/38",
          "cachedResultName": "Sabrina_Ramonov"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.title }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "9a00bbc1-4883-40e6-90e1-bbeac1b24abe",
      "name": "Youtube [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        1248
      ],
      "parameters": {
        "options": {},
        "platform": "youtube",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "111",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/111",
          "cachedResultName": "Sabrina Ramonov \ud83c\udf44"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.caption }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}",
        "postCreateYoutubeOptionTitle": "={{ $('AI Writer').item.json.choices[0].message.content.title }}",
        "postCreateYoutubeOptionContainsSyntheticMedia": true
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "28f69c51-a437-4dcd-8743-f3502d9c5de3",
      "name": "Threads [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        1408
      ],
      "parameters": {
        "options": {},
        "platform": "threads",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "2537",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/2537",
          "cachedResultName": "sabrina_ramonov"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.title }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "2cde4480-332c-43b5-b8ef-d61833c88f0f",
      "name": "Bluesky [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        1568
      ],
      "parameters": {
        "options": {},
        "platform": "bluesky",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "6036",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/6036",
          "cachedResultName": "sabrinaramonov.bsky.social"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.title }}",
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "ea528671-63b8-40a7-aa4b-e0a4d35d44f2",
      "name": "Pinterest [BLOTATO]",
      "type": "@blotato/n8n-nodes-blotato.blotato",
      "onError": "continueErrorOutput",
      "position": [
        592,
        1728
      ],
      "parameters": {
        "options": {},
        "platform": "pinterest",
        "accountId": {
          "__rl": true,
          "mode": "list",
          "value": "358",
          "cachedResultUrl": "https://backend.blotato.com/v2/accounts/358",
          "cachedResultName": "sabrina_ramonov"
        },
        "postContentText": "={{ $('AI Writer').item.json.choices[0].message.content.caption }}",
        "pinterestBoardId": {
          "__rl": true,
          "mode": "id",
          "value": "1234"
        },
        "postContentMediaUrls": "={{ $('Upload media').item.json.url }}"
      },
      "credentials": {
        "blotatoApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "221f4aa7-eace-4f16-827d-0ca76e70ca48",
      "name": "Sticky Note15",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2064,
        1168
      ],
      "parameters": {
        "color": 7,
        "width": 384,
        "content": "## Troubleshooting Checklist\n- Perplexity API account must have billing funded\n- Update your industry in the prompt\n- Update the prompt if you want to research something specific"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "f4241d20-c3f5-402c-b79a-48b63e617359",
  "connections": {
    "If": {
      "main": [
        [
          {
            "node": "Create Avatar Video WITH Background Video",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Create Avatar Video WITHOUT Background Video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait": {
      "main": [
        [
          {
            "node": "Get Avatar Video",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Merge": {
      "main": [
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Writer": {
      "main": [
        [
          {
            "node": "Setup Heygen",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Setup Heygen": {
      "main": [
        [
          {
            "node": "If",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload media": {
      "main": [
        [
          {
            "node": "Tiktok [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Linkedin [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Facebook [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Instagram [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Twitter [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Youtube [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Threads [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Bluesky [BLOTATO]",
            "type": "main",
            "index": 0
          },
          {
            "node": "Pinterest [BLOTATO]",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If Video Done": {
      "main": [
        [
          {
            "node": "Upload media",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Avatar Video": {
      "main": [
        [
          {
            "node": "If Video Done",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "AI Research - Top 10",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Tiktok [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Bluesky [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 7
          }
        ]
      ]
    },
    "Threads [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 6
          }
        ]
      ]
    },
    "Twitter [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 4
          }
        ]
      ]
    },
    "Youtube [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 5
          }
        ]
      ]
    },
    "Facebook [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 2
          }
        ]
      ]
    },
    "Linkedin [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 1
          }
        ]
      ]
    },
    "Instagram [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 3
          }
        ]
      ]
    },
    "Pinterest [BLOTATO]": {
      "main": [
        [],
        [
          {
            "node": "Error Report",
            "type": "main",
            "index": 8
          }
        ]
      ]
    },
    "AI Research - Report": {
      "main": [
        [
          {
            "node": "AI Writer",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Research - Top 10": {
      "main": [
        [
          {
            "node": "AI Research - Report",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create Avatar Video WITH Background Video": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create Avatar Video WITHOUT Background Video": {
      "main": [
        [
          {
            "node": "Merge",
            "type": "main",
            "index": 1
          }
        ]
      ]
    }
  }
}