Skip to main content

Automated breaking news headlines with LLaMA3, Google Search and X posting

Workflow preview

Workflow preview
100%
Automated breaking news headlines with LLaMA3, Google Search and X posting preview
Open on n8n.io

Important notice

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

1. Workflow Overview

This n8n workflow automates the process of finding, summarizing, and posting breaking news headlines on X (formerly Twitter). It combines Google Custom Search for finding the latest news articles w...

Best for

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

Tools used

n8n-nodes-base.scheduletrigger, n8n-nodes-base.twitter, n8n-nodes-base.httprequest, n8n-nodes-base.code, 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 Afnan.

Original n8n.io source

1.1 Workflow description

Title
Automated breaking news headlines with LLaMA3, Google Search and X posting
Workflow name
Automated breaking news headlines with LLaMA3, Google Search and X posting

This n8n workflow automates the process of finding, summarizing, and posting breaking news headlines on X (formerly Twitter). It combines Google Custom Search for finding the latest news articles with Groq's LLaMA 3 model to generate short, engaging headlines — complete with hashtags — and posts them on your X account.

🔧 Features

Custom topic support (e.g., "AI", "health", "technology")

Automated scheduling every few hours

Google Custom Search to find the most recent news articles

Groq LLaMA3-based headline generation with hashtags

Auto-post to X (Twitter)

Built-in credential separation for API keys and access tokens

📦 Included Nodes

Schedule Trigger

Set (Set Topic, Google API Key, Custom Search CX, etc.)

HTTP Request (Google Search API)

Code Node (Format prompt and extract article data)

HTTP Request (Groq API for headline generation)

Twitter Node (Post to X)

⚙️ How It Works (Step-by-Step)

Trigger

  • The workflow starts on a scheduled interval (default: every 5 hours, at a random minute within the hour).

Set Topic

  • You can define your own topic keyword (e.g., AI, mental health, climate change) by editing the Set Topic node.

Build Search Query

  • Constructs a Google search query like: latest {topic} news.

Google API Config

  • Injects your own Google API Key and Custom Search CX (replace the placeholders in the Google Config node).

Search for News

  • Performs a real-time search using Google Custom Search API and fetches the latest article result.

Generate Prompt for AI

  • A JavaScript Function node extracts the top article’s title and link, formats it into a clean prompt including instructions to append hashtags.

Groq AI Request

  • Sends the prompt to Groq’s LLaMA 3 model to generate a concise, tweet-length headline with 1–2 relevant hashtags.

Post to Twitter (X)

  • The generated headline is posted to your connected X account via the Twitter OAuth2 API.

Requirements

  • Google API Key

  • Google Custom Search Engine (CX)

  • Groq API Key

  • Twitter Developer App with OAuth2 credentials

💡 Customization Tips

  • Change the topic in the Set Topic node to anything you like.

  • Adjust the posting frequency in the Schedule Trigger node.

  • Modify prompt behavior in the Function node to fit a specific tone or brand voice.

  • Add logging, filtering, or multiple post variations as needed.

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 - Schedule Trigger

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

Block 2 - Post to X

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

Block 3 - Groq AI

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

Block 4 - HTTP Request

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

Block 5 - Function

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

Block 6 - Google Config

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

Block 7 - Set Topic

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

Block 8 - Build Query

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

3. Summary Table

Workflow Automated breaking news headlines with LLaMA3, Google Search and X posting
Complexity intermediate
Nodes 8
Categories Social Media, Multimodal AI
Author Afnan
Published 16 Jun 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/4971/4971.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 breaking news headlines with LLaMA3, Google Search and X posting do?

This n8n workflow automates the process of finding, summarizing, and posting breaking news headlines on X (formerly Twitter). It combines Google Custom Search for finding the latest news articles w...

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.