🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

X + Facebook to Notion, reports shared in Slack

Lisa Granqvist Partner Workflow Automation Expert

Your weekly social report should not feel like detective work. But when metrics live in two dashboards, notes live in a doc, and “the final numbers” change twice, you end up copying, pasting, and second-guessing everything.

This X Facebook reporting automation hits social media managers first, honestly. Marketing leads who need clean snapshots for leadership feel it too, and agency owners running multiple client accounts get stuck in it every week. The outcome is simple: consistent, shareable reporting without the spreadsheet chaos.

Below you’ll see how the workflow pulls X and Facebook metrics, validates them, stores structured data in Notion, and pushes an AI-written report to Slack and Gmail.

How This Automation Works

The full n8n workflow, from trigger to final output:

n8n Workflow Template: X + Facebook to Notion, reports shared in Slack

The Problem: Weekly social reports turn into manual busywork

Weekly reporting sounds easy until you actually do it. You open X analytics, then Facebook Insights, then try to line up date ranges, definitions, and totals that don’t quite match what you saw last week. Now you’re pasting numbers into a doc or dashboard while Slack pings you for “a quick update” and someone asks if engagement is up or down. One small mistake (wrong timeframe, missing metric, swapped platform labels) and your whole summary becomes questionable, which means more rework and more explaining.

The friction compounds. Here’s where it usually breaks down.

  • Pulling follower and engagement metrics from two platforms can easily eat about 1–2 hours each week once you include validation and formatting.
  • Numbers get copied into the wrong row or the wrong week, and nobody notices until the meeting.
  • You end up rewriting the “insights” section from scratch because there’s no consistent structure to follow.
  • When an API call fails or a metric is missing, you learn about it late, after the report is already sent.

The Solution: An AI-generated report stored in Notion and shared in Slack

This workflow automates the entire reporting loop. You trigger it manually (or schedule it weekly), and n8n immediately pulls the latest metrics from X and Facebook using their APIs. Those two responses are merged into one dataset, then validated so the workflow can catch missing fields or incomplete results before they pollute your report. Next, a small JavaScript formatting step normalizes the metrics into a clean JSON structure, which makes the rest of the system predictable. From there, GPT-4o generates a polished HTML report with tables and plain-English insights, then the workflow stores the structured data in a Notion “Growth Chart” database and shares summaries to Slack and Gmail.

The workflow starts with a trigger, pulls X and Facebook data in parallel, then merges and checks it. After normalization, the AI produces the report content, which is delivered to the places teams actually use: Notion for tracking, Slack for visibility, and Gmail for distribution.

What You Get: Automation vs. Results

Example: What This Looks Like

Say you create one weekly report for two platforms (X + Facebook). Manually, it’s often about 30 minutes to pull each set of metrics, then another 30–60 minutes to format, write insights, and send updates, so roughly 2 hours per week. With this workflow, you spend maybe 5 minutes to trigger it and skim the output, then wait for the API calls and report generation to finish. You get the same deliverables (Notion record, Slack summary, Gmail report) without the copy-paste marathon.

What You’ll Need

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • X (Twitter) API credentials to retrieve public metrics.
  • Facebook Graph API access token to pull page insights.
  • Azure OpenAI API key (get it from the Azure OpenAI resource in your Azure portal).
  • Notion integration for writing into your Growth Chart database.
  • Slack bot token to post the summary message.
  • Gmail OAuth to email the HTML report to your list.
  • Google Sheets OAuth to log errors for debugging.

Skill level: Intermediate. You won’t write much code, but you will match Notion fields, paste API tokens, and test a few runs to confirm the metrics map correctly.

Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).

How It Works

A manual or scheduled trigger kicks things off. You can run it on demand for a quick update, or set it to fire weekly before your team meeting.

Metrics are pulled from X and Facebook. Two API requests run, then the workflow merges the responses into one combined dataset so comparisons are straightforward.

