Yash Gupta

Yash Gupta

Software developer. I build multi-tenant systems in NestJS, Django and Next.js, and I find out where the time actually goes.

I work across three products at a B2B SaaS company: a multi-tenant WhatsApp business platform with 170+ connected business accounts, an ERP, and a CRM. Below are two measurements from that work, drawn to scale.

A 5,000-recipient campaign send

89 min to 6 min 14x faster

Loop
~89 min
Queue
~6 min
  • Serial loop, one send in flight
  • Redis job queue, 15 a second

Both rates are measured on production runs rather than calculated. The largest real run sent 18,615 contacts in 23.6 minutes, with no duplicates and no double charges across 20,637 sends.

One contacts-list request

515ms to 30ms 17x faster

Before
~515ms
After
~30ms
  • Scanning whole tables and sorting
  • Walking an index

Four queries per request, measured on a 528,000-row copy of production. Two join tables had no index at all, and one index could not be used for ordering.

Case studies

Each one covers the problem, what I found, what I changed and how I checked it. Customer names, identifiers and proprietary code are left out.

If you only read three: why a campaign took an hour and a half for measured performance work, selling the platform to a reseller for system design under a new tenancy boundary, and an API that works is not yet an API you can publish for how I verify a change I cannot take back.

  • 56 to 790 messages a minute, measured.

    The send loop slept on delays we had set ourselves. Removing them helped; the real ceiling was that it sent one message at a time.

    NestJS, BullMQ, Redis, WhatsApp Business API

  • A second tenancy boundary above the existing one: ownership of a company written into the schema, a billing owner hidden from the company's own member list, and a checkout that verifies Razorpay's signature and grants credits once under a row lock.

    NestJS, PostgreSQL, Drizzle ORM, Razorpay

  • Our API-key surface authenticated correctly and returned the right rows. It still answered a rejected send with a bare 500, lost a retry's idempotency key, and refused ?page=1 because an internal convention had leaked into the public contract. Changing it meant proving the other 59 of 74 responses stayed identical.

    NestJS, PostgreSQL, Redis, idempotency, API design

  • 515ms to 30ms per request.

    Unindexed join tables, composite indexes in the wrong column order, and an ORM default that silently made an index useless for sorting.

    PostgreSQL, EXPLAIN ANALYZE, Drizzle ORM

  • Money in a float column

    Live in production

    Every balance and ledger amount is a 32-bit float. One reconciliation query returned a different total each run because the planner changed the accumulation order, and a safety assertion started refusing to let the largest customers be charged at all.

    PostgreSQL, NestJS, Drizzle ORM, concurrency

  • A payment-funnel change in one service has to start a messaging journey in another. I built it on a transactional outbox, so an event exists exactly when the fact does.

    Django, Celery, PostgreSQL, HMAC-SHA256, NestJS

  • Three code paths mirrored the same provider data, none aware of the others, and left 356 duplicated templates across 153 production companies. A per-company advisory lock fixes it, but only because the rows are read again inside it.

    NestJS, PostgreSQL, Drizzle ORM, concurrency

  • iPhone customers buy plans and credits inside the app, and all my server gets is a message claiming a purchase happened. It asks Apple, and a partial unique index makes a replayed transaction impossible rather than merely unlikely.

    NestJS, PostgreSQL, App Store Server API, idempotency

  • Work that a deploy used to destroy

    Merged to production

    Campaign sending lived in a process a deploy could kill mid-run. Moving it onto a queue was the easy half; the rest was atomic claims in Lua, a reconciler for jobs the queue loses, and keeping "unknown" distinct from "failed".

    NestJS, Bull, Redis, Lua, PostgreSQL

  • Every campaign scheduled between midnight and 05:29 silently never sent, and the interface went on showing it as scheduled. Two date helpers disagreed by a day, and only in the timezone production runs in, so it could not be reproduced from a fresh checkout.

    NestJS, PostgreSQL, cron, Docker

  • The provider validates the device token before it ever reads your payload, so a fake token proves nothing. A harness driving a real browser against real infrastructure found three bugs, two of them already live.

    NestJS, Firebase Cloud Messaging, service workers

  • An 8-day outage that returned HTTP 200, media failing for about 90% of accounts, a unique index that stopped every invite expiring, and 26 hours of failures caused by trailing spaces.

    Webhooks, AWS S3, PostgreSQL, Django

  • Invoice PDFs go to business owners on WhatsApp through a provider we pay per message, and that traffic should come home to our own platform. A fallback to the old provider is only safe when failure proves nothing was sent, so the work is a taxonomy of failures that do and do not prove it.

    Django, Python, MySQL, WhatsApp Business API

  • 16/16 items scored, 13/13 with a verified quote.

    The server re-checks every model quote against the contract and shows the document's own words, not the model's, so an invented clause has no path to the screen.

    Next.js 15, TypeScript, Postgres with pgvector, Bull, Clerk, Docker

Experience

Software Development Engineer

B2B SaaS product company, May 2026 to present

  • A multi-tenant WhatsApp business platform: campaigns, inbox, chatbots, billing and onboarding for 170+ connected business accounts.
  • User Journeys: built end to end, from schema and event-ingest API to the dispatch scheduler and UI. Dark-launched, then taken live per tenant behind feature flags.
  • Payments and billing: server-verified iOS in-app purchases, and per-message metered billing that charges once from the delivery webhook and refuses sends when credits run out.
  • Delivery: campaign sending moved onto a Redis-backed queue with atomic claims, a reconciler and a circuit breaker.
  • Security: closed multi-tenant authorization holes, authenticated the real-time socket channel, and fixed a cross-tenant leak in the CRM.
  • An ERP and a payments product in Django: the outbound half of the event pipeline, on a transactional outbox with Celery workers.
  • A CRM in NestJS and Next.js: a staging environment refreshed from production behind data masking, a manual release gate, and a shared visual language across its screens.

Skills

Split by where I have actually used them.

In production
TypeScript, Node.js, NestJS, Python, Django, Celery, PostgreSQL, Redis, BullMQ, Docker, AWS S3, Linux, REST, webhooks, WebSockets, OAuth 2.0
Patterns I have shipped
Transactional outbox, idempotent consumers, atomic claims in Lua, reconciliation of lost work, circuit breakers, HMAC request signing, secret rotation, feature-flagged rollouts, multi-tenant isolation, composite indexing, server-verified in-app purchases, metered billing
AI tooling
Claude and Claude Code, Model Context Protocol tool servers, LLM tool calling, retrieval-augmented generation, embeddings and vector search, ChromaDB, LangChain, open-weight models run locally with Ollama
Also comfortable with
React, Next.js, SQL, Drizzle ORM

Education

B.Tech, Computer Science Engineering

O.P. Jindal University, Raigarh, 2022 to 2026

CGPA 9.0 out of 10

Achievements

  • NPTEL Reinforcement Learning, Elite, top 2%
  • NPTEL Cryptography and Network Security, Elite

Contact

I am open to backend and full-stack roles. The fastest way to reach me is email.