Note: I built this because I think it's hilarious to give out a link to rorchat instead of giving out my phone number, email, or LinkedIn. If you're here because I sent you this link instead of my contact info ā yes, this is real, and yes, I do actually respond. It's non ironically the best way to reach me, when someone messages me I get a full page push notification on my phone - it's the only app I have that on for!
What It Does
rorchat is a web-based messaging app that lets anyone start a conversation with me. It works like a personal customer support chat, but for personal use:
- Visitors sign up with just a username and password, then chat
- Admin (me) responds from a protected dashboard at
/admin
Tech Stack
| Layer | Technology |
|---|---|
| Frontend | Next.js 16 (React 18, App Router) |
| Backend | Next.js API Routes |
| Database | PostgreSQL via Supabase |
| Auth | Custom username/password (bcrypt + hashed session tokens) |
| Deployment | Vercel |
Key Features
For Users
- š Simple signup (username + password only, no email)
- š¬ Real-time chat with polling (2-second intervals)
- āØļø Typing indicators
- š Emoji reactions (š ā¤ļø š š® š¢)
- ā©ļø Reply-to-message threading
- š· Image messages (auto-compressed)
- š¼ļø Profile picture upload with crop tool
- āļø Change username anytime
- š Push notifications (optional)
For Admin
- š Conversation list with user avatars
- š¬ Full chat history per conversation
- āØļø See when users are typing
- š· Send image messages
- š Push notifications for new messages
Architecture
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā Browser ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤
ā / (User Chat) ā /admin (Admin Dashboard) ā
ā - Auth modal ā - Password-protected ā
ā - Message view ā - Conversation list ā
ā - Image upload ā - Reply interface ā
āāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāā“āāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāā
ā ā
ā¼ ā¼
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā Next.js API Routes ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤
ā /api/auth/* - signup, signin, signout, me, profile ā
ā /api/chat/* - messages, typing, reactions, upload ā
ā /api/admin/* - login, conversations, messages, reply ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā
ā¼
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā PostgreSQL (Supabase) ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤
ā users ā Sessions + hashed passwords ā
ā sessions ā Hashed session tokens (30-day expiry) ā
ā conversations ā User ā Admin chat threads ā
ā messages ā Text + images + replies ā
ā message_reactions ā Emoji reactions per message ā
ā typing_status ā Who's currently typing ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāSecurity Model
| Aspect | Implementation |
|---|---|
| Passwords | Bcrypt hashing |
| Sessions | Random 256-bit tokens, SHA-256 hashed in DB |
| Cookies | httpOnly, secure (prod), sameSite: lax |
| Database | RLS enabled, all Supabase public API access revoked |
| API | All DB access through server-side API routes only |
Project Structure
rorchat/
āāā app/
ā āāā page.tsx # Main user chat interface
ā āāā admin/page.tsx # Admin dashboard
ā āāā layout.tsx # Root layout with fonts
ā āāā globals.css # All styling
ā āāā api/
ā āāā auth/* # User auth endpoints
ā āāā chat/* # User messaging endpoints
ā āāā admin/* # Admin-only endpoints
āāā lib/
ā āāā db.ts # PostgreSQL connection pool
ā āāā auth.ts # Session management
ā āāā imageUtils.ts # Image processing
ā āāā ImageCropper.tsx # Profile pic crop tool
ā āāā usePushNotifications.ts
āāā public/
āāā sw.js # Service worker for pushSummary
rorchat is a clean, mobile-first personal messaging app. It's essentially "DMs with Rory" ā visitors create an account and chat, I respond from a dashboard. Built with Next.js and Supabase, it prioritizes simplicity (no email required) and security (no direct DB access from browser).