SemScore Logo
New App

SemScore App is Live on Google Play!

Automate Facebook & Instagram Reels with n8n and Content Creator Paradise API

O
OD2 Team
7 min read (1260 words)2 readsOffline Snapshot
Automate Facebook & Instagram Reels with n8n and Content Creator Paradise API

In the modern digital landscape, content volume and consistency are the keys to growth. However, manually sourcing articles, drafting engaging captions, creating eye-catching graphics, editing video reels, and posting them across platforms takes hours of manual work every single day.

By combining the power of n8n (the open-source workflow automation builder), AI models (like Google Gemini and Ollama Qwen), and the custom Content Creator Paradise API, you can build a 100% hands-free social media publishing engine.

In this guide, we will break down the exact architecture of an automated workflow that monitors RSS feeds, generates social media copy via AI, programmatically renders image updates or motion video Reels, publishes them directly to Facebook & Instagram, and monitors success via Discord.

🚀 OD2 Creator Tool

Automate Reels & Social Media Video Engines

Build automated AI content pipelines and generate branded video reels for free.

Explore Creator Engine →

The Architecture at a Glance

The publishing engine follows a linear, pipeline-oriented design that connects feeds, databases, artificial intelligence, creative engines, and social media APIs:


Step-by-Step Workflow Breakdown

Let’s dissect the core components of the n8n workflow to understand how each node contributes to the automated engine.

1. Sourcing Content Dynamically

