Chapter 2

The WhatsApp PDF Problem (The Origin)

Subhash Choudhary · 16 min read

Part 1: The Idea and the Skateboard

Every startup story begins with a problem. Ours began with a grainy PDF and the chaos of a nationwide lockdown.

The year was 2020. The world had pressed a giant pause button. In India, streets that were once a chaotic symphony of horns, hawkers, and humanity fell silent. The familiar rhythm of daily life was broken. For millions of small business owners-the kirana store uncle, the neighborhood vegetable vendor, the lady selling homemade sarees-it was a catastrophe. Their shutters were down, their customers were locked in, and their livelihoods were evaporating.

The only lifeline was the internet, specifically, WhatsApp. It became the new marketplace, the new storefront, the new bargaining counter. But it was a messy, inefficient, and deeply frustrating one.

This is where my co-founder, Suumit, enters the picture. He wasn't trying to build a company; he was just trying to help a local grocery store in his neighborhood stay afloat. He watched, fascinated and horrified, as they conducted their entire business through a series of chaotic WhatsApp chats.

The process was a masterclass in inefficiency.

Step 1: The Catalog. The shopkeeper would send every potential customer a multi-page PDF document. It was a terribly formatted, low-resolution file, likely made in Microsoft Word and saved incorrectly. Product names were misaligned, prices were blurry, and it was impossible to search. To find out if they had your favorite brand of biscuits, you had to manually scroll through five pages of grainy images.

Step 2: The Order. The customer, after much squinting and zooming, would then have to type out their entire order in a long, error-prone text message. "Ek packet Maggi, do kilo atta, aadha kilo cheeni, woh blue wala Lays ka packet..." (One packet of Maggi, two kilos of flour, half a kilo of sugar, that blue Lays packet...)

Step 3: The Confirmation. The shopkeeper, now juggling dozens of such chats, would have to manually confirm each item. "Sorry madam, blue Lays is out of stock, we have green." This would trigger another round of back-and-forth messages.

Step 4: The Payment. Finally, after the order was confirmed, the shopkeeper would send his UPI ID or a QR code. The customer would pay using GPay or PhonePe and then-the most crucial step-send a screenshot of the successful transaction as proof. The shopkeeper's phone gallery was a graveyard of thousands of payment screenshots, with no easy way to reconcile who had paid for what.

It was a nightmare. A digital jugaad (a makeshift hack) born out of desperation.

One evening, my phone rang. It was Suumit. I could hear the energy crackling through the receiver. He wasn't just talking; he was practically vibrating with an idea.

"Subhash, yaar, this is crazy," he began, launching straight in without a hello. "I'm watching this uncle try to run his entire shop on WhatsApp, and it's a disaster. He's losing orders, mixing up payments... it's just broken. We have to do something."

He painted the picture I just described, the messy dance of PDFs and screenshots.

"We need to build something simple for these guys," he said, his voice getting more intense. "Ek app, jahan pe woh log apna saaman list kar sakein, aur customers seedha order kar dein. Simple. No PDFs, no long chats. Just a link. They get their own online dukaan." (One app, where they can list their products, and customers can order directly. Simple... their own online shop.)

The word hung in the air: Dukaan. Shop.

He was right. The problem wasn't a lack of technology; it was a lack of simplicity. These sellers didn't need a complex platform like Amazon or Shopify. They didn't have the time or the technical skills for that. They needed something as easy to use as WhatsApp itself, but designed for commerce.

That phone call was the spark. But an idea is just a thought. To turn it into something real, you have to build. And in the startup world, you have to build fast. We didn't have the luxury of spending six months creating a perfect product. We needed to know, within days, if this was an idea worth pursuing.

This brings us to one of the most important concepts for any aspiring founder or techie: the MVP.

Technical Deep Dive: The Minimum Viable Product (MVP)

The term MVP, or Minimum Viable Product, is thrown around a lot in the tech world. Most people think it means building a smaller, buggier version of your final product. That's wrong.

An MVP is not a product. It's an experiment.

Its primary goal is not to make money or attract millions of users. Its primary goal is to learn. It's a scientific tool designed to test your most critical hypothesis with the least amount of effort. Our hypothesis was: "If we give small business owners a dead-simple tool to create an online store, will they use it?"

To test this, we didn't need a perfect product. We needed the simplest possible thing that could answer the question. This is the MVP philosophy.

