Skip to main content
All projects
Automation & AI
/projects/zabesync

LinkedIn Content Automation Pipeline

project.zabesync.local
LinkedIn Content Automation Pipeline project screenshot
  1. Problem:

    LinkedIn content creation is time-intensive, repetitive, and often lacks real-time relevance, reducing posting consistency.

  2. Solution:

    Built an AI-driven n8n automation pipeline with live research, LLM-based generation, and Discord-triggered workflows with Supabase state management.

  3. Impact:

    Automated end-to-end ideation to publishing, reducing effort from hours to seconds and enabling consistent, high-quality output.

Overview

End-to-end automation from research and ideation to drafted posts and one-click publish, with human-in-the-loop via Discord and durable state for deduplication.

Results & metrics

  • Hours to seconds per content cycle
  • Zero duplicate topics via Supabase state tracking
  • 5-API orchestration (Discord, Drive, LinkedIn, Supabase, LLM)
  • Consistent posting cadence with minimal manual effort

Before / after

  • Publishing flow

    Before: Manual context-switching across tools

    After: Single pipeline with checkpointed state

  • Ideation

    Before: Ad hoc notes and repetition

    After: Deduped AI-assisted ideas delivered on schedule

  • Content Consistency

    Before: Irregular posting schedule subject to manual context switching

    After: Predictable, automated delivery pipeline scheduled directly from Discord

What I built

n8n content pipeline

Discord triggers n8n on EC2; an LLM drafts, Supabase dedups, LinkedIn publishes.

Discord control plane

Ideas, drafts and approve/reject buttons live in Discord; approval posts to LinkedIn.

Stack

  • AWS EC2 + Docker
  • n8n workflows
  • Supabase
  • LLM + web research
  • LinkedIn & Google APIs

Decisions

Key trade-offs and design calls that shaped the final delivery.

  • n8n over custom code

    Why
    Context
    Needed rapid workflow iteration without deployments for a content automation tool
    Decision
    Chose n8n visual workflow builder for AI-powered pipelines—allowed iterating on LLM prompts and API integrations without code changes
  • Discord as control plane

    Why
    Context
    Team already used Discord for daily communication
    Decision
    Made Discord the single interface for triggering, reviewing, and publishing—no separate dashboard needed, minimal context switching

Architecture

The primary system boundaries, runtime pieces, and how the project was structured in production.

Diagram, 6 connections:
  1. Discord → n8n on EC2
  2. n8n on EC2 → LLM + research
  3. n8n on EC2 → Supabase
  4. n8n on EC2 → Google Drive
  5. n8n on EC2 → LinkedIn API
  6. Supabase → n8n on EC2
Groups: Trigger & control: Discord; Automation: n8n on EC2, LLM + research; State & assets: Supabase, Google Drive; Outbound: LinkedIn API.
  • n8n workflows with Gemini LLM

    AI Content Engine

    How

    Three interconnected workflows: daily AI-powered idea pitcher with live web research and deduplication, content creator triggered by Discord that drafts posts and generates images, and one-click publisher that posts to LinkedIn.

  • Supabase

    State Management

    How

    Stores idea deduplication state, user preferences, and tracks which ideas have been pitched—prevents topic repetition across campaigns.

  • Discord Bot

    Control Interface

    How

    Sole control interface for the entire pipeline interactive buttons for approve/reject/publish, no manual LinkedIn interaction required.

Mermaid source

Paste into mermaid.live to edit the diagram.

flowchart LR
  subgraph ingest [Trigger & control]
    D[Discord]
  end
  subgraph compute [Automation]
    N[n8n on EC2]
    L[LLM + research]
  end
  subgraph data [State & assets]
    S[(Supabase)]
    G[Google Drive]
  end
  subgraph publish [Outbound]
    LI[LinkedIn API]
  end
  D --> N
  N --> L
  N --> S
  N --> G
  N --> LI
  S --> N

Pipeline

How changes moved from development through validation and deployment.

Select a step for its detail

Incidents

Operational failures, rehearsals, or recovery moments that changed how the system was run.

  • P2

    Free tier API limits causing workflow failures

    Resolution

    Implemented multi-AI fallback mechanism and concise prompt engineering to reduce token usage

    Lesson: Free tiers have hard limits—design fallback chains and optimize prompts for cost efficiency

  • P3

    Discord bot webhook connectivity issues

    Resolution

    Configured n8n webhook node with retry logic and proper Discord bot token management

    Lesson: Webhook integrations need retry logic and proper authentication handling

  • P3

    Web search API rate limiting

    Resolution

    Cached research results and batched searches to minimize API calls

    Lesson: Research APIs are expensive—cache aggressively and batch requests