Frontend- Next.js, backend - node.js server and the database postgres. made completely using AI. hosted on digital ocean and vercel. Learnt different things all from AI and sometimes udemy.
AI & Accounting

Frontend- Next.js, backend - node.js server and the database postgres. made completely using AI. hosted on digital ocean and vercel. Learnt different things all from AI and sometimes udemy.

Author : CA. Shiwam Agarwal

Watch on Youtube

Use Case (one line)

A practising Chartered Accountant directed AI to build a production-grade accounting ERP — and that ERP uses AI to do the work CAs hate most: reading vendor invoices and booking them after checking goods receipt, quantity sold, and GST portal data.

The double helix: the system was built by AI and it runs on AI.

The Problem

In day-to-day CA practice and in the accounts departments we serve, the most expensive work is also the most repetitive:

  1. Vendor invoice booking — a clerk reads each PDF/photo invoice, types the vendor, GSTIN, line items and tax split, and posts a voucher. Slow, error-prone, and it scales only by hiring more people.
  2. Paying without proof — invoices get paid before anyone confirms the goods were actually received, how much has actually been sold, or whether the invoice even appears in the GST portal (GSTR-2B). This leaks working capital and creates input-tax-credit risk.
  3. No real controls — in small/mid practices, the same person can see and touch everything. A cashier can see payroll; a branch manager can see another branch. That breaks segregation of duties.
  4. No memory — when a figure is questioned months later, nobody can say who changed it, who downloaded the file, or who logged in from where.
  5. Off-the-shelf software is rigid, expensive to customise, and a CA cannot bend it to a specific practice's controls.

The Solution

A single, multi-client accounting platform — 168 screens, 157 database tables, 377 permission rules and 109 API modules — that an individual CA built and that 10–30 users across 1–3 businesses operate daily. Its flagship capability is an AI-assisted, pay-smart invoice pipeline:

  1. AI reads the invoice. Upload a PDF or photo; an AI vision model extracts vendor, GSTIN, line items, and the full tax break-up (IGST/CGST/SGST/cess/round-off) into structured, editable fields.
  2. Match to goods receipt. The invoice is reconciled against the Goods Receipt / MRR — did we actually receive these goods, and for how much?
  3. See what's been sold. At payment time the screen shows quantity actually sold against that purchase, so you never overpay for stock still sitting unsold.
  4. Check the GST portal. It surfaces the GSTR-2B difference — does this invoice match what the supplier filed? — protecting input tax credit.
  5. Book it. One click creates a balanced, double-entry vendor journal entry; the GST-2B match is inherited onto the entry automatically.

Around this sit the controls a real firm needs: granular role + branch locking (a cashier cannot see payroll; a manager sees cashier and payroll but not vendor entries), a complete audit trail (who changed what, who logged in from where, who up/downloaded which file, plus a full before/after snapshot of every entry), and a single document vault (KYC, bank statements, employee photos, reports, audit reports, daily expenses, invoices — all in cloud storage). Bank statements are imported by deterministic, 100%-confidence account mapping with no AI at all — a deliberate choice: AI for unstructured reading, exact code for the numbers that must never be guessed.

How We Implemented It

AI tools used

  1. Claude Code — the AI coding agent that wrote the bulk of the application (backend services, database layer, frontend screens) under human direction.
  2. Claude (Anthropic) models via API — power the product's own AI: vision-based invoice extraction (using batch processing and prompt caching to cut cost), and tool-use parsing of statutory PDFs.

How it was built (technical): I am a CA, not a software engineer. Instead of writing code, I encoded the rules of the domain into a guardrail file the AI must obey on every change — money is never stored as floating-point (a fixed-precision decimal library is mandatory), every voucher must balance by a database trigger, future-dated entries are blocked, every change is versioned, and the code must follow a strict layered architecture (Routes → Controllers → Services → Repositories → Database). The AI then built — and keeps extending — an enterprise system inside those rules. The domain expert sets the law; the AI does the labour, at a scale and speed no single person could.

A bug AI helped me solve: After building strict role-and-branch locking, a subtle hole remained — a cashier could still see and operate every cash counter, not just their own. Using AI to debug systematically, we traced it to a single wrong assumption in how “global access” was decided (it keyed off only one of two access flags). The fix established a clear rule — a user is global only if they need neither a branch nor a cash counter — and closed the leak. A textbook internal-control failure, found and fixed by reasoning, not guesswork.

The Result

  1. Invoice booking time: from 4–5 minutes of manual typing per invoice to a few seconds of AI extraction plus a quick review.
  2. Scale: 10–30 users / 1–3 businesses run on it today; 1,0000+ invoices read, matched and booked.
  3. Money protected: vendors are no longer paid before goods are confirmed received, sold, and matched to GSTR-2B — protecting cash and input tax credit.
  4. Controls & trust: complete who-did-what audit history and enforced segregation of duties — the firm can answer any “who, when, from where” question instantly.
  5. The headline: a single domain expert, using AI, delivered software that previously needed a funded engineering team — and that software now does the profession's most tedious work automatically.

“I used to hope my team got it right. Now I can guarantee it.”