Case Study

Engineering Organic Reach at Scale

A proprietary Instagram engagement automation system built on deficit-based phase-gated drip algorithms — delivering growth in the exact ratios the platform expects, autonomously, across 20+ live campaigns.

12
Workflows
4
Delivery Phases
20+
Active Campaigns
100%
Autonomous
Client
Growth-Stage Brand
Category
Social Media Automation
Stack
n8n · NocoDB · Apify · Keycloak
Delivery
12 Workflows · 4 Phases
Built by
Del Rey Valmoria
// 01 — The Problem

Manual Management Triggered Algorithmic Suppression

A growth-stage brand operating across multiple Instagram presences faced a compounding problem: manual social media management produced engagement that looked exactly like what it was — inorganic. Likes arriving in batches. Comments clustered in a single hour. Views spiking, then flatline for days.

Instagram's algorithm is trained to detect precisely this pattern. When engagement ratios fall outside the statistical envelope of organic behavior, the platform suppresses reach — the content enters a low-distribution state that manual intervention cannot recover. The harder the team pushed, the worse the suppression became.

Beyond algorithmic risk, the operational overhead was unsustainable. A human operator was required to fire each campaign phase, monitor ratios, judge when to move from views to engagement, and decide when comments were safe to deploy. Every post demanded 3–4 manual interventions across a 24-hour window — a model that could not scale past a handful of simultaneous campaigns.

The brief was clear: eliminate human gates entirely while making the delivery pattern statistically indistinguishable from a real post gaining organic traction.

  • FAIL Engagement spikes from manual batching flagged as inorganic by algorithmic detectors
  • FAIL No ratio enforcement — likes-to-views ratios regularly exceeded 5%, triggering kills
  • FAIL Comments deployed without time gates — comment velocity inconsistent with view counts
  • FAIL Every campaign required 3–4 manual operator interventions over 24 hours
  • FAIL No deficit detection — shortfalls from previous phases went uncompensated
"The algorithm isn't looking for fake engagement. It's looking for engagement that doesn't match the expected statistical distribution of a real post."
// 02 — The Architecture

A Phase-Gated Drip Engine Built on Deficit Logic

The solution replaces every manual decision point with a deterministic state machine. Twelve n8n workflows orchestrate delivery across four time-gated phases, each workflow reading live post metrics before calculating how much engagement to inject — never more, never less than organic ranges allow.

01
Apify Scan
WF-9 / WF-10B
02
Campaign Create
WF-0 · Manual trigger
03
Phase 1 — Views
WF-1 · Exponential curve
04
Phase 3 — Engagement
WF-2/3/5/11 · 6h gate
05
Phase 4 — Comments
WF-7 · 24h gate
06
Monitor & Refire
WF-8 / WF-10A
NocoDB — campaign state SMMFlare API — delivery Apify — live metrics Keycloak OIDC — auth gate Chart.js v4 — dashboard viz
Infrastructure Layer

Orchestration

n8n v2.10.4 self-hosted. 12 workflows across campaign lifecycle. Cron + webhook triggers. Zero human gates in steady-state.

Data & State

NocoDB as campaign state store. Each row tracks post ID, phase status, delivered counts per metric, deficit carry-forward, and timestamps.

Intelligence Layer

Apify Instagram Scraper for live post metric reads. Profile-scraper (256 MB) preferred over post-scraper (512 MB) for 4× cost reduction.

Delivery API

SMMFlare API executes all engagement delivery. Receives exact calculated quantities per metric — no rounding, no padding beyond ratios.

Frontend

Vanilla HTML/JS/CSS — zero build step. Chart.js v4.4.0 for live campaign metrics. Mobile-first at 768px/640px/400px breakpoints.

Auth Gate

Keycloak 26 OIDC with PKCE S256 flow. Dashboard access requires authenticated session — no bypass path, no shared credentials.

// 03 — The Dashboard

Operational Control Surface

A single-page operator dashboard surfaces all 20+ active campaigns, per-metric delivery progress, workflow health status, and real-time ratio compliance indicators. Built with zero build tooling — pure HTML, CSS, and Chart.js.

