DEV Community

mamoor123
mamoor123

Posted on • Originally published at github.com

I Open-Sourced a Company OS That Replaces 5 SaaS Tools โ€” With AI Agents That Actually Do Work ๐Ÿค–

I was paying $600+/month for Trello + Notion + Gmail + Zapier + a chatbot tool.

Five tabs open at all times. Five subscriptions bleeding money. Five places where context went to die. ๐Ÿ˜ฉ

One day I asked myself: what if one app did all of this โ€” and I actually owned it?

So I built HiveOps ๐Ÿ โ€” an open-source company operating system with AI agents that execute real work, not just chat.

Here's why it's different from everything else out there. ๐Ÿ‘‡


๐Ÿšจ The Problem Nobody Talks About

Every SaaS tool solves ONE problem:

  • Trello โ†’ tasks
  • Notion โ†’ docs
  • Gmail โ†’ email
  • Zapier โ†’ automation
  • Chatbot โ†’ AI

But your work doesn't live in silos. A customer email becomes a task. A task triggers a workflow. A workflow notifies your team. It's all connected โ€” except your tools aren't.

You end up copy-pasting between 5 tabs and paying for the privilege. ๐Ÿ’ธ


๐Ÿค– Meet the AI Agents (This Changes Everything)

Here's what most "AI tools" actually are: a chatbot in a fancy wrapper. You ask a question. It gives an answer. You still do the work.

HiveOps agents are different. They execute tasks like real workers:

pending โ†’ execute โ†’ retry (10s) โ†’ retry (20s) โ†’ retry (40s) โ†’ dead letter queue โ†’ notify creator
Enter fullscreen mode Exit fullscreen mode

That's the same retry + backoff + DLQ pattern you'd use in a production message queue. Except it's running your business operations. ๐Ÿ”„

The killer feature? Agents delegate to each other.

// Marketing agent needs a landing page?
// Delegate to the Engineering agent.
await agentDelegate(
  marketingAgentId,
  engineeringAgentId,
  "We need a landing page for Q2 campaign",
  taskId
);
Enter fullscreen mode Exit fullscreen mode

Each agent has:

  • โœ๏ธ Custom system prompt (personality + instructions)
  • ๐Ÿข Department assignment
  • โ–ถ๏ธ Auto-execution loop (picks up pending tasks automatically)
  • ๐Ÿ” Retry logic with exponential backoff
  • ๐Ÿ’€ Dead letter queue after 3 failures

You assign a task to an agent โ†’ it picks it up โ†’ runs it โ†’ handles errors โ†’ notifies you if it fails. No human babysitting required.

AI Agents


๐Ÿ“‹ Task Management โ€” Built for Teams AND Agents

Every task has:

  • ๐Ÿ”ด๐ŸŸก๐ŸŸ ๐ŸŸข Priority levels (urgent โ†’ low)
  • ๐Ÿ“Š Status tracking (pending โ†’ in progress โ†’ review โ†’ completed โ†’ blocked)
  • ๐Ÿ‘ค Assign to humans OR ๐Ÿค– AI agents
  • ๐Ÿ’ฌ Comments and file attachments
  • ๐Ÿ” Retry tracking with error history

Task Management


๐Ÿ”„ Workflow Automation โ€” No Zapier Tax

The rule engine follows a dead-simple pattern:

Trigger โ†’ Condition โ†’ Action

Example workflow:

  • ๐Ÿ”” When: Task is created
  • โœ… If: priority = urgent
  • โšก Then: Notify manager โ†’ Auto-assign to ops agent โ†’ Post in #urgent channel

Three pre-built workflows come out of the box. Create your own in seconds.

Workflow Automation


๐Ÿ“ง Real Email โ€” Not a Mock

Inbox. Sent. Drafts. Starred. Labels. Search.

  • ๐Ÿ“ฅ IMAP polling for inbound mail
  • ๐Ÿ“ค SMTP for outbound
  • ๐Ÿค– AI drafts replies based on context
  • ๐Ÿ”” Auto-notifications for new mail

Not a demo. Not a mock. Real email inside your OS.

Email Client


๐Ÿ’ฌ Real-Time Chat โ€” Socket.IO

  • ๐Ÿ“ข Department channels
  • โœ‰๏ธ Direct messaging
  • ๐Ÿค– Agent chat (talk to your AI workers)
  • โŒจ๏ธ Typing indicators
  • ๐Ÿ”” Real-time notifications

Real-Time Chat


๐Ÿ— Under the Hood (Architecture)

