Skip to main content
Community templateMarket Research

Aggregate news articles from NewsAPI, Mediastack & CurrentsAPI into database - n8n workflow template

This workflow pulls news articles from NewsAPI, Mediastack, and CurrentsAPI on a scheduled basis. Each provider’s results are normalized into a consistent schema, then written into your database (NocoDB by default). Use case: automated aggregation of categorized news for…

Template by Joel Gamble · Original listing (opens in a new tab)

Starts on
On a schedule
Nodes
29 nodes
Level
Advanced
Setup
About 16 min

Workflow preview

How this workflow runs

  1. 1

    MediaStack

    Starts the workflow automatically on a schedule (cron / fixed interval).

  2. 2

    CurrentsAPI

    Starts the workflow automatically on a schedule (cron / fixed interval).

  3. 3

    NewsAPI - Top Headlines

    Starts the workflow automatically on a schedule (cron / fixed interval).

  4. 4

    NewsAPI - Categories

    Starts the workflow automatically on a schedule (cron / fixed interval).

  5. 5

    mediastack categories

    Sets or transforms workflow data — prepares, renames, or injects fields before the next step.

  6. 6

    currentsapi config

    Sets or transforms workflow data — prepares, renames, or injects fields before the next step.

  7. 7

    call newsapi.org - Top Headlines

    Makes an external API call (HTTP request) to send or retrieve data from a third-party service.

  8. 8

    newsapi.org categories

    Sets or transforms workflow data — prepares, renames, or injects fields before the next step.

  9. 9

    Itemize Mediastack Categories

    Runs custom JavaScript to transform or manipulate the data flowing through the workflow.

  10. 10

    call currentsapi

    Makes an external API call (HTTP request) to send or retrieve data from a third-party service.

Creator's notes and setup

Written by Joel Gamble for the original listing.

This workflow pulls news articles from NewsAPI, Mediastack, and CurrentsAPI on a scheduled basis.

Each provider’s results are normalized into a consistent schema, then written into your database (NocoDB by default).
Use case: automated aggregation of categorized news for content pipelines, research agents, or editorial queues.

What You Must Update Before Running

1. API Keys

Replace all placeholder keys:

  • call newsapi.org - Top Headlines → update API_KEY in URL
  • call newsapi.org - categories → update API_KEY
  • call mediastack → update "ACCESS_KEY" in JSON
  • call currentsapi → update "API_KEY" param

2. Database Connection

Workflow uses NocoDB to store results.

You must:

  • Update the NocoDB API Token credential to your own
  • Ensure your table includes the fields used in the create operations
    (source_category, title, summary, author, sources, content, images, publisher_date, etc.)

If you prefer Google Sheets, Airtable, or another DB:

  • Replace each NocoDB node with your equivalent “create row” operation
  • The Set nodes already provide all normalized fields you need

3. Scheduling

All schedulers are disabled by default.
Enable the following so the workflow runs automatically:

  • NewsAPI – Top Headlines
  • NewsAPI – Categories
  • Mediastack
  • CurrentsAPI

You may change the run times, but all four must be scheduled for the workflow to function as designed.

What You Can Configure

1. Categories

Defined in:

  • newsapi.org categories
  • mediastack categories

Edit these arrays to pull only the categories you care about or to match your API plan limits.

2. Article Limits

Adjust article_limit in:

  • newsapi.org categories
  • mediastack categories
  • currentsapi config

n8n nodes used (8 types)

