A Grok Bot inbox syncs hourly to Neon and requires a human Send click
Source read in fullRead first
Overview
The author claims a mail.grokbot.com inbox and builds a personal mail app on top. The bot handles mail and the app uses only its own database.
Workflow
- Trigger: Give Grok Bot its own inbox. Grok Bot can claim one. "The address is permanent, so choose it carefully." The author has the bot claim it, sends a test through an approved draft card and replies from Gmail. "The loop worked on the first try."
- By hand: Keep the app away from the mail provider. The rule is "the app never talks to the mail provider". With no public inbox API, faking one with a browser session token "breaks, leaks or gets your account flagged". The app is Next.js on Vercel, stores mail in Neon Postgres, uses Clerk for author-only login and reads and writes its own database.
- Bot: Sync inbound mail hourly and send via draft cards. A Grok Bot routine syncs new mail to Neon hourly from 8:00 to 22:00. The app queues messages or replies. Grok Bot turns them into draft cards and "nothing goes out until I press Send". Starred and Trash exist only in the app and leave provider state alone.
- By hand: Handle security and deployment issues. Treat received mail as untrusted: "Prompt injection is real." The bot treats mail as data, sanitizes HTML and blocks remote images by default. The Cursor Origin repo needs a higher Vercel plan than Hobby. The first deployment returned 500 and Vercel could not initially see the repo.
- Check: The author verified a full round trip on claiming the inbox: send via draft card, reply from Gmail and receive the reply. Every outbound email requires the author to click Send on the draft card. The full checklist is in the author's blog setup guide, which was not archived.
Key points and results
- The app sticks to its database when there is no API. The author keeps browser sessions out of unofficial mailbox APIs and lets the bot do the mail work.
- The human Send click is the only outbound gate. Outgoing mail becomes draft cards and waits for approval.
- Treat email as hostile input. Sanitize HTML, block remote images by default and have the bot treat mail as data to avoid embedded instructions.
- The permanent address sends as the bot. The author's two gotchas are that the address is fixed once chosen and outbound mail identifies the bot.
- The first deployment returned 500. The author reports the Vercel plan issue with an Origin repo and the initial deployment error firsthand.
Source
- Platform
- X
- Author
- Kondas Viktor
- Published
- Categories
- Mail and calendar, Code and repos
What this evidence label means
Source read in full
We read the source (post, article or transcript). That only means the original was read. It does not mean this site reproduced the author's results.