hiveops/
โ”œโ”€โ”€ server/               # Node.js + Express
โ”‚   โ”œโ”€โ”€ src/
โ”‚   โ”‚   โ”œโ”€โ”€ services/
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ ai-engine.js        # LLM integration
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ execution-loop.js   # Retry + backoff + DLQ
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ workflows.js        # Rule engine
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ scheduler.js        # DB-persisted cron
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ email-real.js       # SMTP + IMAP
โ”‚   โ”‚   โ””โ”€โ”€ routes/                 # 12 API modules
โ”‚   โ””โ”€โ”€ __tests__/                  # 58 tests โœ…
โ”œโ”€โ”€ web/                  # Next.js 14 + Tailwind
โ””โ”€โ”€ docker-compose.yml    # Postgres + API + Web
Enter fullscreen mode Exit fullscreen mode

Tech stack:

  • ๐Ÿ–ฅ๏ธ Backend: Node.js + Express
  • ๐ŸŽจ Frontend: Next.js 14 (App Router) + React 18 + Tailwind
  • ๐Ÿ’พ Database: SQLite (dev) OR PostgreSQL (production) โ€” same API, one env var switch
  • โšก Real-time: Socket.IO
  • ๐Ÿ” Auth: JWT + bcrypt + role-based access
  • ๐Ÿง  AI: Any OpenAI-compatible API (OpenAI, Ollama, local models)

The dual-database adapter I'm most proud of โ€” same code, both backends:

// Works on SQLite AND PostgreSQL โ€” zero changes
const user = await db.prepare('SELECT * FROM users WHERE id = ?').get(id);
const tasks = await db.prepare('SELECT * FROM tasks WHERE status = ?').all('pending');
Enter fullscreen mode Exit fullscreen mode

๐Ÿ” Self-Host = Your Data, Your Rules

SaaS Stack HiveOps
๐Ÿ’ฐ Cost $50-500/tool/month Free forever
๐Ÿ  Data Their servers Your servers
๐Ÿค– AI Separate subscription Built-in
โšก Automation Zapier $30+/mo Included
๐Ÿณ Setup Sign up + configure docker-compose up

Your tasks, emails, chat messages, and knowledge base never leave your infrastructure. ๐Ÿ 


๐Ÿš€ Run It in 60 Seconds

git clone https://github.com/mamoor123/hiveops.git && cd hiveops
cp .env.example .env
openssl rand -base64 32        # paste into .env as JWT_SECRET
docker-compose up --build
Enter fullscreen mode Exit fullscreen mode

Open http://localhost:3000 โ†’ create account โ†’ done. ๐ŸŽฏ

No Docker? No problem. SQLite mode works standalone:

cd server && npm install && npm run migrate
JWT_SECRET=your-secret npm run dev
Enter fullscreen mode Exit fullscreen mode

๐Ÿงช It's Actually Tested

58 tests. Not "vibes-based" development:

  • ๐Ÿ” Auth โ€” 14 tests (register, login, profile, tokens)
  • ๐Ÿ“‹ Tasks โ€” 13 tests (CRUD, filters, comments)
  • ๐Ÿ”„ Workflows โ€” 8 tests (triggers, conditions, actions)
  • ๐Ÿค– AI โ€” 11 tests (chat, execution, delegation)
  • ๐Ÿข Departments โ€” 12 tests (knowledge, email)

๐Ÿงฉ Full Feature List

  • โœ… Task Management (priorities, statuses, assignments, comments, attachments)
  • ๐Ÿค– AI Agents (auto-execution, retries, DLQ, agent-to-agent delegation)
  • ๐Ÿ”„ Workflow Automation (trigger โ†’ condition โ†’ action rules)
  • ๐Ÿ“ง Real Email (SMTP + IMAP, AI draft replies)
  • ๐Ÿ’ฌ Real-Time Chat (Socket.IO, channels, typing indicators)
  • ๐Ÿ“š Knowledge Base (full-text search, categories)
  • โฐ Scheduler (DB-persisted cron, auto-creates tasks)
  • ๐Ÿ” JWT Auth + Role-Based Access (admin/member)
  • ๐Ÿ“Š Dashboard (live stats)

๐Ÿ”ฎ What's Coming

  • ๐Ÿ“ฑ Mobile-friendly responsive UI
  • ๐Ÿ“… Calendar view for tasks
  • ๐Ÿ”— Webhook integrations
  • ๐Ÿข Multi-tenant support
  • ๐Ÿ” SSO (SAML/OIDC)

๐Ÿ’ฌ The Real Question

What SaaS tools are you paying for that could be one self-hosted app?

I'm genuinely curious. Drop a comment ๐Ÿ‘‡ โ€” especially if you've tried replacing a SaaS stack with something you own.


โญ Star the repo if this was useful: github.com/mamoor123/hiveops

Built with โค๏ธ and a stubborn refusal to pay $600/month for things that should be free.


P.S. โ€” If you want to contribute, all PRs welcome. Check out CONTRIBUTING.md.

Top comments (0)