{"workflow":{"id":12416,"name":"Analyze Meta ads daily with Google Gemini and Google Sheets","views":251,"recentViews":0,"totalViews":251,"createdAt":"2026-01-03T11:15:41.125Z","description":"# Analyze Meta ads with Gemini and Google Sheets\n\n**Stop manually exporting CSVs and start automating your marketing insights.**\n\nThis workflow is designed for Marketing Agencies, Freelancers, and Media Buyers who want to keep a daily pulse on their Meta (Facebook/Instagram) Ads performance without logging into Ads Manager.\n\nIt doesn't just scrape data; it uses **Google Gemini AI** to act as a virtual data analyst. It reviews your campaigns, identifies winning/losing creatives, and writes strategic suggestions for both your agency team and your clients.\n\n### 🚀 What this workflow does\n1. **Extracts Data:** Wakes up every morning (6:00 AM) to fetch yesterday's Ad and Campaign performance from the **Facebook Graph API**.\n2. **Cleans & Filters:** Automatically ignores paused or zero-spend campaigns to keep your reports clean.\n3. **Structuring:** Uses a Code node to group Ads intelligently under their respective Ad Sets and Campaigns.\n4. **AI Analysis:** Sends the structured data to **Google Gemini**. The AI analyzes CTR, CPC, and Spend to identify the \"Best Performing Ad\" and \"Worst Performing Ad\" per Ad Set.\n5. **Reporting:**\n   - Saves raw **Campaign Data** to Google Sheets.\n   - Saves raw **Ad Data** to Google Sheets.\n   - Saves **AI-Generated Insights** (Client & Agency suggestions) to a dedicated sheet.\n6. **Error Handling:** If anything breaks (e.g., API token expiry), it instantly sends you an alert via **Gmail** with the error details.\n\n### 💡 Key Features\n- **Zero-Spend Filter:** Keeps your spreadsheet tidy by excluding inactive ads.\n- **Hierarchical Data Processing:** Groups data logically so the AI understands the context of your tests.\n- **Dual-Perspective Insights:** The AI generates two types of advice:\n  - *For the Client:* Simple, performance-based updates.\n  - *For the Agency:* Technical optimization tips (e.g., \"Pause Ad B, Scale Ad A\").\n- **Robust Error Monitoring:** Includes a dedicated error workflow to notify you of failures.\n\n### 🛠️ Prerequisites\nTo use this template, you will need:\n- **Meta/Facebook Developer App:** A System User Access Token with `ads_read` permission.\n- **Google Cloud Console Project:** Enabled APIs for Google Sheets, Gmail, and Vertex AI (Gemini).\n- **Google Sheet:** A sheet with three tabs: `Campaigns`, `Ads`, and `AI_Insights`.\n\n### 📝 Setup Instructions\n1. **Configure Credentials:** Connect your Facebook Graph API and Google accounts in n8n.\n2. **Set Configuration Node:** Open the \"Set Configuration\" node and paste your `Ad Account ID` and `Email Address` for error alerts.\n3. **Link Google Sheet:** Open the three Google Sheets nodes and select your spreadsheet file.\n4. **Activate:** Turn on the workflow and let it run daily!\n\n---\n\n**Need help setting this up or want a custom automation for your agency?**\nI specialize in building agentic workflows for consultants and agencies.\n\n📧 **Contact me:** bakdaulet.mph@gmail.com","workflow":{"meta":{"instanceId":"ff6f82868b693a4c71d2b3456aa1713ca34108a67a7cfba73a7f8ee3c5ec8465","templateCredsSetupCompleted":true},"nodes":[{"id":"fead4f03-9842-47f8-838f-c5137b2f0d5a","name":"Template Guide","type":"n8n-nodes-base.stickyNote","position":[-368,-32],"parameters":{"width":486,"height":608,"content":"## Analyze Meta ads with Gemini and Google Sheets\n\n**How it works:**\n1.  **Extract:** Fetches Ad and Campaign data from Meta API (Yesterday's data).\n2.  **Process:** Aggregates data by Campaign and Ad Set using Code node.\n3.  **Analyze:** Sends data to Gemini to generate qualitative insights for both Client and Agency.\n4.  **Save:** Exports raw data and AI insights to Google Sheets.\n\n**Setup steps:**\n1.  **Configuration:** Update the `Set Configuration` node with your `Ad Account ID` and `Email`.\n2.  **Credentials:** Authenticate your `Facebook Graph API`, `Google Sheets`, `Gmail`, and `Google Gemini` credentials.\n3.  **Spreadsheet:** Create a Google Sheet and update the `Save...` nodes with your Spreadsheet ID.\n4. **Facebook Graph API** [Guide](https://docs.google.com/document/d/1ydWNom0TUVh5SkU9IymlpnM_NXbTqHeL_YetDLn-9m0/edit?usp=sharing)\n9. **Google sheets** [template](https://docs.google.com/spreadsheets/d/11M6Co13t9t2P7NtFaTm9VXHnzUHXO_RGYf-FRnHkS28/edit?usp=sharing)\n10. Use this format to pull the specific date range: `time_range[since]=YYYY-MM-DD&time_range[until]=YYYY-MM-DD`\n\n\nHappy setup,\nBakdaulet Abdikhan\n\nPS. Feel free to add slack/email nodes to notify alerts/updates ;)"},"typeVersion":1},{"id":"8936023f-8462-4525-aca0-1f76203fcbd6","name":"Get Config","type":"n8n-nodes-base.set","position":[1552,-240],"parameters":{"options":{},"assignments":{"assignments":[{"id":"678b725a-e235-48b1-904d-1fb7ea9ad061","name":"Ad Account ID","type":"string","value":"YOUR_ACT_ID_HERE"},{"id":"b0b6e2b9-6f30-4b53-a61d-485edac8d27b","name":"Email","type":"string","value":"user@example.com"}]}},"typeVersion":3.4},{"id":"193a9ee7-1c12-46cb-b318-f767137a316d","name":"Send Error Email","type":"n8n-nodes-base.gmail","position":[1776,-240],"webhookId":"5e1cc80b-8ca9-42f9-be63-617d0ef005ab","parameters":{"sendTo":"={{ $('Get Config').first().json.Email }}","message":"=<b>Error:</b> {{ $('Error Trigger').first().json.execution.error.message }}<br/>\n<b>Stack:</b> {{ $('Error Trigger').first().json.execution.error.stack }}<br/>\n<b>Last Node Executed:</b> {{ $('Error Trigger').first().json.execution.lastNodeExecuted }}","options":{"appendAttribution":false},"subject":"=N8N ERROR: Daily Ad Pulse for Ad Account {{ $('Get Config').first().json['Ad Account ID'] }} Failed"},"credentials":{"gmailOAuth2":{"id":"credential-id","name":"know.abou.ai.kz@gmail.com"}},"typeVersion":2.1},{"id":"a9d35f35-e8c1-42f9-bb5b-8ca26eefc6be","name":"Structure Data Hierarchy","type":"n8n-nodes-base.code","position":[784,128],"parameters":{"jsCode":"// Get all items from previous node\nconst allItems = $input.all();\n\n// Flatten everything into one array (each item.json is an ad)\nconst ads = allItems.map(item => item.json);\n\n// Prepare campaign grouping\nconst campaigns = {};\n\nfor (const ad of ads) {\n  const {\n    campaign_id,\n    campaign_name,\n    adset_id,\n    adset_name,\n    ad_id,\n    ad_name,\n    spend,\n    reach,\n    impressions,\n    clicks,\n    ctr,\n    cpc,\n    cpm,\n    date_start,\n    date_stop,\n    results\n  } = ad;\n\n  // --- Group by Campaign ---\n  if (!campaigns[campaign_id]) {\n    campaigns[campaign_id] = {\n      campaign_id,\n      campaign_name,\n      adsets: {}\n    };\n  }\n\n  // --- Group by Adset ---\n  if (!campaigns[campaign_id].adsets[adset_id]) {\n    campaigns[campaign_id].adsets[adset_id] = {\n      adset_id,\n      adset_name,\n      ads: []\n    };\n  }\n\n  // --- Add Ad ---\n  campaigns[campaign_id].adsets[adset_id].ads.push({\n    ad_id,\n    ad_name,\n    metrics: {\n      spend,\n      reach,\n      impressions,\n      clicks,\n      ctr,\n      cpc,\n      cpm\n    },\n    results,\n    date: {\n      start: date_start,\n      stop: date_stop\n    }\n  });\n}\n\n// Convert nested objects to arrays\nconst output = Object.values(campaigns).map(campaign => ({\n  ...campaign,\n  adsets: Object.values(campaign.adsets)\n}));\n\n// Return final grouped data\nreturn [{ json: { campaigns: output } }];\n"},"typeVersion":2},{"id":"29c78e97-ea13-4ff3-9a9e-329a9ac3eb7d","name":"Write Insights","type":"@n8n/n8n-nodes-langchain.chainLlm","position":[1216,128],"parameters":{"text":"=Analyze the following Meta Ads data and return structured insights.\n\nData:\n{{ JSON.stringify($json.campaigns, null, 2) }}\n\nRules:\n- Always include both campaign-level and adset-level insights.\n- Write in a professional, concise tone suitable for client reports.\n- For each adset, identify:\n  - best_performing_ad\n  - worst_performing_ad\n  - adset_suggestion (1–2 short sentences)\n- For each campaign, summarize overall campaign performance with campaign_suggestion (1–2 sentences).\n\nReturn only valid JSON following this schema:\n\n[\n  {\n    \"campaign_name\": \"\",\n    \"campaign_id\": \"\",\n    \"adsets\": [\n      {\n        \"adset_name\": \"\",\n        \"adset_id\": \"\",\n        \"best_performing_ad\": \"\",\n        \"worst_performing_ad\": \"\",\n        \"adset_suggestion\": \"\"\n      }\n    ],\n    \"campaign_suggestion\": \"\"\n  }\n]\n","batching":{},"messages":{"messageValues":[{"message":"=You are MetaInsightsGPT — an expert Meta Ads performance analyst AI working inside a marketing agency automation system.\n\nYour responsibilities:\n- Read structured JSON ad performance data (campaigns → adsets → ads).\n- Evaluate ads objectively using spend, CTR, CPC, CPM, and conversions (if available).\n- Identify the best- and worst-performing ads per adset.\n- Generate useful, data-driven insights:\n  - For the agency → what to optimize or scale.\n  - For the client → what’s working and why.\n- Write in English.\n\nPerformance logic:\n- Prioritize CTR and conversions as success indicators.\n- If conversions missing, use CTR/CPC ratio.\n- Consider spend and impressions for significance.\n- Ignore zero-impression ads.\n- Never use vague words like “good”, “bad”, “try more”.\n- Always quantify insights (e.g., “CTR 2.3% vs. 0.7%”).\n- Output must be strictly valid JSON (no markdown, no commentary).\n\nYou output insights in a consistent JSON structure so they can be parsed into Google Sheets.\n"},{"type":"AIMessagePromptTemplate","message":"=[\n  {\n    \"campaign_name\": \"Engagement Campaign\",\n    \"campaign_id\": \"1234567890\",\n    \"adsets\": [\n      {\n        \"adset_name\": \"Broad Targeting\",\n        \"adset_id\": \"0987654321\",\n        \"best_performing_ad\": \"Video_Variant_A\",\n        \"worst_performing_ad\": \"Image_Variant_B\",\n        \"adset_suggestion\": \"Video_Variant_A achieved 0.9% CTR with 32 clicks. Image_Variant_B underperformed with 0 clicks; consider pausing.\"\n      }\n    ],\n    \"campaign_suggestion\": \"This campaign performs efficiently (CTR ~0.9%) but has uneven engagement across adsets. Reallocate budget toward higher-performing ads.\"\n  }\n]\n"}]},"promptType":"define","hasOutputParser":true},"typeVersion":1.7},{"id":"8ccc0b9f-d870-4e5f-a0d0-469bb2bfecc0","name":"Save AI Insights","type":"n8n-nodes-base.googleSheets","position":[2032,128],"parameters":{"columns":{"value":{"Date":"={{ $now.minus({ days: 1 }).toFormat('yyyy-MM-dd') }}","Ad Set":"={{ $json.adsets[0].adset_name }}","Best Ad":"={{ $json.adsets[0].best_performing_ad }}","Campaign":"={{ $json.campaign_name }}","Worst Ad":"={{ $json.adsets[0].worst_performing_ad }}","Agency Suggestion":"={{ $json.adsets[0].suggestion_for_agency }}","Client Suggestion":"={{ $json.adsets[0].suggestion_for_client }}"},"schema":[{"id":"Date","type":"string","display":true,"required":false,"displayName":"Date","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Campaign","type":"string","display":true,"required":false,"displayName":"Campaign","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Ad Set","type":"string","display":true,"required":false,"displayName":"Ad Set","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Best Ad","type":"string","display":true,"required":false,"displayName":"Best Ad","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Worst Ad","type":"string","display":true,"required":false,"displayName":"Worst Ad","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Agency Suggestion","type":"string","display":true,"required":false,"displayName":"Agency Suggestion","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Client Suggestion","type":"string","display":true,"required":false,"displayName":"Client Suggestion","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"operation":"append","sheetName":{"__rl":true,"mode":"name","value":"AI_Insights"},"documentId":{"__rl":true,"mode":"id","value":"YOUR_SPREADSHEET_ID_HERE"}},"credentials":{"googleSheetsOAuth2Api":{"id":"credential-id","name":"Google Sheets account 2"}},"typeVersion":4.7},{"id":"1980b51b-fb7a-4b18-95aa-9cb02ec16158","name":"Save Ad Data","type":"n8n-nodes-base.googleSheets","position":[784,304],"parameters":{"columns":{"value":{"cpc":"={{ $json.cpc }}","cpm":"={{ $json.cpm }}","ctr":"={{ $json.ctr }}","date":"={{ $json.date_stop }}","ad_id":"={{ $json.ad_id }}","reach":"={{ $json.reach }}","spend":"={{ $json.spend }}","clicks":"={{ $json.clicks }}","ad_name":"={{ $json.ad_name }}","results":"={{ $json.results[0].values[0].value }}","adset_id":"={{ $json.adset_id }}","adset_name":"={{ $json.adset_name }}","campaign_id":"={{ $json.campaign_id }}","impressions":"={{ $json.impressions }}","campaign_name":"={{ $json.campaign_name }}"},"schema":[{"id":"date","type":"string","display":true,"required":false,"displayName":"date","defaultMatch":false,"canBeUsedToMatch":true},{"id":"campaign_id","type":"string","display":true,"required":false,"displayName":"campaign_id","defaultMatch":false,"canBeUsedToMatch":true},{"id":"campaign_name","type":"string","display":true,"required":false,"displayName":"campaign_name","defaultMatch":false,"canBeUsedToMatch":true},{"id":"adset_id","type":"string","display":true,"required":false,"displayName":"adset_id","defaultMatch":false,"canBeUsedToMatch":true},{"id":"adset_name","type":"string","display":true,"required":false,"displayName":"adset_name","defaultMatch":false,"canBeUsedToMatch":true},{"id":"ad_id","type":"string","display":true,"required":false,"displayName":"ad_id","defaultMatch":false,"canBeUsedToMatch":true},{"id":"ad_name","type":"string","display":true,"required":false,"displayName":"ad_name","defaultMatch":false,"canBeUsedToMatch":true},{"id":"spend","type":"string","display":true,"required":false,"displayName":"spend","defaultMatch":false,"canBeUsedToMatch":true},{"id":"results","type":"string","display":true,"required":false,"displayName":"results","defaultMatch":false,"canBeUsedToMatch":true},{"id":"reach","type":"string","display":true,"required":false,"displayName":"reach","defaultMatch":false,"canBeUsedToMatch":true},{"id":"impressions","type":"string","display":true,"required":false,"displayName":"impressions","defaultMatch":false,"canBeUsedToMatch":true},{"id":"clicks","type":"string","display":true,"required":false,"displayName":"clicks","defaultMatch":false,"canBeUsedToMatch":true},{"id":"ctr","type":"string","display":true,"required":false,"displayName":"ctr","defaultMatch":false,"canBeUsedToMatch":true},{"id":"cpc","type":"string","display":true,"required":false,"displayName":"cpc","defaultMatch":false,"canBeUsedToMatch":true},{"id":"cpm","type":"string","display":true,"required":false,"displayName":"cpm","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"operation":"append","sheetName":{"__rl":true,"mode":"name","value":"Ads"},"documentId":{"__rl":true,"mode":"id","value":"YOUR_SPREADSHEET_ID_HERE"}},"credentials":{"googleSheetsOAuth2Api":{"id":"credential-id","name":"Google Sheets account 2"}},"typeVersion":4.7},{"id":"dd95a46b-39ff-49b4-8d34-516a19a8ea73","name":"Save Campaign Data","type":"n8n-nodes-base.googleSheets","position":[1008,-240],"parameters":{"columns":{"value":{"CPL":"={{ $json.cost_per_result[0].values[0].value }}","CTR":"={{ $json.ctr }}","Date":"={{ $json.date_start }}","Reach":"={{ $json.reach }}","Spend":"={{ $json.spend }}","Clicks":"={{ $json.clicks }}","Campaign ID":"={{ $json.campaign_id }}","Impressions":"={{ $json.impressions }}","Campaign Name":"={{ $json.campaign_name }}","Conversations Started":"={{ $json.results[0].values[0].value }}"},"schema":[{"id":"Date","type":"string","display":true,"required":false,"displayName":"Date","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Campaign ID","type":"string","display":true,"required":false,"displayName":"Campaign ID","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Campaign Name","type":"string","display":true,"required":false,"displayName":"Campaign Name","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Reach","type":"string","display":true,"required":false,"displayName":"Reach","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Impressions","type":"string","display":true,"required":false,"displayName":"Impressions","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Conversations Started","type":"string","display":true,"required":false,"displayName":"Conversations Started","defaultMatch":false,"canBeUsedToMatch":true},{"id":"CPL","type":"string","display":true,"required":false,"displayName":"CPL","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Clicks","type":"string","display":true,"required":false,"displayName":"Clicks","defaultMatch":false,"canBeUsedToMatch":true},{"id":"CTR","type":"string","display":true,"required":false,"displayName":"CTR","defaultMatch":false,"canBeUsedToMatch":true},{"id":"Spend","type":"string","display":true,"required":false,"displayName":"Spend","defaultMatch":false,"canBeUsedToMatch":true}],"mappingMode":"defineBelow","matchingColumns":[],"attemptToConvertTypes":false,"convertFieldsToString":false},"options":{},"operation":"append","sheetName":{"__rl":true,"mode":"name","value":"Campaigns"},"documentId":{"__rl":true,"mode":"id","value":"YOUR_SPREADSHEET_ID_HERE"}},"credentials":{"googleSheetsOAuth2Api":{"id":"credential-id","name":"Google Sheets account 2"}},"typeVersion":4.7},{"id":"574a9644-05f3-4df0-a9d8-4fea57a8f562","name":"Set Configuration","type":"n8n-nodes-base.set","position":[-16,-240],"parameters":{"options":{},"assignments":{"assignments":[{"id":"678b725a-e235-48b1-904d-1fb7ea9ad061","name":"Ad Account ID","type":"string","value":"YOUR_ACT_ID_HERE"},{"id":"b0b6e2b9-6f30-4b53-a61d-485edac8d27b","name":"Email","type":"string","value":"user@example.com"}]}},"typeVersion":3.4},{"id":"e86432fc-a55d-41f6-ad7f-270129ae2f7e","name":"Split AI Insights","type":"n8n-nodes-base.splitOut","position":[1840,128],"parameters":{"options":{},"fieldToSplitOut":"output"},"typeVersion":1},{"id":"20e6389f-3feb-4b96-bb12-eaedb5c6cc6a","name":"Structured Output Parser","type":"@n8n/n8n-nodes-langchain.outputParserStructured","position":[1392,352],"parameters":{"jsonSchemaExample":"[\n  {\n    \"campaign_name\": \"string\",\n    \"adsets\": [\n      {\n        \"adset_name\": \"string\",\n        \"best_performing_ad\": \"string\",\n        \"worst_performing_ad\": \"string\",\n        \"suggestion_for_agency\": \"string\",\n        \"suggestion_for_client\": \"string\"\n      }\n    ]\n  }\n]\n"},"typeVersion":1.3},{"id":"482dd147-d952-4915-adf9-1b7766e47741","name":"Google Gemini Chat Model","type":"@n8n/n8n-nodes-langchain.lmChatGoogleGemini","position":[1216,352],"parameters":{"options":{}},"typeVersion":1},{"id":"3650d021-a1db-494c-9869-027994b0131a","name":"Get Ad Insights - Ad Level","type":"n8n-nodes-base.facebookGraphApi","position":[368,128],"parameters":{"edge":"insights?fields=ad_id,ad_name,adset_id,adset_name,campaign_id,campaign_name,spend,reach,impressions,clicks,results,ctr,cpc,cpm&level=ad&date_preset=yesterday","node":"=act_{{ $('Set Configuration').first().json['Ad Account ID'] }}","options":{},"graphApiVersion":"v24.0"},"credentials":{"facebookGraphApi":{"id":"credential-id","name":"Facebook Graph account"}},"typeVersion":1},{"id":"131c45ee-14b8-457f-b6ea-aabe65961104","name":"Get Ad Insights - Campaign Level","type":"n8n-nodes-base.facebookGraphApi","position":[352,-240],"parameters":{"edge":"=insights?fields=campaign_id,campaign_name,spend,impressions,clicks,results,marketing_messages_delivered,actions,reach,ctr,cost_per_result&level=campaign&date_preset=yesterday","node":"=act_{{ $('Set Configuration').first().json['Ad Account ID'] }}","options":{},"graphApiVersion":"v24.0"},"credentials":{"facebookGraphApi":{"id":"credential-id","name":"Facebook Graph account"}},"typeVersion":1},{"id":"90e8a0dc-3788-4925-94b1-9fbac67d91f4","name":"Split Ad Data","type":"n8n-nodes-base.splitOut","position":[592,128],"parameters":{"options":{},"fieldToSplitOut":"data"},"typeVersion":1},{"id":"132888b7-a5ee-4985-bb70-184345e2eb9a","name":"Filter Zero Spend","type":"n8n-nodes-base.filter","position":[800,-240],"parameters":{"options":{},"conditions":{"options":{"version":2,"leftValue":"","caseSensitive":true,"typeValidation":"strict"},"combinator":"and","conditions":[{"id":"066d6215-ac80-4510-9061-bd121fcae8ff","operator":{"type":"string","operation":"notEquals"},"leftValue":"={{ $json.spend }}","rightValue":"0"}]}},"typeVersion":2.2},{"id":"b6db113e-a4e3-48b6-baaf-48a6050b3490","name":"Split Campaign Data","type":"n8n-nodes-base.splitOut","position":[592,-240],"parameters":{"options":{},"fieldToSplitOut":"data"},"typeVersion":1},{"id":"91b6916f-c095-4961-8c12-f4c51dc33453","name":"Error Trigger","type":"n8n-nodes-base.errorTrigger","position":[1328,-240],"parameters":{},"typeVersion":1},{"id":"39328528-4432-41cb-9928-db5520f8ea1d","name":"Schedule - Once per day","type":"n8n-nodes-base.scheduleTrigger","position":[-320,-240],"parameters":{"rule":{"interval":[{"triggerAtHour":6}]}},"typeVersion":1.2},{"id":"1c62cf57-7a30-4c82-be4e-f5ee409419e8","name":"Sticky Note1","type":"n8n-nodes-base.stickyNote","position":[-368,-368],"parameters":{"color":7,"width":480,"height":288,"content":"## Configuration & schedule\n• Define run frequency\n• Set account and reporting parameters\n"},"typeVersion":1},{"id":"5990642f-977b-4e46-9ad6-04557dfb58c7","name":"Sticky Note2","type":"n8n-nodes-base.stickyNote","position":[320,-368],"parameters":{"color":7,"width":880,"height":288,"content":"## Campaign-level data collection\n• Fetch campaign performance data\n• Remove zero-spend campaigns\n• Store clean campaign metrics\n"},"typeVersion":1},{"id":"23cf66be-16d5-45fb-bd5e-061ac14560ca","name":"Sticky Note4","type":"n8n-nodes-base.stickyNote","position":[320,-16],"parameters":{"color":7,"width":720,"height":496,"content":"## Ad-level data collection\n• Fetch ad-level performance data\n• Normalize and structure records\n• Persist raw ad metrics\n"},"typeVersion":1},{"id":"e9927923-b091-4dfc-8b71-026663ca5f86","name":"Sticky Note5","type":"n8n-nodes-base.stickyNote","position":[1136,-16],"parameters":{"color":7,"width":480,"height":512,"content":"## AI analysis & insights\n• Analyze performance with Gemini\n• Detect winners and underperformers\n• Generate actionable recommendations\n"},"typeVersion":1},{"id":"cb8b95e6-7967-4c67-9f7b-cfe41f2362c1","name":"Sticky Note6","type":"n8n-nodes-base.stickyNote","position":[1728,-16],"parameters":{"color":7,"width":480,"height":512,"content":"## Insights storage\n• Split structured AI output\n• Save insights for reporting\n"},"typeVersion":1},{"id":"e5dcc793-68a0-4f4f-8f1d-2d8a86f710cf","name":"Sticky Note7","type":"n8n-nodes-base.stickyNote","position":[1280,-368],"parameters":{"color":7,"width":720,"height":288,"content":"## Error handling\n• Catch workflow failures\n• Send notification email\n"},"typeVersion":1}],"pinData":{},"connections":{"Get Config":{"main":[[{"node":"Send Error Email","type":"main","index":0}]]},"Error Trigger":{"main":[[{"node":"Get Config","type":"main","index":0}]]},"Split Ad Data":{"main":[[{"node":"Save Ad Data","type":"main","index":0},{"node":"Structure Data Hierarchy","type":"main","index":0}]]},"Write Insights":{"main":[[{"node":"Split AI Insights","type":"main","index":0}]]},"Filter Zero Spend":{"main":[[{"node":"Save Campaign Data","type":"main","index":0}]]},"Set Configuration":{"main":[[{"node":"Get Ad Insights - Campaign Level","type":"main","index":0}]]},"Split AI Insights":{"main":[[{"node":"Save AI Insights","type":"main","index":0}]]},"Split Campaign Data":{"main":[[{"node":"Filter Zero Spend","type":"main","index":0}]]},"Schedule - Once per day":{"main":[[{"node":"Set Configuration","type":"main","index":0},{"node":"Get Ad Insights - Ad Level","type":"main","index":0}]]},"Google Gemini Chat Model":{"ai_languageModel":[[{"node":"Write Insights","type":"ai_languageModel","index":0}]]},"Structure Data Hierarchy":{"main":[[{"node":"Write Insights","type":"main","index":0}]]},"Structured Output Parser":{"ai_outputParser":[[{"node":"Write Insights","type":"ai_outputParser","index":0}]]},"Get Ad Insights - Ad Level":{"main":[[{"node":"Split Ad Data","type":"main","index":0}]]},"Get Ad Insights - Campaign Level":{"main":[[{"node":"Split Campaign Data","type":"main","index":0}]]}}},"lastUpdatedBy":1,"workflowInfo":{"nodeCount":25,"nodeTypes":{"n8n-nodes-base.set":{"count":2},"n8n-nodes-base.code":{"count":1},"n8n-nodes-base.gmail":{"count":1},"n8n-nodes-base.filter":{"count":1},"n8n-nodes-base.splitOut":{"count":3},"n8n-nodes-base.stickyNote":{"count":7},"n8n-nodes-base.errorTrigger":{"count":1},"n8n-nodes-base.googleSheets":{"count":3},"n8n-nodes-base.scheduleTrigger":{"count":1},"n8n-nodes-base.facebookGraphApi":{"count":2},"@n8n/n8n-nodes-langchain.chainLlm":{"count":1},"@n8n/n8n-nodes-langchain.lmChatGoogleGemini":{"count":1},"@n8n/n8n-nodes-langchain.outputParserStructured":{"count":1}}},"status":"published","readyToDemo":null,"user":{"name":"Bakdaulet Abdikhan","username":"bakdaulet-abdikhan","bio":"Automation engineer with 2+ years experience. I build custom n8n engines for lead gen, reporting, and sales ops. If an API exists, I can automate it.","verified":false,"links":["https://instagram.com/bakdauletdesign"],"avatar":"https://gravatar.com/avatar/e8504a75c24da98947975e8238e1fa6b0488e34f7af39acced68209df389b271?r=pg&d=retro&size=200"},"nodes":[{"id":12,"icon":"fa:bug","name":"n8n-nodes-base.errorTrigger","codex":{"data":{"details":"In n8n, when a workflow execution fails, it can start another workflow. This second workflow can be any arbitrary workflow on your n8n instance. Use the Error Trigger node as your Trigger in the Error workflow.","resources":{"generic":[{"url":"https://n8n.io/blog/creating-error-workflows-in-n8n/","icon":"🌪","label":"Creating Error Workflows in n8n"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.errortrigger/"}]},"categories":["Development","Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Other Trigger Nodes"]}}},"group":"[\"trigger\"]","defaults":{"name":"Error Trigger","color":"#0000FF"},"iconData":{"icon":"bug","type":"icon"},"displayName":"Error Trigger","typeVersion":1,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]},{"id":18,"icon":"file:googleSheets.svg","name":"n8n-nodes-base.googleSheets","codex":{"data":{"alias":["CSV","Sheet","Spreadsheet","GS"],"resources":{"generic":[{"url":"https://n8n.io/blog/love-at-first-sight-ricardos-n8n-journey/","icon":"❤️","label":"Love at first sight: Ricardo’s n8n journey"},{"url":"https://n8n.io/blog/why-business-process-automation-with-n8n-can-change-your-daily-life/","icon":"🧬","label":"Why business process automation with n8n can change your daily life"},{"url":"https://n8n.io/blog/automatically-adding-expense-receipts-to-google-sheets-with-telegram-mindee-twilio-and-n8n/","icon":"🧾","label":"Automatically Adding Expense Receipts to Google Sheets with Telegram, Mindee, Twilio, and n8n"},{"url":"https://n8n.io/blog/supercharging-your-conference-registration-process-with-n8n/","icon":"🎫","label":"Supercharging your conference registration process with n8n"},{"url":"https://n8n.io/blog/creating-triggers-for-n8n-workflows-using-polling/","icon":"⏲","label":"Creating triggers for n8n workflows using polling"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/migrating-community-metrics-to-orbit-using-n8n/","icon":"📈","label":"Migrating Community Metrics to Orbit using n8n"},{"url":"https://n8n.io/blog/automate-google-apps-for-productivity/","icon":"💡","label":"15 Google apps you can combine and automate to increase productivity"},{"url":"https://n8n.io/blog/your-business-doesnt-need-you-to-operate/","icon":" 🖥️","label":"Hey founders! Your business doesn't need you to operate"},{"url":"https://n8n.io/blog/how-honest-burgers-use-automation-to-save-100k-per-year/","icon":"🍔","label":"How Honest Burgers Use Automation to Save $100k per year"},{"url":"https://n8n.io/blog/how-a-digital-strategist-uses-n8n-for-online-marketing/","icon":"💻","label":"How a digital strategist uses n8n for online marketing"},{"url":"https://n8n.io/blog/why-this-product-manager-loves-workflow-automation-with-n8n/","icon":"🧠","label":"Why this Product Manager loves workflow automation with n8n"},{"url":"https://n8n.io/blog/sending-automated-congratulations-with-google-sheets-twilio-and-n8n/","icon":"🙌","label":"Sending Automated Congratulations with Google Sheets, Twilio, and n8n "},{"url":"https://n8n.io/blog/how-a-membership-development-manager-automates-his-work-and-investments/","icon":"📈","label":"How a Membership Development Manager automates his work and investments"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.googlesheets/"}],"credentialDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/credentials/google/oauth-single-service/"}]},"categories":["Data & Storage","Productivity"],"nodeVersion":"1.0","codexVersion":"1.0"}},"group":"[\"input\",\"output\"]","defaults":{"name":"Google Sheets"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI2MCIgaGVpZ2h0PSI2MCI+PGcgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjxwYXRoIGZpbGw9IiMyOEI0NDYiIGQ9Ik0zNS42OSAxIDUyIDE3LjIyNXYzOS4wODdhMy42NyAzLjY3IDAgMCAxLTEuMDg0IDIuN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BMy42NyAzLjY3IDAgMCAxIDggNTUuMzEyVjMuNjg4YTMuNjcgMy42NyAwIDAgMSAxLjA4NC0yLjYxQTMuNyAzLjcgMCAwIDEgMTEuNzA3IDB6Ii8+PHBhdGggZmlsbD0iIzZBQ0U3QyIgZD0iTTM0LjY5IDAgNTEgMTYuMjI1SDM4LjM5N2MtMi4wNTQgMC0zLjcwNy0xLjgyOS0zLjcwNy0zLjg3MnoiLz48cGF0aCBmaWxsPSIjMjE5QjM4IiBkPSJNMzguMjExIDE2LjIyNSA1MSAyMS40OHYtNS4yNTV6Ii8+PHBhdGggZmlsbD0iI0ZGRiIgZD0iTTE5LjEyIDMwLjk3NWMwLS44MTcuNjYyLTEuNDc1IDEuNDgzLTEuNDc1aDE3Ljc5NGMuODIxIDAgMS40ODIuNjU4IDEuNDgyIDEuNDc1djE1LjQ4N2MwIC44MTgtLjY2MSAxLjQ3NS0xLjQ4MiAxLjQ3NUgyMC42MDNhMS40NzYgMS40NzYgMCAwIDEtMS40ODItMS40NzRWMzAuOTc0em0yLjIyNSAxLjQ3NWg2LjY3MnYyLjIxMmgtNi42NzJ6bTAgNS4xNjJoNi42NzJ2Mi4yMTNoLTYuNjcyem0wIDUuMTYzaDYuNjcydjIuMjEyaC02LjY3MnptOS42MzgtMTAuMzI1aDYuNjcydjIuMjEyaC02LjY3MnptMCA1LjE2Mmg2LjY3MnYyLjIxM2gtNi42NzJ6bTAgNS4xNjNoNi42NzJ2Mi4yMTJoLTYuNjcyeiIvPjwvZz48L3N2Zz4="},"displayName":"Google Sheets","typeVersion":5,"nodeCategories":[{"id":3,"name":"Data & Storage"},{"id":4,"name":"Productivity"}]},{"id":38,"icon":"fa:pen","name":"n8n-nodes-base.set","codex":{"data":{"alias":["Set","JS","JSON","Filter","Transform","Map"],"resources":{"generic":[{"url":"https://n8n.io/blog/learn-to-automate-your-factorys-incident-reporting-a-step-by-step-guide/","icon":"🏭","label":"Learn to Automate Your Factory's Incident Reporting: A Step by Step Guide"},{"url":"https://n8n.io/blog/2021-the-year-to-automate-the-new-you-with-n8n/","icon":"☀️","label":"2021: The Year to Automate the New You with n8n"},{"url":"https://n8n.io/blog/automatically-pulling-and-visualizing-data-with-n8n/","icon":"📈","label":"Automatically pulling and visualizing data with n8n"},{"url":"https://n8n.io/blog/database-monitoring-and-alerting-with-n8n/","icon":"📡","label":"Database Monitoring and Alerting with n8n"},{"url":"https://n8n.io/blog/automatically-adding-expense-receipts-to-google-sheets-with-telegram-mindee-twilio-and-n8n/","icon":"🧾","label":"Automatically Adding Expense Receipts to Google Sheets with Telegram, Mindee, Twilio, and n8n"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/how-to-build-a-low-code-self-hosted-url-shortener/","icon":"🔗","label":"How to build a low-code, self-hosted URL shortener in 3 steps"},{"url":"https://n8n.io/blog/automate-your-data-processing-pipeline-in-9-steps-with-n8n/","icon":"⚙️","label":"Automate your data processing pipeline in 9 steps"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/5-tasks-you-can-automate-with-notion-api/","icon":"⚡️","label":"5 tasks you can automate with the new Notion API "},{"url":"https://n8n.io/blog/automate-google-apps-for-productivity/","icon":"💡","label":"15 Google apps you can combine and automate to increase productivity"},{"url":"https://n8n.io/blog/how-uproc-scraped-a-multi-page-website-with-a-low-code-workflow/","icon":" 🕸️","label":"How uProc scraped a multi-page website with a low-code workflow"},{"url":"https://n8n.io/blog/building-an-expense-tracking-app-in-10-minutes/","icon":"📱","label":"Building an expense tracking app in 10 minutes"},{"url":"https://n8n.io/blog/the-ultimate-guide-to-automate-your-video-collaboration-with-whereby-mattermost-and-n8n/","icon":"📹","label":"The ultimate guide to automate your video collaboration with Whereby, Mattermost, and n8n"},{"url":"https://n8n.io/blog/5-workflow-automations-for-mattermost-that-we-love-at-n8n/","icon":"🤖","label":"5 workflow automations for Mattermost that we love at n8n"},{"url":"https://n8n.io/blog/learn-to-build-powerful-api-endpoints-using-webhooks/","icon":"🧰","label":"Learn to Build Powerful API Endpoints Using Webhooks"},{"url":"https://n8n.io/blog/how-a-membership-development-manager-automates-his-work-and-investments/","icon":"📈","label":"How a Membership Development Manager automates his work and investments"},{"url":"https://n8n.io/blog/a-low-code-bitcoin-ticker-built-with-questdb-and-n8n-io/","icon":"📈","label":"A low-code bitcoin ticker built with QuestDB and n8n.io"},{"url":"https://n8n.io/blog/how-to-set-up-a-ci-cd-pipeline-with-no-code/","icon":"🎡","label":"How to set up a no-code CI/CD pipeline with GitHub and TravisCI"},{"url":"https://n8n.io/blog/benefits-of-automation-and-n8n-an-interview-with-hubspots-hugh-durkin/","icon":"🎖","label":"Benefits of automation and n8n: An interview with HubSpot's Hugh Durkin"},{"url":"https://n8n.io/blog/how-goomer-automated-their-operations-with-over-200-n8n-workflows/","icon":"🛵","label":"How Goomer automated their operations with over 200 n8n workflows"},{"url":"https://n8n.io/blog/aws-workflow-automation/","label":"7 no-code workflow automations for Amazon Web Services"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.set/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Data Transformation"]}}},"group":"[\"input\"]","defaults":{"name":"Edit Fields"},"iconData":{"icon":"pen","type":"icon"},"displayName":"Edit Fields (Set)","typeVersion":3,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":314,"icon":"file:facebook.svg","name":"n8n-nodes-base.facebookGraphApi","codex":{"data":{"resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.facebookgraphapi/"}],"credentialDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/credentials/facebookgraph/"}]},"categories":["Development"],"nodeVersion":"1.0","codexVersion":"1.0"}},"group":"[\"transform\"]","defaults":{"name":"Facebook Graph API"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA2MCA2MCI+PHBhdGggZmlsbD0iIzE4NzdmMiIgZD0iTTU5LjUgMzBDNTkuNSAxMy43MSA0Ni4yOS41IDMwIC41Uy41IDEzLjcxLjUgMzBjMCAxNC43MiAxMC43OSAyNi45MyAyNC44OSAyOS4xNFYzOC41M0gxNy45VjMwaDcuNDl2LTYuNWMwLTcuMzkgNC40LTExLjQ4IDExLjE0LTExLjQ4IDMuMjMgMCA2LjYuNTggNi42LjU4djcuMjZoLTMuNzJjLTMuNjYgMC00LjgxIDIuMjctNC44MSA0LjYxVjMwaDguMThsLTEuMzEgOC41M0gzNC42djIwLjYxQzQ4LjcxIDU2LjkzIDU5LjUgNDQuNzIgNTkuNSAzMCIvPjxwYXRoIGZpbGw9IiNmZmYiIGQ9Ik00MS40OCAzOC41MyA0Mi43OSAzMGgtOC4xOHYtNS41M2MwLTIuMzMgMS4xNC00LjYxIDQuODEtNC42MWgzLjcyVjEyLjZzLTMuMzgtLjU4LTYuNi0uNThjLTYuNzQgMC0xMS4xNCA0LjA4LTExLjE0IDExLjQ4VjMwaC03LjV2OC41M2g3LjQ5djIwLjYxYzEuNS4yNCAzLjA0LjM2IDQuNjEuMzZzMy4xMS0uMTIgNC42MS0uMzZWMzguNTN6Ii8+PC9zdmc+"},"displayName":"Facebook Graph API","typeVersion":1,"nodeCategories":[{"id":5,"name":"Development"}]},{"id":356,"icon":"file:gmail.svg","name":"n8n-nodes-base.gmail","codex":{"data":{"alias":["email","human","form","wait","hitl","approval"],"resources":{"generic":[{"url":"https://n8n.io/blog/why-business-process-automation-with-n8n-can-change-your-daily-life/","icon":"🧬","label":"Why business process automation with n8n can change your daily life"},{"url":"https://n8n.io/blog/supercharging-your-conference-registration-process-with-n8n/","icon":"🎫","label":"Supercharging your conference registration process with n8n"},{"url":"https://n8n.io/blog/no-code-ecommerce-workflow-automations/","icon":"store","label":"6 e-commerce workflows to power up your Shopify s"},{"url":"https://n8n.io/blog/how-to-get-started-with-crm-automation-and-no-code-workflow-ideas/","icon":"👥","label":"How to get started with CRM automation (with 3 no-code workflow ideas"},{"url":"https://n8n.io/blog/automate-google-apps-for-productivity/","icon":"💡","label":"15 Google apps you can combine and automate to increase productivity"},{"url":"https://n8n.io/blog/your-business-doesnt-need-you-to-operate/","icon":" 🖥️","label":"Hey founders! Your business doesn't need you to operate"},{"url":"https://n8n.io/blog/using-automation-to-boost-productivity-in-the-workplace/","icon":"💪","label":"Using Automation to Boost Productivity in the Workplace"}],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.gmail/"}],"credentialDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/credentials/google/oauth-single-service/"}]},"categories":["Communication","HITL"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"HITL":["Human in the Loop"]}}},"group":"[\"transform\"]","defaults":{"name":"Gmail"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNTYiIGhlaWdodD0iMTkzIiBwcmVzZXJ2ZUFzcGVjdFJhdGlvPSJ4TWlkWU1pZCI+PHBhdGggZmlsbD0iIzQyODVGNCIgZD0iTTU4LjE4MiAxOTIuMDVWOTMuMTRMMjcuNTA3IDY1LjA3NyAwIDQ5LjUwNHYxMjUuMDkxYzAgOS42NTggNy44MjUgMTcuNDU1IDE3LjQ1NSAxNy40NTV6Ii8+PHBhdGggZmlsbD0iIzM0QTg1MyIgZD0iTTE5Ny44MTggMTkyLjA1aDQwLjcyN2M5LjY1OSAwIDE3LjQ1NS03LjgyNiAxNy40NTUtMTcuNDU1VjQ5LjUwNWwtMzEuMTU2IDE3LjgzNy0yNy4wMjYgMjUuNzk4eiIvPjxwYXRoIGZpbGw9IiNFQTQzMzUiIGQ9Im01OC4xODIgOTMuMTQtNC4xNzQtMzguNjQ3IDQuMTc0LTM2Ljk4OUwxMjggNjkuODY4bDY5LjgxOC01Mi4zNjQgNC42NyAzNC45OTItNC42NyA0MC42NDRMMTI4IDE0NS41MDR6Ii8+PHBhdGggZmlsbD0iI0ZCQkMwNCIgZD0iTTE5Ny44MTggMTcuNTA0VjkzLjE0TDI1NiA0OS41MDRWMjYuMjMxYzAtMjEuNTg1LTI0LjY0LTMzLjg5LTQxLjg5LTIwLjk0NXoiLz48cGF0aCBmaWxsPSIjQzUyMjFGIiBkPSJtMCA0OS41MDQgMjYuNzU5IDIwLjA3TDU4LjE4MiA5My4xNFYxNy41MDRMNDEuODkgNS4yODZDMjQuNjEtNy42NiAwIDQuNjQ2IDAgMjYuMjN6Ii8+PC9zdmc+"},"displayName":"Gmail","typeVersion":2,"nodeCategories":[{"id":6,"name":"Communication"},{"id":28,"name":"HITL"}]},{"id":565,"icon":"fa:sticky-note","name":"n8n-nodes-base.stickyNote","codex":{"data":{"alias":["Comments","Notes","Sticky"],"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers"]}}},"group":"[\"input\"]","defaults":{"name":"Sticky Note","color":"#FFD233"},"iconData":{"icon":"sticky-note","type":"icon"},"displayName":"Sticky Note","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":834,"icon":"file:code.svg","name":"n8n-nodes-base.code","codex":{"data":{"alias":["cpde","Javascript","JS","Python","Script","Custom Code","Function"],"details":"The Code node allows you to execute JavaScript in your workflow.","resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.code/"}]},"categories":["Development","Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Helpers","Data Transformation"]}}},"group":"[\"transform\"]","defaults":{"name":"Code"},"iconData":{"type":"file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IiIGhlaWdodD0iNTEyIiBmaWxsPSJ3aGl0ZSIvPgo8L2NsaXBQYXRoPgo8L2RlZnM+Cjwvc3ZnPgo="},"displayName":"Code","typeVersion":2,"nodeCategories":[{"id":5,"name":"Development"},{"id":9,"name":"Core Nodes"}]},{"id":839,"icon":"fa:clock","name":"n8n-nodes-base.scheduleTrigger","codex":{"data":{"alias":["Time","Scheduler","Polling","Cron","Interval"],"resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.scheduletrigger/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0"}},"group":"[\"trigger\",\"schedule\"]","defaults":{"name":"Schedule Trigger","color":"#31C49F"},"iconData":{"icon":"clock","type":"icon"},"displayName":"Schedule Trigger","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":844,"icon":"fa:filter","name":"n8n-nodes-base.filter","codex":{"data":{"alias":["Router","Filter","Condition","Logic","Boolean","Branch"],"details":"The Filter node can be used to filter items based on a condition. If the condition is met, the item will be passed on to the next node. If the condition is not met, the item will be omitted. Conditions can be combined together by AND(meet all conditions), or OR(meet at least one condition).","resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.filter/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Flow","Data Transformation"]}}},"group":"[\"transform\"]","defaults":{"name":"Filter","color":"#229eff"},"iconData":{"icon":"filter","type":"icon"},"displayName":"Filter","typeVersion":2,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":1123,"icon":"fa:link","name":"@n8n/n8n-nodes-langchain.chainLlm","codex":{"data":{"alias":["LangChain"],"resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/cluster-nodes/root-nodes/n8n-nodes-langchain.chainllm/"}]},"categories":["AI","Langchain"],"subcategories":{"AI":["Chains","Root Nodes"]}}},"group":"[\"transform\"]","defaults":{"name":"Basic LLM Chain","color":"#909298"},"iconData":{"icon":"link","type":"icon"},"displayName":"Basic LLM Chain","typeVersion":2,"nodeCategories":[{"id":25,"name":"AI"},{"id":26,"name":"Langchain"}]},{"id":1179,"icon":"fa:code","name":"@n8n/n8n-nodes-langchain.outputParserStructured","codex":{"data":{"alias":["json","zod"],"resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/cluster-nodes/sub-nodes/n8n-nodes-langchain.outputparserstructured/"}]},"categories":["AI","Langchain"],"subcategories":{"AI":["Output Parsers"]}}},"group":"[\"transform\"]","defaults":{"name":"Structured Output Parser"},"iconData":{"icon":"code","type":"icon"},"displayName":"Structured Output Parser","typeVersion":1,"nodeCategories":[{"id":25,"name":"AI"},{"id":26,"name":"Langchain"}]},{"id":1239,"icon":"file:splitOut.svg","name":"n8n-nodes-base.splitOut","codex":{"data":{"alias":["Split","Nested","Transform","Array","List","Item"],"details":"","resources":{"generic":[],"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.splitout/"}]},"categories":["Core Nodes"],"nodeVersion":"1.0","codexVersion":"1.0","subcategories":{"Core Nodes":["Data Transformation"]}}},"group":"[\"transform\"]","defaults":{"name":"Split Out"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI1MTIiIGhlaWdodD0iNTEyIiBmaWxsPSJub25lIj48ZyBmaWxsPSIjOUI2REQ1IiBjbGlwLXBhdGg9InVybCgjYSkiPjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgZD0iTTQ4MCAxNDhjMC02LjYyNy01LjM3My0xMi0xMi0xMkgzMjJjLTYuNjI3IDAtMTIgNS4zNzMtMTIgMTJ2MjRjMCA2LjYyNyA1LjM3MyAxMiAxMiAxMmgxNDZjNi42MjcgMCAxMi01LjM3MyAxMi0x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uNjI3IDAtMTIgNS4zNzMtMTIgMTJ2MjRjMCA2LjYyNyA1LjM3MyAxMiAxMiAxMmgxMTJjNi42MjcgMCAxMi01LjM3MyAxMi0xMnoiIGNsaXAtcnVsZT0iZXZlbm9kZCIvPjwvZz48ZGVmcz48Y2xpcFBhdGggaWQ9ImEiPjxwYXRoIGZpbGw9IiNmZmYiIGQ9Ik01MTIgMEgwdjUxMmg1MTJ6Ii8+PC9jbGlwUGF0aD48L2RlZnM+PC9zdmc+"},"displayName":"Split Out","typeVersion":1,"nodeCategories":[{"id":9,"name":"Core Nodes"}]},{"id":1262,"icon":"file:google.svg","name":"@n8n/n8n-nodes-langchain.lmChatGoogleGemini","codex":{"data":{"resources":{"primaryDocumentation":[{"url":"https://docs.n8n.io/integrations/builtin/cluster-nodes/sub-nodes/n8n-nodes-langchain.lmchatgooglegemini/"}]},"categories":["AI","Langchain"],"subcategories":{"AI":["Language Models","Root Nodes"],"Language Models":["Chat Models (Recommended)"]}}},"group":"[\"transform\"]","defaults":{"name":"Google Gemini Chat Model"},"iconData":{"type":"file","fileBuffer":"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSIwIDAgNDggNDgiPjxkZWZzPjxwYXRoIGlkPSJhIiBkPSJNNDQuNSAyMEgyNHY4LjVoMTEuOEMzNC43IDMzLjkgMzAuMSAzNyAyNCAzN2MtNy4yIDAtMTMtNS44LTEzLTEzczUuOC0xMyAxMy0xM2MzLjEgMCA1LjkgMS4xIDguMSAyLjlsNi40LTYuNEMzNC42IDQuMSAyOS42IDIgMjQgMiAxMS44IDIgMiAxMS44IDIgMjRzOS44IDIyIDIyIDIyYzExIDAgMjEtOCAyMS0yMiAwLTEuMy0uMi0yLjctLjUtNCIvPjwvZGVmcz48Y2xpcFBhdGggaWQ9ImIiPjx1c2UgeGxpbms6aHJlZj0iI2EiIG92ZXJmbG93PSJ2aXNpYmxlIi8+PC9jbGlwUGF0aD48cGF0aCBmaWxsPSIjRkJCQzA1IiBkPSJNMCAzN1YxMWwxNyAxM3oiIGNsaXAtcGF0aD0idXJsKCNiKSIvPjxwYXRoIGZpbGw9IiNFQTQzMzUiIGQ9Im0wIDExIDE3IDEzIDctNi4xTDQ4IDE0VjBIMHoiIGNsaXAtcGF0aD0idXJsKCNiKSIvPjxwYXRoIGZpbGw9IiMzNEE4NTMiIGQ9Im0wIDM3IDMwLTIzIDcuOSAxTDQ4IDB2NDhIMHoiIGNsaXAtcGF0aD0idXJsKCNiKSIvPjxwYXRoIGZpbGw9IiM0Mjg1RjQiIGQ9Ik00OCA0OCAxNyAyNGwtNC0zIDM1LTEweiIgY2xpcC1wYXRoPSJ1cmwoI2IpIi8+PC9zdmc+"},"displayName":"Google Gemini Chat Model","typeVersion":1,"nodeCategories":[{"id":25,"name":"AI"},{"id":26,"name":"Langchain"}]}],"categories":[{"id":32,"name":"Market Research"},{"id":49,"name":"AI Summarization"}],"image":[]}}