What every node does (29)
  • Split Out 1 (Split Out)Splits an array field into individual items so each can be processed separately.
  • Split Out 2 (Split Out)Splits an array field into individual items so each can be processed separately.
  • Split Out 3 (Split Out)Splits an array field into individual items so each can be processed separately.
  • Set Mediastack (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • Add Mediastack item (Noco DB)Reads or writes records in a NocoDB database.
  • Add NewsAPI item (Noco DB)Reads or writes records in a NocoDB database.
  • call mediastack (HTTP Request)Makes an external API call (HTTP request) to send or retrieve data from a third-party service.
  • call currentsapi (HTTP Request)Makes an external API call (HTTP request) to send or retrieve data from a third-party service.
  • currentsapi config (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • MediaStack (Schedule Trigger)Starts the workflow automatically on a schedule (cron / fixed interval).
  • CurrentsAPI (Schedule Trigger)Starts the workflow automatically on a schedule (cron / fixed interval).
  • call newsapi.org - Top Headlines (HTTP Request)Makes an external API call (HTTP request) to send or retrieve data from a third-party service.
  • Set CurrentsAPI (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • NewsAPI - Top Headlines (Schedule Trigger)Starts the workflow automatically on a schedule (cron / fixed interval).
  • Split Out (Split Out)Splits an array field into individual items so each can be processed separately.
  • Add NewsAPI item1 (Noco DB)Reads or writes records in a NocoDB database.
  • mediastack categories (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • newsapi.org categories (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • Itemize Newsapi Categories (Code)Runs custom JavaScript to transform or manipulate the data flowing through the workflow.
  • Itemize Mediastack Categories (Code)Runs custom JavaScript to transform or manipulate the data flowing through the workflow.
  • call newsapi.org - categories (HTTP Request)Makes an external API call (HTTP request) to send or retrieve data from a third-party service.
  • NewsAPI - Categories (Schedule Trigger)Starts the workflow automatically on a schedule (cron / fixed interval).
  • Wait (Wait)Pauses the workflow for a set time or until a condition is met (used for polling / async jobs).
  • Wait1 (Wait)Pauses the workflow for a set time or until a condition is met (used for polling / async jobs).
  • Loop Over NewsAPI (Split In Batches)Loops over items in batches, processing each one in turn (used for iteration).
  • Loop Over Mediastack (Split In Batches)Loops over items in batches, processing each one in turn (used for iteration).
  • Set Newsapi.org top headlines (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • Set Newsapi.org categories (Set)Sets or transforms workflow data — prepares, renames, or injects fields before the next step.
  • Add CurrentsAPI item (Noco DB)Reads or writes records in a NocoDB database.

FAQ

Aggregate news articles from NewsAPI, Mediastack & CurrentsAPI into database: questions

How do I import the "Aggregate news articles from NewsAPI, Mediastack & CurrentsAPI into database" workflow into n8n?

Copy the workflow JSON from this page, open the n8n editor, click on an empty canvas and paste with Ctrl+V (Cmd+V on macOS). You can also download the .json file and choose Import from File in the workflow menu. Save the workflow, then attach credentials before activating it.

Which nodes and credentials does "Aggregate news articles from NewsAPI, Mediastack & CurrentsAPI into database" use?

It uses HTTP Request, Set, Split In Batches, Noco Db, Wait and Code, plus 2 more. Any node that connects to an external service needs your own credential — open each node after import and select or create one. Trigger, logic and transformation nodes usually need no credentials.

Can it run on n8n Cloud and on self-hosted n8n?

The workflow format is the same on both. If a node appears as unknown or outdated after import, update n8n to a recent version or, on self-hosted instances, install the required community node package. Features such as $env access are available on self-hosted instances only.

How can I customise "Aggregate news articles from NewsAPI, Mediastack & CurrentsAPI into database"?

Start by changing the trigger (schedule, webhook or app event) and the destination nodes to match your stack — it is listed under Market Research. Edit prompts, field mappings and filters in the relevant nodes, use expressions like {{ $json.field }} to map data, and test with a manual execution before activating.

n8n is a trademark of n8n GmbH. AltFTool is not affiliated with, endorsed by or sponsored by n8n. Community templates are credited to their creators and link to the original listing; AltFTool originals are written and tested by the AltFTool team.

About this page

Free n8n workflow templates to copy and import

The AltFTool n8n library collects free n8n workflow templates for AI agents, Gmail, Google Sheets, Telegram and other apps. Each workflow page shows a preview, the list of nodes and the credentials it needs, and lets you copy or download the JSON to import into your own n8n.

Search the templates by app or task, or browse them by category and by node. The Workflow Inspector checks any workflow JSON for triggers, credentials and hardcoded keys before you share it, and the expressions cheat sheet gives copy-paste n8n expression examples. AltFTool is not affiliated with n8n.

People also search for

  • n8n workflow templates
  • n8n templates
  • n8n automation examples
  • n8n json workflows
  • n8n nodes
  • free n8n workflow templates
  • n8n ai agent template
  • n8n expressions cheat sheet