Skip to main content

Publish AI-written newsletters and LinkedIn posts from WordPress with Gemini, Google Sheets and Gmail

Workflow preview

Workflow preview
100%
Publish AI-written newsletters and LinkedIn posts from WordPress with Gemini, Google Sheets and Gmail preview
Open on n8n.io

1. Workflow Overview

How it works This workflow fetches the latest blog post from a WordPress API and checks against a Google Sheets tracker to prevent duplicate processing. If a new post is found, the workflow updates...

Best for

  • Social Media automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

@n8n/n8n-nodes-langchain.lmchatgooglegemini, n8n-nodes-base.splitinbatches, n8n-nodes-base.linkedin, n8n-nodes-base.if, n8n-nodes-base.code, n8n-nodes-base.googlesheets, n8n-nodes-base.gmail, n8n-nodes-base.stickynote

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Avkash Kakdiya.

Original n8n.io source

1.1 Workflow description

Title
Publish AI-written newsletters and LinkedIn posts from WordPress with Gemini, Google Sheets and Gmail
Workflow name
Publish AI-written newsletters and LinkedIn posts from WordPress with Gemini, Google Sheets and Gmail

How it works

This workflow fetches the latest blog post from a WordPress API and checks against a Google Sheets tracker to prevent duplicate processing. If a new post is found, the workflow updates the tracker and cleans the blog data. The cleaned content is then sent to a Gemini-powered AI agent to generate a newsletter and LinkedIn teaser. Finally, the workflow distributes the content via LinkedIn and Gmail to subscribers.

Step-by-step

  • Detect new blog content

  • Schedule Trigger – Runs the workflow automatically at intervals.

  • HTTP Request – Fetches the latest blog post from WordPress.

  • Last ID – Retrieves the last processed blog ID from Google Sheets.

  • If – Compares IDs to check if the blog is new.

  • Update Last ID – Updates the sheet with the latest blog ID.

  • Clean and generate AI content

  • data cleanse – Cleans HTML, extracts title, content, and image.

  • AI Agent2 – Generates newsletter and teaser content.

  • Google Gemini Chat Model – Provides AI model for content generation.

  • Distribute content across channels

  • Format Response – Parses and structures AI output.

  • Create a post – Publishes content on LinkedIn.

  • Email List – Fetches subscriber emails from Google Sheets.

  • Loop Over Items – Iterates through each recipient.

  • Send Email – Sends HTML newsletter via Gmail.

Why use this?

  • Automates end-to-end blog promotion workflow
  • Prevents duplicate publishing using ID tracking
  • Uses AI to generate engaging content instantly
  • Saves time on manual posting and emailing
  • Easily scalable for growing audiences

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Google Gemini Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 2 - Loop Over Items

Type / Role
n8n-nodes-base.splitInBatches - splitInBatches
Config choices
Version 3

Block 3 - Create a post

Type / Role
n8n-nodes-base.linkedIn - linkedIn
Config choices
Version 1

Block 4 - If

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.3

Block 5 - data cleanse

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 6 - Last ID

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.7

Block 7 - Update Last ID

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.7

Block 8 - Format Response

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 9 - Email List

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 4.7

Block 10 - Send Email

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.2

Block 11 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 12 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 13 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 14 - Schedule Trigger

Type / Role
n8n-nodes-base.scheduleTrigger - scheduleTrigger
Config choices
Version 1.3

Block 15 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 16 - AI Agent2

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 3

Block 17 - HTTP Request

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.3

3. Summary Table

Workflow Publish AI-written newsletters and LinkedIn posts from WordPress with Gemini, Google Sheets and Gmail
Complexity advanced
Nodes 17
Categories Social Media, Multimodal AI
Author Avkash Kakdiya
Published 31 Mar 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/14525/14525.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Publish AI-written newsletters and LinkedIn posts from WordPress with Gemini, Google Sheets and Gmail do?

How it works This workflow fetches the latest blog post from a WordPress API and checks against a Google Sheets tracker to prevent duplicate processing. If a new post is found, the workflow updates...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Social Media, Multimodal AI use case.