The data is checked and normalized. If required fields are missing, the workflow routes the issue into a Google Sheets error log. If it looks valid, a JavaScript formatting step converts everything into a consistent structure that Notion and the AI prompt can rely on.

An HTML report is generated and shared. GPT-4o produces the report, then n8n writes structured metrics into Notion, emails the report via Gmail, and posts a concise Slack summary for visibility.

You can easily modify the report prompt to match your brand voice and change which metrics are saved to Notion based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Manual Trigger

This workflow starts manually and then launches parallel API calls to pull social metrics.

  1. Add and open Manual Launch Trigger to serve as the entry point.
  2. Connect Manual Launch Trigger so it outputs to both Retrieve Twitter Metrics and Retrieve Facebook Metrics in parallel.

Parallel Execution: Manual Launch Trigger outputs to both Retrieve Twitter Metrics and Retrieve Facebook Metrics in parallel.

Step 2: Connect Social API Requests

Pull metrics from X (Twitter) and Facebook, then combine the results for downstream processing.

  1. Open Retrieve Twitter Metrics and set URL to https://api.x.com/2/users/by/username/marveldcclub?user.fields=public_metrics.
  2. Credential Required: Connect your twitterOAuth2Api credentials in Retrieve Twitter Metrics.
  3. Open Retrieve Facebook Metrics and set URL to https://graph.facebook.com/v18.0/[YOUR_ID]?fields=name,followers_count,fan_count.
  4. Credential Required: Connect your facebookGraphApi credentials in Retrieve Facebook Metrics.
  5. Connect both API nodes into Combine Platform Results to merge the two inputs.

Step 3: Validate and Format the Metrics

Verify API responses and normalize the data into a unified JSON object.

  1. Open Validate API Response and confirm the condition uses {{ $json.data }} with the notEmpty operator.
  2. Connect the “true” output from Validate API Response to Format Social Metrics Script.
  3. In Format Social Metrics Script, keep the provided JavaScript to merge Twitter and Facebook metrics into a single merged object.

Parallel Execution: Format Social Metrics Script outputs to both Create HTML Performance Report and Store Report in Notion in parallel.

Step 4: Set Up the AI Report Generator

Use the Azure OpenAI model to generate the HTML summary from the formatted metrics.

  1. Open Set Azure GPT-4o Model and confirm Model is set to gpt-4o.
  2. Credential Required: Connect your azureOpenAiApi credentials in Set Azure GPT-4o Model.
  3. Open Create HTML Performance Report and keep Prompt Type set to define.
  4. Ensure the Text prompt includes the expressions like {{$json.twitter.name}}, {{$json.facebook.followers}}, and {{$json.facebook.likes}}.
  5. Verify the System Message provides the reporting guidelines and emoji formatting, as configured.

OpenAI is connected via Set Azure GPT-4o Model as the language model for Create HTML Performance Report — ensure credentials are added to Set Azure GPT-4o Model, not the agent node.

Step 5: Configure Output Destinations

Store the report in Notion, email the HTML report, and post a summary to Slack.

  1. Open Store Report in Notion and set Database to [YOUR_ID] with Resource set to databasePage.
  2. Keep the property mappings in Store Report in Notion using expressions like {{ $json.twitter.name }} and {{ $json.facebook.followers.toString() }}.
  3. Credential Required: Connect your notionApi credentials in Store Report in Notion.
  4. Open Email Report to Team and set Send To to [YOUR_EMAIL], Subject to 📊 Weekly Social Media Performance Report — Twitter & Facebook Overview, and Message to {{ $json.output }}.
  5. Credential Required: Connect your gmailOAuth2 credentials in Email Report to Team.
  6. Open Post Summary to Slack and verify the Text field uses expressions from Format Social Metrics Script like {{ $('Format Social Metrics Script').item.json.twitter.followers }}.
  7. Credential Required: Connect your slackApi credentials in Post Summary to Slack.

Parallel Execution: Create HTML Performance Report outputs to both Email Report to Team and Post Summary to Slack in parallel.