Think of it like this: If your goal is to solve the problem of "transportation," you don't start by building a car. A car is complex-it has an engine, wheels, seats, a chassis, electronics. Building one takes a long time. By the time you're done, you might find out that your customers actually wanted a motorcycle.

The MVP approach is to first build a skateboard. It's basic, it's simple, but it solves the core problem: it gets you from point A to point B. It allows you to test your core hypothesis. Do people even want to move around on wheels?

Once you confirm that, you can use the feedback to build the next version: a scooter. Then a bicycle. Then a motorcycle. And finally, a car. At each stage, you are learning and delivering value.

So, for Dukaan, we had to define our skateboard. What was the absolute bare minimum we needed to build to test our idea? We threw out every fancy feature we could think of. No payment gateway integration, no delivery tracking, no customer accounts, no themes, no analytics. We stripped it down to its absolute essence.

We defined this as Dukaan's Core Loop:

That was it. That was our skateboard.

It wasn't a "platform." It wasn't an "e-commerce suite." It was a simple tool to replace a ugly PDF with a clean, mobile-friendly webpage. It was the absolute minimum required to solve the core problem.

With the plan set, we gave ourselves a challenge. No long development cycles. No drawn-out planning sessions. We would build and launch this MVP in a single weekend.

The 48-hour hackathon was on. The clock was ticking. Now, we had to make our first big technical decision: what tools would we use to build our skateboard?

Part 2: Choosing Our Tools

The 48-hour clock was ticking. We had our "what"-the MVP, our digital skateboard. Now we needed the "how." What tools would we use to build it?

In the world of software, your set of tools is called a "tech stack." Think of it like building a house. You have to decide your primary materials. Will you use brick, wood, or steel? What kind of foundation will you lay? What tools will you use to put it all together? These choices determine how fast you can build, how sturdy your house will be, and how easy it is to add a new room later.

For a weekend hackathon, the choice is governed by one principle above all else: speed. We didn't need the most scalable, most cutting-edge, or most "buzzword-compliant" stack. We needed the stack that would get us from zero to a working product in the shortest time possible.

This meant choosing tools that were familiar, reliable, and did a lot of the heavy lifting for us.

Technical Deep Dive: The Language and Framework

Our first and most important choice was the programming language and the framework.

Why Python?

A programming language is the vocabulary you use to give instructions to a computer. We chose Python. Why? Because Python is famous for its simple, clean syntax. It reads almost like plain English. When you're in a race against time, the last thing you want is to fight with your own tools, trying to remember a complicated rule or a missing semicolon. Python gets out of your way and lets you focus on the problem you're trying to solve. It also has a massive community and a library for almost anything you can imagine.

Why Django: The "Batteries-Included" Framework

A language is just the vocabulary. A framework is the whole instruction manual. It provides the structure, the blueprints, and a set of pre-built components so you don't have to start from scratch.

Imagine you're building a house. You could go and chop down your own trees, mill your own lumber, and forge your own nails. Or, you could buy a pre-fabricated house kit that comes with all the walls, windows, and doors already built. All you have to do is assemble them and add your personal touches.

That's Django. It's the pre-fabricated house kit for web applications. Its philosophy is famously "batteries-included." This means it comes with almost everything you need right out of the box. For our 48-hour MVP, two of these "batteries" were absolute game-changers:

Technical Deep Dive: Alternatives We Considered

Of course, Django wasn't the only option. In tech, there are always a dozen ways to do anything. The key is to choose the right tool for the job at hand.

Technical Deep Dive: The Database

With the framework chosen, we needed to decide where we would permanently store all our information-the store names, product details, prices, etc. We needed a database. If the framework is the house kit, the database is the foundation it's built on. It needs to be solid, reliable, and organized.

Why a Relational Database?

We chose a relational database. The idea is simple: data is stored in tables, like giant, powerful Excel spreadsheets. You have a stores table with all the store information. You have a products table with all the product information. And, crucially, you can create relationships between them. You can tell the database that every product must belong to a store.

This structure is perfect for e-commerce. Your data has clear relationships and rules. You don't want products floating around without a store, or orders without a customer. A relational database enforces this structure and ensures your data stays clean and consistent.

Why PostgreSQL?

Among the many relational databases (like MySQL, Microsoft SQL Server, etc.), we chose PostgreSQL (often just called "Postgres").

