How to Self-Host Instagram DM Automation (Next.js + BullMQ + Redis)
Most chat automation tools charge per contact as your Reels grow. Self-hosting ReplyGo gives you an open-source Next.js web app and BullMQ background worker with zero per-subscriber fees.
1. Core Infrastructure Components
ReplyGo splits synchronous web requests from asynchronous Meta API delivery so webhook bursts never time out.
- ✓Web App (Next.js + React): Serves the landing pages, campaign builder, inbox, /r/[slug] redirects, and webhook endpoints.
- ✓Background Worker (Node.js + BullMQ): Processes queued comment/DM jobs, enforces rate limits, and retries transient failures.
- ✓PostgreSQL + Prisma: Stores workspaces, campaigns, encrypted OAuth tokens (AES-256-GCM), logs, and link clicks.
- ✓Redis: Powers BullMQ queues, webhook deduplication, sliding-window rate limiters, and tracked link caching.
2. Direct Meta App vs Zernio Connection
You choose how each deployment connects to Instagram. Direct Meta OAuth gives you zero third-party middleware costs, while Zernio handles Meta app configuration and review for teams that want faster onboarding.
3. SEO & Public Landing Pages on Your Domain
ReplyGo ships with robots.txt, dynamic sitemap.xml, canonical metadata, Open Graph preview images, and noindex protections on private dashboard, login, invite, and client report routes.
Frequently asked questions
What license is ReplyGo released under?
ReplyGo's core codebase is MIT-licensed open-source software with no contact or seat limits when self-hosted.
Can I deploy the web app on Vercel and the worker separately?
Yes. The Next.js web app and cron routes can run on Vercel or Docker, while the BullMQ worker runs as a persistent Node.js process connected to the same PostgreSQL and Redis instances.