Step 6: Add Error Handling

Capture failed API responses and append error details to Google Sheets.

  1. From Validate API Response, connect the “false” output to Append Errors to Sheets.
  2. In Append Errors to Sheets, set Operation to append and select Document ID [YOUR_ID] and Sheet Name [YOUR_ID].
  3. Credential Required: Connect your googleSheetsOAuth2Api credentials in Append Errors to Sheets.

⚠️ Common Pitfall: If Validate API Response expects {{ $json.data }} but the Facebook response doesn’t include data, route only Twitter’s API response through that check or adjust the condition to handle both structures.

Step 7: Test and Activate Your Workflow

Run a manual test and confirm each output destination receives the expected data.

  1. Click Execute Workflow on Manual Launch Trigger to run the workflow end-to-end.
  2. Confirm Retrieve Twitter Metrics and Retrieve Facebook Metrics return valid JSON and merge in Combine Platform Results.
  3. Verify Create HTML Performance Report outputs HTML in $json.output, then check your inbox from Email Report to Team.
  4. Confirm a new page appears in Notion from Store Report in Notion and a message posts from Post Summary to Slack.
  5. Once verified, toggle the workflow to Active for production use.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Common Gotchas

  • Slack credentials can expire or need specific permissions. If things break, check your Slack app’s token scopes (especially chat:write) and the selected workspace connection in n8n first.
  • If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • Default prompts in AI nodes are generic. Add your brand voice early or you’ll be editing outputs forever.

Frequently Asked Questions

How long does it take to set up this X Facebook reporting automation?

About 45 minutes if your accounts and tokens are ready.

Do I need coding skills to automate X Facebook reporting?

No. You’ll mainly connect accounts, paste credentials, and match fields in Notion.

Is n8n free to use for this X Facebook reporting workflow?

Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in Azure OpenAI usage costs (often a few dollars a month for weekly reports, depending on length).

Where can I host n8n to run this automation?

Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.

Can I customize this X Facebook reporting workflow for multiple client accounts?

Yes, but you’ll want to parameterize the X handle, Facebook Page ID, and the Notion database destination. Most people duplicate the workflow per client, then adjust the two HTTP Request nodes (X and Facebook) and the “Store Report in Notion” node to point at the right database. You can also tweak the AI prompt in the “Create HTML Performance Report” agent to output a client-branded layout and include the exact KPIs you report on in QBRs.

Why is my Slack connection failing in this workflow?

Usually it’s an expired or changed token, or the bot simply isn’t allowed to post in that channel. Reconnect Slack in n8n, confirm the bot is invited to the target channel, and verify it has chat:write permission. If it works in tests but fails on scheduled runs, double-check the selected credentials on the “Post Summary to Slack” node (it’s easy to have the wrong one saved). Rate limiting can also show up if you blast multiple reports at once.

How many reports can this X Facebook reporting automation handle?

On n8n Cloud Starter, you can run roughly a few thousand executions per month, which is plenty for weekly reporting across several brands. If you self-host, there’s no execution cap and the limit becomes your server resources and the API rate limits from X and Facebook. In practice, this workflow is “one execution per report,” so even 20 clients with weekly runs is still a very manageable volume.

Is this X Facebook reporting automation better than using Zapier or Make?

Often, yes. This workflow needs branching (valid vs invalid API responses), merging, custom JavaScript formatting, and an AI-generated HTML report, and those pieces are simply less painful in n8n. Zapier and Make can do parts of it, but you may end up paying more once you add paths, code steps, and higher task volume. Also, self-hosting matters here because reporting tends to expand over time (more clients, more KPIs, more runs). If you only need “send me the raw numbers,” Zapier might be enough. If you’re not sure, Talk to an automation expert and get a straight recommendation.

Once this is running, weekly reporting becomes a push-button habit, not a recurring fire drill. The workflow handles the repetitive stuff, so you can focus on what the numbers are telling you.

Need Help Setting This Up?

Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal