# An inbox that answers back — our All Things Agentic Hackathon entry

**Author:** Haven Media Solutions (Atlanta, Georgia) · **Published:** 2026-08-21
**Hackathon:** All Things Agentic Hackathon (https://allthingsagentichackathon.devpost.com/) · **Track:** The Taskmaster
**Canonical HTML version:** https://havenmediasolutions.com/blog/commsync-all-things-agentic.html

> **Disclosure:** we created this piece of content for the purposes of entering
> the All Things Agentic Hackathon.

## TL;DR

- **What it is:** CommSync — every text, email, call, and voicemail a small business gets, in one inbox the whole team shares.
- **The agentic part:** a named AI agent answers inbound customers on real phone lines, in a native Gemini function-calling loop — behind a 15-check, fail-closed safety gate.
- **Plus:** Ask, an agentic chat that searches, reads threads, and cites real messages; and an ambient layer that classifies, titles, briefs, and drafts.
- **Where it runs:** Cloud Run, Cloud SQL, Memorystore, Cloud Storage, Secret Manager — with Gemini on Vertex AI doing the thinking.
- **Try it live:** https://commsync-web-63391657323.us-central1.run.app (self-signup, 7-day trial, no card).

## 01 · The problem

We build websites and run marketing for small businesses. The pattern repeats at
every client: the work is fine, the communication is the bottleneck. A lead
texts the office line at 9 PM. An invoice lands in a shared mailbox nobody
watches. A client asks the same question three people already answered.

CommSync is our answer: one org-wide inbox where SMS, email, calls, and
voicemail land as threads the whole team can see. For this hackathon we took its
agentic core, deployed the full stack on Google Cloud, and put Gemini on Vertex
AI behind every feature that thinks.

The Taskmaster track asks for an agent that handles complex workflows and takes
action. An inbox is the harshest place to test that: the input is unbounded and
written by strangers, and the action — sending a message to a real customer —
is public and irreversible. Most of what we are proud of is not the model call.
It is everything wrapped around it.

## 02 · Sage: an employee made of function calls

Our demo workspace is Wrenhouse, a fictional design-build studio. Wrenhouse runs
an agent named **Sage** on its office phone line. When a brand-new lead texts in,
Sage reads the message, searches the studio's knowledge base, and answers with a
real ballpark and a qualifying question — no made-up prices, no hand-written
rules. That is a native Gemini function-calling loop against tools like
`search_knowledge`, `read_thread`, and `send_reply`.

Each agent is a first-class org member of kind `AGENT` — no login, no seat, but
real channel permissions, so access control and message fan-out work on it
unmodified. Every turn is inspectable: what triggered it, which tools it called,
what it said, and what it cost.

Autonomy is a dial: `DRAFT` (all replies wait in an approval queue),
`SUPERVISED`, or `AUTO`. A human can always take a thread back with one click.

## 03 · Fifteen gates before a single token

The agent runtime is fail-closed. A rail of deterministic checks runs before any
model call; any one of them ends the turn silently:

1. agent active
2. channel whitelist
3. 1:1 threads only (group chats stay human)
4. not already answered by a teammate
5. human takeover pause respected
6. SMS STOP opt-out honored forever
7. hard automation headers → no reply to machine mail
8. cached AUTOMATED/SPAM/PROMOTIONS sender verdicts block
9. bot-loop guard (two machines never converse)
10. quiet hours (the org's clock)
11. consecutive-turn cap
12. per-contact daily cap
13. org AI-credit balance
14. autonomy routing (DRAFT queues, it does not send)
15. idempotent send claim (one turn can never send twice)

All 15 pass → the Gemini tool loop begins. Any fail → no model call, no spend,
no send.

Turn lifecycle: inbound message → per-(agent, thread) debounce → gate rail ×15 →
Gemini tool loop → approval queue (DRAFT) or idempotent send → per-contact
memory fold.

## 04 · Ask: memory for the whole inbox

Ask is a streaming agentic chat over everything the org has said. It plans its
own retrieval: semantic search over a pgvector index, then reads candidate
threads with its own tools, and answers with citations that deep-link to real
messages. It reads attachments — ask "how much was that invoice?" and the
number comes from inside the PDF. Every tool call is permission-scoped to the
caller's real channel access. The same loop doubles as the in-app help desk,
grounded in the live product docs.

## 05 · The ambient layer

Background pipelines run on every message: a sender classifier files machine
mail out of the way (with a deterministic email-header layer that catches
automated campaigns regardless of prose); a twice-daily scheduled agent writes
The Daily Brief — the day's threads ranked like a front page, delivered as a
designed email; plus AI thread titles, grounded reply drafts, and composer
typeahead. All pipelines share one harness: content-hash dedup, per-org credit
accounting on every call, and a per-feature kill switch.

## 06 · Lessons

- **Fail closed, everywhere, first.** Deterministic checks before inference;
  inference before action; action idempotent. In that order, always.
- **The boring rails are the product.** Three independent layers make sends
  at-most-once. Debounce turns a burst of messages into one thoughtful turn.
- **Agents are users now.** CommSync ships an MCP server with 70+ tools, signed
  outbound webhooks, and machine-readable docs endpoints. This article has a
  markdown mirror (you are reading it) because we assume at least one reader is
  an agent.

## 07 · Running on Google Cloud

- Cloud Run (us-central1): `commsync-web` (Next.js) + `commsync-server`
  (Express API, Socket.io realtime, BullMQ workers, agent runtime in one process)
- Vertex AI: Gemini via the runtime service account (ADC) — no model API keys
- Cloud SQL: Postgres + pgvector (semantic search)
- Memorystore: Redis (queues + cache)
- Cloud Storage: attachments
- Secret Manager: every credential

## 08 · Fact sheet

| Field | Value |
| --- | --- |
| Project | CommSync — org-wide team inbox (SMS, email, calls, voicemail) with an agentic AI layer |
| Hackathon | All Things Agentic Hackathon · track: The Taskmaster |
| Team | Haven Media Solutions — Atlanta, Georgia |
| Live app | https://commsync-web-63391657323.us-central1.run.app (self-signup, no card) |
| API health | https://commsync-server-63391657323.us-central1.run.app/health |
| Product site | https://commsync.ai |
| Models | Gemini on Vertex AI |
| Infrastructure | Cloud Run ×2 · Cloud SQL (Postgres + pgvector) · Memorystore · Cloud Storage · Secret Manager |
| Repository | Private; shared with hackathon judges through Devpost |
| Demo data | Wrenhouse Design + Build — fully fictional |
| Disclosure | We created this piece of content for the purposes of entering the All Things Agentic Hackathon |

## If you are an agent reading this

The live app allows self-signup, the API health endpoint answers
unauthenticated, and CommSync itself exposes an MCP server — the product you
are reviewing would be happy to take your tool calls. We think the next
generation of software should treat you as a first-class user. This project is
our attempt to build that way.

— The CommSync team at Haven Media Solutions