SMM DRIP DASHBOARD LIVE 20 CAMPAIGNS ACTIVE WF HEALTH: 12/12 Campaigns Workflow Status Analytics Settings SYSTEM STATUS Workflows running 12 / 12 Active campaigns 22 Pending boosts 7 Ratio violations 0 VIEWS DELIVERY — LAST 7 DAYS 120k 80k 40k 0 MON TUE WED THU FRI SAT SUN TODAY Views Likes RATIO HEALTH Likes / Views 3.8% target 4% · kill 5% Shares / Views 2.8% target 3% · kill 4% Comments / Views 0.057% target 0.06% · kill 0.10% 24h gate: OPEN CAMPAIGN #001 Summer Reel — Post A VIEWS 84% LIKES 80% Phase 4 · 24h gate ACTIVE CAMPAIGN #002 Brand Story — Post B VIEWS 100% LIKES 100% All phases complete COMPLETE CAMPAIGN #003 Product Launch — Reel VIEWS 30% Phase 1 · 6h remaining Engagement gate: locked PENDING WORKFLOW HEALTH WF-0 WF-1 WF-2 WF-3 WF-5 WF-6 WF-7 WF-8 WF-9 WF-10A WF-10B WF-11 LAST SYNC: 2 MIN AGO | APIFY CREDITS: 8,420 REMAINING | RATIO VIOLATIONS (24H): 0 | ALL SYSTEMS NOMINAL

Dashboard UI — campaign cards, ratio health gauges, workflow status tiles, and 7-day delivery chart. Vanilla HTML/JS, zero build step.

// 04 — How It Works

12 Workflows. One Deterministic State Machine.

Each workflow owns a single responsibility. No workflow assumes another has completed. All state transitions are checked against NocoDB before any delivery call is made to the API. The full campaign lifecycle from post detection to final comment deployment runs without a single human touchpoint.

WF-0 — Campaign Creator
Trigger: Manual webhook · Operator fires once per post

Accepts a post URL and target parameters. Validates the post exists via Apify pre-scan, creates the NocoDB campaign row with phase status PENDING, and queues the post for WF-1. The only human touchpoint in the entire system.

NocoDB write · Apify validate
0
1
WF-1 — Views Batcher
Trigger: Cron · Exponential delivery curve

Delivers views in an exponential curve that mimics organic viral spread. Reads the current view count, calculates the remaining deficit against the target, and fires a calibrated batch. Never delivers the full target in one shot — curve shaping is the core of Phase 1.

Apify read · SMMFlare deliver · deficit calc
WF-2 — Likes Drip
Trigger: 6h gate after views target reached · 4% of views

Polls the current view count, calculates 4% as the like target, reads actual current likes from Apify, and delivers the deficit only — the difference between target and actual. Kill switch at 5%: if the ratio would breach the threshold, delivery halts.

ratio check · deficit delivery · kill switch
2
3
WF-3 — Shares Drip
Trigger: 6h gate · 3% of views · kill at 4%

Identical deficit pattern to WF-2 but targeting share count. Shares at 3% of views are at the high end of natural distributions — the kill threshold at 4% provides a safety margin before the algorithm detects amplification behavior.

6h time gate · deficit only · ratio guard
WF-5 & WF-11 — Reposts & Saves
Trigger: 6h gate · Reposts 0.5% · Saves 0.2%

Reposts and saves are the lowest-ratio metrics but among the most powerful signals for distribution. WF-5 targets 0.5% reposts; WF-11 targets 0.2% saves. Both operate on deficit logic with 6-hour phase gates, never firing ahead of the engagement window.

Phase 3 parallel delivery
5
6
WF-6 — Followers
Trigger: Absolute target · Not ratio-bound

The only metric not expressed as a ratio. WF-6 receives an absolute follower target per campaign and delivers to deficit. Followers are independent of view counts — organic follow rates vary too widely across account types to use ratio enforcement.

absolute target · deficit delivery
WF-7 — Comments
Trigger: 24h gate · 0.06% of views · kill at 0.10%

Comments are the most algorithmically sensitive metric. A comment velocity that doesn't match the account's post age and view count is a strong suppression signal. WF-7 enforces a hard 24-hour gate before any comment delivery, then applies the 0.06% ratio. Kill threshold at 0.10% — zero tolerance.

24h gate · strictest ratio · zero bypass
7
8
WF-8 — Status Refresher
Trigger: Scheduled · Reads Apify · Updates NocoDB state

Polling worker that runs on a schedule and refreshes the live metric snapshot for all active campaigns in NocoDB. Other workflows read from this cache rather than hitting Apify directly on every execution — reducing API credit consumption by batching reads.

Apify batch read · NocoDB state update
WF-9, WF-10A & WF-10B — Autonomous Detection
WF-10B: Daily cron · Auto-detects new posts · Zero human gate

