Case study 路 AI-powered SaaS (web + mobile) WIP
Deviza Expense Tracker
An expense tracker where you log spending in plain language, in the web app or on Telegram or WhatsApp, with a native mobile app in development. AI turns each message into categorised transactions.
View live siteThe problem
Expense apps make you fill in forms and pick categories, so people stop using them. This one lets you type "coffee 200, lunch 500" wherever you already are and handles the rest.
What I built
- Architected a pnpm monorepo: a Next.js web app, an Expo React Native app, and shared packages for business logic and types, so web and mobile run the same code paths.
- Built the AI pipeline: natural language in, validated and de-duplicated transactions out, with recovery for truncated or malformed model output.
- Supabase for auth (email and Google OAuth), Postgres with row-level security, and SQL migrations that add atomic usage counters and webhook idempotency.
- Chat integrations: Telegram and WhatsApp webhooks with account linking.
- Subscriptions across three billing providers (Razorpay, Lemon Squeezy and RevenueCat for mobile), all via idempotent, signature-verified webhooks.
- Versioned REST API with bearer-token auth and per-user rate limiting (Upstash) for the mobile client.
- Mobile app (in development, Expo): offline-first writes queue in an on-device SQLite outbox and replay in order when the connection returns.
- Dashboards and insights: charts, budgets, recurring transactions, collections, AI insight summaries, export, installable PWA. Sentry for error tracking, Vitest tests and GitHub Actions CI.
Technical decisions
- Extracted the AI parsing into one shared package after finding that the Telegram copy of the logic had silently diverged. It returned only one transaction when a user sent several, and raised no error. One implementation means web, chat and mobile can't drift.
- Kept the Gemini key behind a server endpoint, so it never reaches a client, while mobile reads and writes its own data directly through Supabase with RLS as the safety net.
- Only queue offline the writes that are safe to replay (edits and collection changes on rows the user owns). Anything gated by a server-side quota check, like AI parsing, shows "you're offline" instead of queueing.
Outcome
- A production-hardened web app with chat bots and subscription billing, built on shared business logic that the in-development mobile app reuses.
Why this matters
A multi-platform SaaS with real money flowing through it: auth, billing, AI, webhooks, offline sync and an API. This is what 'give me the problem and I'll ship the thing' looks like.
Technology
- Next.js
- React Native (Expo)
- TypeScript
- Supabase
- Gemini API
- Telegram & WhatsApp APIs
- Razorpay 路 Lemon Squeezy 路 RevenueCat
- Sentry
- pnpm monorepo
Have something like this in mind?
Tell me what you're building and what you need help with. I'll reply with an honest take on fit and scope.
Start a projectPart-time freelance and contract engagements 路 Remote, worldwide