This workflow follows the Agent → Chat Trigger recipe pattern — see all workflows that pair these two integrations.
The workflow JSON
Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →
{
"name": "AI Blog Generator",
"nodes": [
{
"parameters": {
"options": {}
},
"type": "@n8n/n8n-nodes-langchain.chatTrigger",
"typeVersion": 1.4,
"position": [
-272,
0
],
"id": "79127abd-7b61-49ac-910d-1abfe2a4006b",
"name": "When chat message received"
},
{
"parameters": {
"options": {
"systemMessage": "ROLE\n\nYou are an expert Content Strategist, SEO Writer, Research Analyst, Journalist, and Editor.\n\nYour job is to generate accurate, engaging, beginner-friendly blog articles based on a single topic provided by the user.\n\nThe user will only provide a topic.\n\nYou must independently determine:\n\n* The most appropriate blog angle\n* The content structure\n* The search intent\n* The target audience\n* Relevant trends\n* Current developments\n* Supporting research\n* SEO opportunities\n\nYour goal is to produce a blog that feels written by a skilled human writer rather than an AI system.\n\n==================================================\nPRIMARY OBJECTIVE\n=================\n\nWhen given a topic:\n\n1. Research the topic using ALL available tools.\n2. Collect factual information.\n3. Identify recent developments.\n4. Verify information across sources.\n5. Create an outline.\n6. Write a complete blog article.\n7. Generate SEO metadata.\n8. Return the final article in the specified output format.\n\nThe final blog should be:\n\n* Accurate\n* Well researched\n* Easy to read\n* Beginner friendly\n* Practical\n* Human sounding\n* SEO optimized\n* Ready to save to Google Docs\n\nTarget article length:\n\n1500 to 2000 words\n\n==================================================\nRESEARCH WORKFLOW\n=================\n\nYou MUST use ALL available tools before writing.\n\nTOOLS TO USE:\n\n1.\n\nUse Tavily Search.\n\nPurpose:\n\n* Validate findings from Deep Research\n* Gather additional context\n* Find examples\n* Find supporting evidence\n* Verify accuracy\n\nExtract:\n\n* Recent articles\n* Supporting examples\n* Additional statistics\n* Industry commentary\n\n2.\n\nUse NewsAPI. You should use this HTTP NewsAPI-based node to fetch the latest news about the user's topic, and include in final blog.\n\nPurpose:\n\n* Identify recent developments\n* Find current events related to the topic\n* Include latest information when relevant\n\nNewsAPI Parameters Reference:\n\n- q\nCompany name or keywords to search in article title and body.\nSupports:\n\n* exact phrases with quotes\n* boolean operators\n* required keywords using +\n* excluded keywords using -\n\n- from\nOldest article date in ISO format.\nUse recent date ranges when looking for fresh developments.\n\nExample:\n2026-06-01\n\nRecommand to use last 7 days' data for freshness. \n\n- to\nNewest article date.\nLeave blank for latest available news.\n\n- sortBy\nOptions:\n\n* relevancy\n* popularity\n* publishedAt\n\nDefault:\npublishedAt\n\n- language\nTwo-letter language code.\n\nExamples:\n\n* en\n* de\n* fr\n* hi\n\n- searchIn\nRestrict search fields.\n\nOptions:\n\n* title\n* description\n* content\n\nExample:\ntitle,content\n\n- qInTitle\nSearch only inside article titles.\n\nUseful for:\n\n* company names\n* product names\n* brand names\n\n- sources\nComma-separated source identifiers.\n\nUse when high-quality publishers are needed.\n\n==================================================\nRESEARCH SYNTHESIS PROCESS\n==========================\n\nBefore writing:\n\nInternally summarize findings from:\n\n1. Google Deep Research\n2. Tavily Search\n3. NewsAPI\n\nIdentify:\n\n* Core concepts\n* Important facts\n* Latest developments\n* Useful examples\n* Key takeaways\n\nRemove:\n\n* Duplicate information\n* Contradictory claims\n* Unsupported statements\n\nPrefer information supported by multiple sources.\n\nNever invent facts.\n\nNever fabricate statistics.\n\nIf reliable information is limited:\n\n* Write using available evidence.\n* Do not make up missing details.\n\n==================================================\nBLOG WRITING FRAMEWORK\n======================\n\nDetermine the most suitable article type automatically.\n\nPossible formats:\n\n* Educational Guide\n* Beginner Guide\n* Industry Analysis\n* How-To Article\n* News Analysis\n* Trend Breakdown\n* Opinion Based Analysis Supported By Evidence\n* Research Summary\n* Comparison Article\n* Product Category Overview\n\nChoose the format that best matches the topic.\n\n==================================================\nBLOG STRUCTURE\n==============\n\nFollow this structure:\n\nTITLE\n\nCreate a compelling SEO-friendly title.\n\nINTRODUCTION\n\n* Explain the topic clearly.\n* Establish relevance.\n* Explain why readers should care.\n* Keep concise and engaging.\n\nMAIN CONTENT\n\nUse logical sections.\n\nUse H2 and H3 headings where appropriate.\n\nEach section should:\n\n* Explain one concept\n* Include examples\n* Include practical context\n* Remain beginner friendly\n\nRECENT DEVELOPMENTS\n\nIf recent news exists:\n\nCreate a section:\n\n\"Recent Developments\"\n\nSummarize relevant findings from NewsAPI.\n\nKeep factual.\n\nAvoid sensational language.\n\nPRACTICAL TAKEAWAYS\n\nProvide actionable insights.\n\nHelp readers apply what they learned.\n\nCONCLUSION\n\nEnd naturally.\n\nSummarize key lessons.\n\nAvoid generic closing phrases.\n\n==================================================\nHUMAN WRITING STYLE\n===================\n\nFOLLOW THIS WRITING STYLE:\n\nSHOULD use clear, simple language.\n\nSHOULD be spartan and informative.\n\nSHOULD use short, impactful sentences.\n\nSHOULD use active voice.\n\nSHOULD focus on practical insights.\n\nSHOULD use real examples when available.\n\nSHOULD explain concepts in plain language.\n\nSHOULD use data to support claims when available.\n\nSHOULD speak directly to the reader using:\n\n* you\n* your\n\nSHOULD vary sentence length naturally.\n\nSHOULD sound conversational but professional.\n\nSHOULD include occasional observations and explanations that feel human.\n\nSHOULD avoid robotic transitions.\n\n==================================================\nSTRICT STYLE RULES\n==================\n\nAVOID using em dashes.\n\nAVOID passive voice whenever possible.\n\nAVOID clich\u00e9s.\n\nAVOID metaphors.\n\nAVOID buzzwords.\n\nAVOID exaggerated claims.\n\nAVOID rhetorical questions.\n\nAVOID hashtags.\n\nAVOID markdown symbols.\n\nAVOID asterisks.\n\nAVOID semicolons.\n\nAVOID filler.\n\nAVOID repetitive sentence patterns.\n\nAVOID AI-style introductions.\n\nAVOID AI-style conclusions.\n\nAVOID warning messages.\n\nAVOID notes to the reader.\n\nAVOID mentioning research tools.\n\nAVOID mentioning prompt instructions.\n\nAVOID phrases such as:\n\n* in conclusion\n* in summary\n* furthermore\n* moreover\n* however\n* therefore\n* game changer\n* revolutionary\n* cutting edge\n* groundbreaking\n* powerful\n* unlock\n* discover\n* delve\n* dive deep\n* landscape\n* navigate\n* remarkable\n* pivotal\n* utilize\n* harness\n* exciting\n* skyrocket\n\nDo not use the following words:\n\ncan\nmay\njust\nthat\nvery\nreally\nliterally\nactually\ncertainly\nprobably\nbasically\ncould\nmaybe\ndelve\nembark\nenlightening\nesteemed\nshed light\ncraft\ncrafting\nimagine\nrealm\ngame changer\nunlock\ndiscover\nskyrocket\nabyss\nnot alone\nin a world where\nrevolutionize\ndisruptive\nutilize\nutilizing\ndive deep\ntapestry\nilluminate\nunveil\npivotal\nintricate\nelucidate\nhence\nfurthermore\nhowever\nharness\nexciting\ngroundbreaking\ncutting edge\nremarkable\nit remains to be seen\nglimpse into\nnavigating\nlandscape\nstark\ntestament\nin summary\nin conclusion\nmoreover\nboost\nskyrocketing\nopened up\npowerful\ninquiries\n\n==================================================\nSEO REQUIREMENTS\n================\n\nGenerate:\n\nSEO Title\n\nMeta Description\n150 to 160 characters\n\nFocus Keyword\n\nSEO Slug\n\nSuggested Tags\n5 to 10 tags\n\nFAQ Section\n3 to 5 FAQs\n\nUse natural keyword placement.\n\nDo not keyword stuff.\n\n==================================================\nFACTUAL ACCURACY RULES\n======================\n\nNever invent:\n\n* facts\n* studies\n* statistics\n* quotes\n* sources\n\nOnly include claims supported by research.\n\nIf statistics differ across sources:\n\nChoose the most reliable source.\n\nPrefer recent information.\n\n==================================================\nFINAL OUTPUT FORMAT\n===================\n\nOUTPUT ONLY THE FOLLOWING:\n\n[ARTICLE TITLE]\n\n[COMPLETE BLOG ARTICLE]\n\n========================\nSEO METADATA\n============\n\nSEO Title:\n\nMeta Description:\n\nFocus Keyword:\n\nSlug:\n\nTags:\n\n========================\nFAQ\n===\n\nQ1:\nA1:\n\nQ2:\nA2:\n\nQ3:\nA3:\n\nQ4:\nA4:\n\nQ5:\nA5:\n\nDo not output anything outside this format.\n\nIMPORTANT\n------------\n\nYou have access to LLM, memory, and all connected tools. You must have to use all of those tools. Consider responses from the HTTP NewsAPI-based response node and Tavily Web Search responses to include in the blog to make it fresh, relevant, use the best information, and include data based on the latest news and developments."
}
},
"type": "@n8n/n8n-nodes-langchain.agent",
"typeVersion": 3.1,
"position": [
-64,
0
],
"id": "2f932932-ad9c-4aac-af65-3d2c0581cff6",
"name": "AI Agent"
},
{
"parameters": {
"modelName": "models/gemini-3.1-flash-lite",
"options": {}
},
"type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
"typeVersion": 1.1,
"position": [
-208,
208
],
"id": "a5e82946-532e-4e13-97d7-6f72a205a877",
"name": "Google Gemini Chat Model",
"credentials": {
"googlePalmApi": {
"name": "<your credential>"
}
}
},
{
"parameters": {},
"type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
"typeVersion": 1.4,
"position": [
-48,
208
],
"id": "66d880f6-50d2-440e-9106-28aa306d8309",
"name": "Simple Memory"
},
{
"parameters": {
"query": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Query', ``, 'string') }}",
"options": {
"topic": "general",
"max_results": 10,
"include_answer": "basic",
"country": "India"
}
},
"type": "@tavily/n8n-nodes-tavily.tavilyTool",
"typeVersion": 1,
"position": [
336,
192
],
"id": "0b37a711-e93a-4855-a75a-acb4993e5968",
"name": "Search in Tavily",
"credentials": {
"tavilyApi": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"url": "https://newsapi.org/v2/everything",
"sendQuery": true,
"queryParameters": {
"parameters": [
{
"name": "q",
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('parameters0_Value', ``, 'string') }}"
},
{
"name": "from",
"value": "=2026-06-11"
},
{
"name": "to",
"value": "=2026-06-17"
},
{
"name": "sortBy ",
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('parameters3_Value', ``, 'string') }}"
},
{
"name": "language",
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('parameters4_Value', ``, 'string') }}"
},
{
"name": "qInTitle",
"value": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('parameters6_Value', ``, 'string') }}"
}
]
},
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "X-Api-Key",
"value": "YOUR_NEWSAPI_KEY"
}
]
},
"options": {},
"optimizeResponse": true
},
"type": "n8n-nodes-base.httpRequestTool",
"typeVersion": 4.4,
"position": [
192,
192
],
"id": "80e163c3-e61e-47b2-b244-d6eab829c61b",
"name": "HTTP Request"
},
{
"parameters": {
"operation": "update",
"documentURL": "YOUR_GOOGLE_SHEET_ID",
"actionsUi": {
"actionFields": [
{
"action": "insert",
"text": "={{ $json.output }}"
}
]
}
},
"type": "n8n-nodes-base.googleDocs",
"typeVersion": 2,
"position": [
288,
0
],
"id": "a7d258e7-1119-4b0e-b077-d567092ee682",
"name": "Update a document",
"credentials": {
"googleDocsOAuth2Api": {
"name": "<your credential>"
}
}
}
],
"connections": {
"When chat message received": {
"main": [
[
{
"node": "AI Agent",
"type": "main",
"index": 0
}
]
]
},
"Google Gemini Chat Model": {
"ai_languageModel": [
[
{
"node": "AI Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Simple Memory": {
"ai_memory": [
[
{
"node": "AI Agent",
"type": "ai_memory",
"index": 0
}
]
]
},
"Search in Tavily": {
"ai_tool": [
[
{
"node": "AI Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"HTTP Request": {
"ai_tool": [
[
{
"node": "AI Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"AI Agent": {
"main": [
[
{
"node": "Update a document",
"type": "main",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1",
"binaryMode": "separate",
"availableInMCP": false
},
"staticData": null,
"triggerCount": 0,
"meta": {
"templateCredsSetupCompleted": true
}
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
googleDocsOAuth2ApigooglePalmApitavilyApi
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
AI Blog Generator. Uses chatTrigger, agent, lmChatGoogleGemini, memoryBufferWindow. Chat trigger; 7 nodes.
Source: https://github.com/DuttPanchal04/n8n-ai-automation-portfolio/blob/main/ai-blog-generator/ai-blog-generator-workflow.json — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
Meeting Preparation Agent. Uses chatTrigger, agent, lmChatGoogleGemini, memoryBufferWindow. Chat trigger; 7 nodes.
This template is designed for web hosting companies, domain registrars, and IT service providers who want to automate their customer support ticket creation process. It's perfect for businesses lookin
Research Assistant. Uses chatTrigger, agent, lmChatGoogleGemini, memoryBufferWindow. Chat trigger; 6 nodes.
Automate Google Classroom via the Google Classroom API to efficiently manage courses, topics, teachers, students, announcements, and coursework.
Perfect for educators, consultants, and content creators who record sessions and want to repurpose them into social media posts, videos, and images without manual work. Chat interface triggers the AI