Why? For an MVP, Postgres and its main rival, MySQL, are both excellent choices. But we leaned towards Postgres for a few reasons. It has a reputation in the developer community for being incredibly robust, reliable, and standards-compliant. It's a true workhorse. More importantly, I knew it had some powerful advanced features that might be useful later on. One of them, a feature called LISTEN/NOTIFY, would become the secret weapon behind our real-time caching system in Chapter 8. We didn't need it for the MVP, but choosing a powerful foundation from day one, even if you don't use all its features immediately, can pay off massively in the future.

So, the blueprint was ready. Our tech stack was decided:

We had our building materials. Now it was time to pour the foundation and put up the first walls. It was time to set up our server.

Part 3: Pouring the Foundation

With our tech stack decided, the theoretical part was over. It was time to make something real. We needed a place for our code to live on the internet. We needed a server.

If our code was the blueprint and our stack was the building materials, the server was the actual plot of land. It's the physical (or, in our case, virtual) space where you pour the foundation and erect the building for the world to see.

Choosing a server provider in the early days is about finding the right balance between cost, simplicity, and power. We didn't need the infinite power of Amazon Web Services (AWS) or Google Cloud. That would have been like buying an entire industrial park to build a single house. It was too complex and too expensive for our needs. We needed a simple, affordable plot of land.

For that, we turned to DigitalOcean.

Technical Deep Dive: Setting Up Your First Server

DigitalOcean became popular with developers for one reason: it made getting a server incredibly simple. They called their servers "Droplets," a friendly name that removed the intimidating aura of traditional server hosting.

A Practical Guide to DigitalOcean Droplets

Getting our first server, the infamous 512MB machine that would later cause so much drama, took less than five minutes. Here's how simple it was:

That's it. We waited about 60 seconds, and DigitalOcean provisioned our server. We were now the proud owners of a public IP address-a unique address for our server on the global internet. Our small plot of land was ready.

SSH: Your Key to the Server Room

Now that we had our land, we needed a way to get inside and start building. You don't just use a web browser to control a server; you use a special tool called SSH (Secure Shell).

Think of your server as a secure, windowless building in a remote location. SSH is your magical, encrypted key. You use a command in your terminal, like ssh root@123.45.67.89, to unlock the door and step inside. Once you're in, you have a command-line interface, a text-based way to give direct instructions to the server: install software, create files, run your application.

This was our workspace. A black screen with a blinking cursor, connected securely to our new server in Bangalore. It was time to install the final pieces of our infrastructure: the software that would actually show our website to the world.

Nginx + Gunicorn: The Waiter and the Kitchen Staff

You can't just run a Django application by itself and expect it to work. Django is a framework for building the application logic-it's the set of recipes and the head chef. But it's not designed to handle thousands of raw, unfiltered requests from the internet. Doing so would be like letting thousands of hungry customers run directly into your kitchen and shout their orders at the chef. It would be chaos.

You need a system to manage the flow. For a Python web application, this is typically a two-part system: a Web Server and an Application Server.

The flow is simple but powerful: A user's request comes from the internet and hits Nginx. Nginx either serves a static file directly or passes the request to Gunicorn. Gunicorn then runs our Django code to process the request, generate the HTML page, and hands the response back to Nginx, which finally delivers it to the user.

Setting this up involved installing Nginx and Gunicorn on our server and writing a couple of simple configuration files to tell them how to talk to each other. With that final piece in place, our foundation was poured and our structure was up. We pointed a domain name, mydukaan.io, to our server's IP address.

With trembling fingers, I typed the address into my browser and hit Enter.

It worked. A simple "Hello, World" page served from our tiny $5 server.

Our skateboard was built. The 48 hours were almost up. It was time to see if anyone wanted to ride it.

Key Takeaways

  • The MVP is an experiment to test your core hypothesis, not a small version of your final product. Its goal is to maximize learning, not features. Define your "skateboard" before you write a single line of code.
  • Choose your initial tech stack for speed and familiarity. In the beginning, "time to market" is the most important metric. Pick "batteries-included" frameworks like Django or Rails that do the heavy lifting for you.
  • A solid database is a good long-term bet. Choosing a robust, feature-rich database like PostgreSQL from day one can save you major headaches and enable powerful features down the line, even if you don't use them immediately.
  • Start small and simple with your infrastructure. A $5/month server is more than enough to handle your first few thousand users. Don't overcomplicate or overspend on cloud services until you have a proven need.
  • Understand the roles of a web server (Nginx) and an application server (Gunicorn). This fundamental pattern of a "waiter" and a "kitchen manager" is the backbone of how modern web applications are served.