The automation starts with a Schedule Trigger set to run at regular intervals (e.g., every few hours).

  • Niche Feed Picker: A JavaScript code node maps hours to specific categories and RSS URLs matching your target niche. For example, if you run a lifestyle and business brand:
    • 06:00: Motivation Feeds
    • 12:00: Business Feeds
    • 18:00: Industry/World News Feeds
    • 21:00: Tech & Lifestyle Feeds
  • HTTP Request: The selected RSS feed is fetched as raw XML data.
  • XML Parser Node: A JavaScript code node parses the XML tags, extracts the content snippet, description, links, and checks for embedded media content or enclosures (image URLs). If no article image exists, it falls back to a sleek, styled placeholder image (https://placehold.co/...).

2. Guardrails Against Duplication

Before calling expensive AI APIs, the workflow checks a database to ensure the item hasn’t already been processed.

  • Database Duplicate Check: Executes a query filtering recent records from your database. For example, using MySQL:SELECT url, slug, title FROM published_items WHERE created_at >= NOW() - INTERVAL 2 DAY ORDER BY id DESC LIMIT 100;
  • Filter: Checks the fetched URL against the list. If a match is found, n8n exits early and logs a “Duplicate Skipped” payload to your admin notification channel.

3. AI-Powered Copywriting & Formatting

When a new article is confirmed, the workflow executes the LLM Chain node. It can be backed by a cloud chat model like Google Gemini 3.1 Flash Lite or a local Ollama instance.

  • Strict Prompting: The AI is instructed to act as a strict JSON-only content copywriter. It reads the raw feed content and yields a single minified JSON object containing:
    • title: SEO-optimized headline.
    • summary: A concise 2-3 sentence summary.
    • content_markdown: A comprehensive, structured blog body.
    • social: Specific posts written for X/Twitter (under 280 chars), Instagram (strong hook, paragraphs, emoji CTAs, and hashtags), and LinkedIn (professional tone ending in an engaging question).
    • seo: Page titles, descriptions, and keywords.
    • slug & highlights: Key factual takeaways.
  • JSON Repair Node: A custom JavaScript parser handles potential AI syntax errors, stripping Markdown code block wrappers, escaping raw newlines inside JSON strings, closing unclosed brackets/quotes, and returning a valid, parseable JavaScript object.

4. Routing Content: Image vs. Video

To keep your social media feeds dynamic, a JavaScript node alternates or splits the output format:

// Alternating routes example
if (!imagePostedToday) {
    item.json.route = "image";
} else {
    item.json.route = "video";
}

Depending on this route, the system leverages different API endpoints in the creative suite.

Harnessing the Content Creator Paradise API

The core of our visual asset generation is the Content Creator Paradise API (https://od2.in/content-creator-paradise/api). By passing parameters via HTTP requests, the API programmatically compiles assets on-the-fly.

The Image Engine (/api/create/image/:category)

For static feed graphics and carousel posts, the workflow calls the Image API.

  • Templates: Select from available layouts (e.g., newsroom or news-editorial).
  • Query Parameters:
    • secret: Your od2_cc_Access_Token.
    • summary: AI-generated summary text.
    • quote: The main article headline or key quote.
    • template: Design layout template name.
    • brand & logo: Your custom brand name and logo URL.
    • image: URL of the primary image to render in the template.
    • handle & website: Your social handles and website domain.
  • Result: Returns a high-resolution PNG image ready for publishing.

The Video Engine (/api/create/video/:category)

To capture modern vertical video feeds (like Reels, Shorts, and TikToks), the workflow requests video rendering:

  • Template: Uses a vertical video layout (e.g., news-split-cover).
  • Query Parameters:
    • size1080x1920 (Vertical 9:16).
    • duration15 seconds (optimal for vertical reels).
    • fps60 for ultra-smooth rendering.
    • quote & summary: Primary texts rendered dynamically on screen.
    • points: AI-generated bullet highlights joined as a string.
    • ctaText: Custom call to action, e.g., Read More at yourdomain.com.
    • bgType & bgValue: Set to preset-image pointing to the feed article image.
    • audio: URL of a background track. The workflow selects from a pool of royalty-free background audio tracks.
    • savetrue (saves the video in the Content Creator Paradise database and returns a downloadable MP4/WebM URL).

Multi-Platform Publishing via Meta Graph API

Once the image or video asset is generated, the final phase of the n8n pipeline handles publishing.

Posting Images

  1. Facebook Page Photo Post: Sends a POST request to graph.facebook.com/v24.0/{FB_PAGE_ID}/photos containing the Page Access Token, the socialImageurl returned by the API, and the caption.
  2. Instagram Page Photo Post: First, uploads the image container via /media, then publishes the returned creation ID using /media_publish.

Posting Video Reels

Automating Reels requires a two-step polling procedure because Meta processes videos asynchronously:

  1. Initiate Upload: The workflow sends a request to graph.facebook.com/v23.0/{IG_PAGE_ID}/media with parameters:
    • video_url: The MP4 link returned by the Content Creator Paradise video generator.
    • caption: The Instagram copy compiled by the AI.
    • media_typeREELS.
  2. Asynchronous Polling: The video takes 30-90 seconds to process. The workflow enters a loop:
    • Wait Node: Pauses the workflow execution for 20 seconds.
    • Status Check: Queries /v24.0/{CREATION_ID}?fields=status_code.
    • Condition: If the status is IN_PROGRESS, it loops back to the Wait node.
    • Publish: Once the status returns FINISHED, the workflow hits /media_publish using the creation ID to push the Reel live.
  3. Facebook Video Post: Uploads the video URL to the Facebook page using graph-video.facebook.com/v24.0/{FB_PAGE_ID}/videos with the caption as the description.

Enterprise Monitoring & Diagnostics

No automation is perfect. To ensure that API limits, expired tokens, or network hitches don’t go unnoticed, the workflow embeds webhook notifications (e.g., Discord or Slack) at critical execution points:

  • Success Alerts: Pushes a rich card containing the post title, color-coded status, and image preview to a dedicated log channel.
  • Duplicate Handlers: Quietly logs skipped duplicate articles.
  • Failures & Errors: Catch-all nodes intercept SQL failures, API errors, and rate limits, instantly alert administrators with debugging data and execution links.

How to Set Up Your Own Engine

Here is the checklist to build this system yourself:

  1. Host n8n: Spin up an instance of n8n on your server or run it locally.
  2. Obtain Meta Developer Access:
    • Register an app at the Meta Developers Portal.
    • Connect your Instagram Business account to your Facebook Page.
    • Generate a Long-Lived Page Access Token with pages_manage_postsinstagram_basic, and instagram_content_publish.
  3. Get a Content Creator Paradise API Key:
  4. Configure AI Credentials: Add your Google Gemini API key or set up a local Ollama connection inside n8n.
  5. Import the Workflow: Load your automation JSON directly into your n8n workspace, configure the credentials, and hit Activate.

Summary of Benefits

By combining templates, n8n, and AI, you can:

  • Save 15+ Hours/Week: No more manually cropping images, choosing soundtracks, or waiting for video rendering.
  • Ensure Design Consistency: Templates guarantee brand guidelines (logos, colors, websites) are perfectly aligned on every post.
  • Boost Algorithmic Reach: Posting high-quality vertical Reels and static content multiple times a day increases engagement metrics.

Recommended Next Reads

Developer Publishing Portal

Have an Engineering Tutorial or Tool to Share?

Publish your software engineering guides, API walkthroughs, and technical insights on the OD2 Blog. Review our publishing conditions, formatting standards, and guidelines.

Loading Sponsor...