Skip to main content

Automated AI news curation and LinkedIn posting with GPT-5 and Firebase

Workflow preview

Workflow preview
100%
Automated AI news curation and LinkedIn posting with GPT-5 and Firebase preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

What this workflow does Automatically: 1. fetches fresh news, 2. filters out aggregators/PR wires and duplicates, 3. writes a human sounding LinkedIn post with GPT, 4. downloads the article image t...

Best for

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

Tools used

@n8n/n8n-nodes-langchain.lmchatopenai, @n8n/n8n-nodes-langchain.memorybufferwindow, @n8n/n8n-nodes-langchain.outputparserstructured, n8n-nodes-base.scheduletrigger, n8n-nodes-base.stickynote, n8n-nodes-base.googlefirebasecloudfirestore, n8n-nodes-base.httprequest, n8n-nodes-base.set

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
Automated AI news curation and LinkedIn posting with GPT-5 and Firebase
Workflow name
Automated AI news curation and LinkedIn posting with GPT-5 and Firebase

What this workflow does

Automatically: 1. fetches fresh news, 2. filters out aggregators/PR wires and duplicates, 3. writes a human-sounding LinkedIn post with GPT, 4. downloads the article image to verify it’s usable, 5. publishes to LinkedIn (with or without media), 6. and logs the posted titles in Firestore to avoid re-posting.

Runs on a daily schedule (cron) and supports two post variants: • Case 1: article has a description → richer post • Case 2: no description → short, still human and casual

How it works (high level flow) • Schedule Trigger (0 10,12,19,21 * * *): runs at 10:00, 12:00, 19:00, 21:00 (server timezone). • Firestore (Get Previous News Titles): loads previously posted titles (document asma/x20) to de-dupe. • HTTP Request (API NEWS): calls newsapi.org with query “AI Startup” for example, last 24–48h window, searchIn=title, sorted by publishedAt. • Code: Select Articles: • excludes Biztoc and common aggregators/PR wires (Techmeme, TheFly, PRNewswire, GlobeNewswire, MarketWatch press-releases, Medium, Substack, Yahoo consent, etc.), • requires valid URL + image, • groups by topic (normalized title + domain) and picks the best representative, • sorts by recency and returns up to 10 unique articles. • IF (URL & De-dupe checks): ensures link present and not already posted (compares against Firestore titles). • IF (Description Checker): branches on presence of description. • LLM Agents (2 prompts): generate a casual, human LinkedIn post in English (no emojis/links/markdown, 2–3 hashtags). • Post setup: cleans the text, passes the image URL forward. • HTTP Request (Image Downloader): retrieves the image as a file to confirm the link works. • LinkedIn Publisher: • If image OK → posts with media. • Otherwise → posts text-only. • Time Checkers + Firestore Upserts: after a successful publish, writes the article’s title to Firestore (asma/x20 fields title10, title12, title19, title21) so it won’t be posted again at other times.

Credentials & prerequisites • NewsAPI.org: API key (free tier works to start; mind rate limits). • LinkedIn OAuth2: connected account with permission to create posts on your profile (uses “Person” target in the node). • Google Firebase (Firestore): Service Account with read/write to the asma collection. The workflow uses document ID x20.

Setup (5 minutes) 1. Import the workflow and open it in n8n. 2. In API NEWS, set your NewsAPI key in the query param apiKey. 3. In Get Previous News Titles and Firebase Article Saver [1–8], attach your Google Service Account and confirm projectId, collection=asma. 4. In LinkedIn Publisher [1–4], attach your LinkedIn OAuth credential and ensure the Person is your profile URN. 5. (Optional) Adjust the cron in Hourly trigger (server timezone). 6. (Optional) Change the search query (q=AI startup), language, or time window in API NEWS. 7. Enable the workflow.

Customization tips • Search scope: edit q, language, from/to in API NEWS to cover your niche. • Aggregator policy: tweak the aggregatorDomains set in the Select Articles code node. • Post voice: modify the LLM prompt (keeps the “human, slightly messy” tone). • Hashtags: the prompt ends with 2–3 simple tags (#AI #Startups #Innovation) — change as you like. • Posting times: change the cron or the downstream time-checker logic to map specific titles → time slots. • No-image fallback: text-only path is already handled; replace with a placeholder image if you prefer always-with-media.

Notes & constraints • Timezone: Schedule Trigger uses the n8n server timezone; adjust if your LinkedIn audience is elsewhere. • De-dupe: this template stores last posted titles in one Firestore doc (asma/x20) under title10, title12, title19, title21. You can change the schema or keep a rolling history. • Filtering: items missing URL or image are skipped by design. Yahoo consent pages are also skipped. • LLM costs: posts are short; usage is modest, but keep an eye on your OpenAI billing. • NewsAPI limits: free plans throttle requests; consider caching or widening the time window if you hit limits.

Troubleshooting • Nothing posts: check NewsAPI quota/response, then see the URL checker and Description Checker branches. • Image errors: some sites block hotlinking; the image download step will fall back to text-only posting. • Duplicates appeared: verify Firestore upserts executed after posting and that your comparison uses the right fields. • Wrong hours: confirm your n8n instance timezone and the cron expression.

Why this template

You get a robust “news → LinkedIn” autoposter that feels authentically human (no corporate vibes), avoids low-quality aggregators, prevents duplicates, and gracefully handles media — all with clean, modular nodes that are easy to tweak.

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 - OpenAI Chat Model2

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 2 - Simple Memory2

Type / Role
@n8n/n8n-nodes-langchain.memoryBufferWindow - memoryBufferWindow
Config choices
Version 1.3

Block 3 - Structured Output Parser2

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 4 - OpenAI Chat Model4

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 5 - Simple Memory4

Type / Role
@n8n/n8n-nodes-langchain.memoryBufferWindow - memoryBufferWindow
Config choices
Version 1.3

Block 6 - Structured Output Parser4

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 7 - Hourly trigger

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

Block 8 - Sticky Note

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

Block 9 - Sticky Note1

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

Block 10 - Get Previous News Titles

Type / Role
n8n-nodes-base.googleFirebaseCloudFirestore - googleFirebaseCloudFirestore
Config choices
Version 1.1

Block 11 - API NEWS

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

Block 12 - Sticky Note2

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

Block 13 - Sticky Note3

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

Block 14 - Collect Articles

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 15 - Select Articles

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

Block 16 - URL checker

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

Block 17 - Description Checker

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

Block 18 - Sticky Note4

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

Block 19 - LinkedIn post redaction

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

Block 20 - LinkedIn post redaction 2

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

Block 21 - Sticky Note5

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

Block 22 - Sticky Note6

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

Block 23 - Post setup

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 24 - Post setup 2

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Showing the first 24 of 66 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Automated AI news curation and LinkedIn posting with GPT-5 and Firebase
Complexity advanced
Nodes 66
Categories Social Media, AI Chatbot
Author Arthur Dimeglio
Published 19 Oct 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/9886/9886.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 Automated AI news curation and LinkedIn posting with GPT-5 and Firebase do?

What this workflow does Automatically: 1. fetches fresh news, 2. filters out aggregators/PR wires and duplicates, 3. writes a human sounding LinkedIn post with GPT, 4. downloads the article image t...

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, AI Chatbot use case.