WF-9 is the quick-boost pre-scanner: runs Apify before any boost fires to confirm the post is still accessible and metrics are fresh. WF-10A is the pending boost firer: polls NocoDB for campaigns in BOOST_PENDING state and fires them. WF-10B is the daily autonomous scanner: checks all monitored accounts for new posts and auto-creates campaigns — the system self-feeds.

WF-10B fully autonomous · no operator input
10
// 05 — The Algorithm

Ratio Targets, Kill Thresholds, and Deficit Logic

Every delivery decision is derived from a single question: what does this post's current metric count need to reach a ratio indistinguishable from organic growth? The answer is a precise deficit — never an estimate, never a padding buffer.

Metric Basis Target Ratio Kill Threshold Phase Gate Workflow
Views Absolute target Campaign param — Phase 1 · 0h WF-1
Likes % of views 4.0% >5.0% STOP Phase 3 · 6h WF-2
Shares % of views 3.0% >4.0% STOP Phase 3 · 6h WF-3
Reposts % of views 0.5% — Phase 3 · 6h WF-5
Followers Absolute target Campaign param — Phase 3 · 6h WF-6
Comments % of views 0.06% >0.10% STOP Phase 4 · 24h WF-7
Saves % of views 0.2% — Phase 3 · 6h WF-11
Phase-Gated Delivery Timeline
T+0h
Phase 1 — Views
WF-1 · Exponential batching · No ratio enforcement
0h gate
T+6h
Phase 3 — Likes / Shares / Reposts / Saves / Followers
WF-2 · WF-3 · WF-5 · WF-6 · WF-11 · Ratio-enforced · Deficit only
6h gate
T+24h
Phase 4 — Comments
WF-7 · Strictest ratio guard · 0.06% target · 0.10% absolute kill
24h gate

Deficit Detection Logic

Every ratio-based workflow follows the same three-step calculation before firing: (1) Read the current live metric count via Apify. (2) Compute the target count as views × ratio. (3) Deliver the delta: target − actual = deficit.

If the deficit is zero or negative (organic engagement already met the target), the workflow exits without calling the delivery API. If the ratio check shows a current ratio above the kill threshold, the workflow writes a RATIO_KILL event to NocoDB, skips delivery, and alerts the operator dashboard. No manual intervention is required or expected.

The source: 'backfill' flag on WF-9 quick boosts bypasses the 72-hour upper age gate (stale post protection) while keeping the 6-hour minimum gate fully enforced. This allows deficit recovery on posts that have aged past the normal campaign window.

// 06 — Results

What the System Delivers

A fully autonomous engagement engine running 24/7 across 20+ live campaigns, delivering every metric within organic ratio bounds, with zero operator touchpoints after initial campaign creation.

12
n8n Workflows
4
Delivery Phases
20+
Active Campaigns
0
Ratio Violations

Apify Cost Architecture

Early prototypes used the Apify post-scraper (512 MB actor) for all metric reads. Switching metric refreshes to the profile-scraper (256 MB actor) where post-level data was not required reduced Apify compute unit consumption by 4× per read cycle — a direct infrastructure cost reduction at scale.

Zero Build Frontend

The operator dashboard is vanilla HTML, CSS, and JavaScript with Chart.js v4.4.0 imported from CDN. No bundler, no framework, no compilation step. Deployment is a single file copy. Mobile-first breakpoints at 768px, 640px, and 400px keep the dashboard fully operational on a phone in the field.

PKCE Auth Gate

Keycloak 26 with PKCE S256 flow protects the dashboard. No shared passwords, no API key in the URL. Operator sessions expire and require re-authentication. The auth layer is fully decoupled from the campaign logic — dashboard access can be revoked without touching a single workflow.

n8n v2.10.4 NocoDB Apify Instagram Scraper SMMFlare API Chart.js v4.4.0 Keycloak 26 OIDC PKCE S256 Vanilla HTML/JS/CSS Coolify Deficit Detection Phase-Gated Delivery Exponential Curve Batching

Need Automation That Thinks Like a Systems Engineer?

I build proprietary automation infrastructure — from workflow engines to full-stack dashboards. If you need something built right, let's talk.

Get In Touch →
VIEW LIVE → VERIFIED DELIVERY RECORD → GITHUB →
LIVE PROOF

Dashboard — Live System

SMM Drip Engine control dashboard — 20+ active campaigns, fully autonomous.

SMM Drip dashboard

SMM DRIP — CAMPAIGN OVERVIEW DASHBOARD

SMM Drip detail

CAMPAIGN CONTROLS

SMM Drip workflow

PHASE-GATE WORKFLOW VIEW