Book ghostwriting & research AI agent
Needs changesWhat this workflow does
This AI workflow has 24 nodes and runs when an HTTP GET request hits its webhook URL. Along the way it connects Airtable, Google Gemini Chat Model, HTTP Request and OpenAI Chat Model. It also calls api.perplexity.ai over HTTP.
How it runs
Trigger: When an HTTP GET request hits its webhook URL.
- Switch: routes items into 4 branches
- Airtable: uses Airtable
- Airtable: uses Airtable
- Airtable: uses Airtable
- Airtable: uses Airtable
- AI Agent: runs an AI agent, with model: Google Gemini Chat Model; 1 tool (Perplexity)
- Basic LLM Chain: sends a prompt to an LLM, with model: OpenAI Chat Model; output parser: Structured Output Parser
- AI Agent: runs an AI agent, with model: Google Gemini Chat Model; 1 tool (Perplexity)
- Basic LLM Chain: sends a prompt to an LLM, with model: Google Gemini Chat Model
- Airtable: update
…plus 6 more steps. See the full node list below.
Services it uses
HTTP calls to: api.perplexity.ai
Before you upgrade to n8n 3.0
2 things in this workflow are removed in n8n 3.0. Fix them before you upgrade:
- AI Agent v1 (old agent modes) in AI Agent (v1.7), AI Agent1 (v1.7): replace with Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.
- HTTP Request Tool (legacy) in Perplexity, Perplexity1: replace with HTTP Request node connected to the AI Agent's Tool input.
Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).
| Removed in 3.0 | Replace with |
|---|---|
| AI Agent v1 (old agent modes) AI Agent (v1.7), AI Agent1 (v1.7) | Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent. |
| HTTP Request Tool (legacy) Perplexity, Perplexity1 | HTTP Request node connected to the AI Agent's Tool input |
Nodes used (11)
- Webhook
n8n-nodes-base.webhook - Switch
n8n-nodes-base.switch - Airtable
n8n-nodes-base.airtable - AI Agent
@n8n/n8n-nodes-langchain.agent - Google Gemini Chat Model
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - HTTP Request Tool
@n8n/n8n-nodes-langchain.toolHttpRequest - Basic LLM Chain
@n8n/n8n-nodes-langchain.chainLlm - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Structured Output Parser
@n8n/n8n-nodes-langchain.outputParserStructured - Edit Fields (Set)
n8n-nodes-base.set - Split Out
n8n-nodes-base.splitOut
From the author
How it Works: 1. Trigger: The workflow is triggered by a webhook, initiated by an Airtable automation. This automation sends the Book or Chapter record ID and the desired action (e.g., "Generate Book Details," "Generate Chapters," "Generate Chapter Research,"…