
The kabadiwala doesn't care about the environment, and that's the whole design
How I built a Hindi-first app on AWS Lambda, RDS, S3 and Amplify that lets India's scrap collectors compare authorized recyclers on price, so e-waste moves from informal processing to formal facilities. Includes the region, dependency and build bugs I hit deploying with SAM.
Building Kabadiwala Connect on AWS for the Waste and Energy track
Most e-waste projects start from a hopeful idea: if people understood the harm, they would recycle properly. I started from the opposite one. A scrap collector choosing a buyer is thinking about rent, not about lead in groundwater. If the app depends on him caring, it will not work.
The numbers show why this matters. NITI Aayog and TERI's 2026 report says about 78% of India's e-waste is processed by the informal sector. That processing recovers 10 to 20% of the material, while formal facilities recover 95 to 97%. The collectors who feed that chain are not careless. They sell to the one buyer they know, at the price that buyer names, because they have nobody to compare against.
So Kabadiwala Connect does one thing: it gives the collector a comparison. He photographs his pile, enters a rough weight and an address, and sees what several authorized recyclers will pay for exactly that lot, best price first. He is paid more because buyers compete, and the material ends up at an authorized facility. The environment gets its win as a side effect of his own interest.
The part where AWS earned its place
The backend is FastAPI on AWS Lambda behind a Function URL. I chose that over API Gateway for a boring reason: the photo scan calls a vision model, and that call takes 10 to 30 seconds. API Gateway's REST integration gives up at around 29 seconds, so a slow scan would fail for the user while the function was still working. A Function URL has no such cap, and one setting in the SAM template gave me a public HTTPS endpoint. Wrapping the app with Mangum took one line.
Python
handler = Mangum(app, lifespan="off")
Photos go to S3, but the database stores only the object key, and every API response carries a fresh presigned link. That kept the bucket private without writing any access code. Lots, recyclers, rates and deal records live in RDS PostgreSQL, the frontend is on Amplify, and the whole backend is one
template.yaml I could redeploy with a single command.What my laptop was hiding
The app worked locally for days. Then I deployed it, and the cloud began telling me things I had not known.
My local AWS config pointed at Mumbai, while my IAM user and every resource were in Sydney. SAM failed with a generic organisation-policy deny that never mentioned a region, and presigned URLs later came back signed for the wrong one. I lost an embarrassing amount of time looking for a permissions problem that was really a default setting. Now the region is explicit in the code and in the CLI.
The first deploy that built successfully then crashed on startup:
No module named 'pg8000' . My requirements file had been a full pip freeze that would not even resolve, so I replaced it with only what the app imports, and missed one package. Every missing module showed up as one more full deploy. The fix took two minutes and I should have started with it: make a clean virtual environment and run python -c "import app.backend.main" before deploying anything.Amplify was the last surprise. It was set to monorepo mode while my build settings were in the plain format, so it failed three times with the same error, because retrying the same settings can never produce a different result.
The bug that looked like an AI problem
The vision model returns each box as
[ymin, xmin, ymax, xmax] on a 0 to 1000 scale. My frontend wants fractions of the image with a top-left origin. Without the conversion, boxes land in the wrong place, and it looks exactly like the model being inaccurate. I did the conversion on the backend and checked it the only way that works: drawing the boxes over a real photo. A range check cannot tell a swapped x and y.Building for someone who is not me
The collector may read little English and uses an inexpensive phone, so the app opens in Hindi, with one main action per screen, large high-contrast text, and an icon next to every category. The price range is the biggest text on the lot screen, because money is what he decides on.
I wrote the frontend with an AI coding agent, and it broke working code once. The Home list stopped loading because a stage renamed an element the old code still looked up. That is why I committed after every stage that passed my own check, and why I tested each screen against the live backend and never trusted the agent's own "it works".
What this does not prove
The recyclers, authorization details and rates are seeded demo data. I have not tested the app with real collectors, it needs a connection for every step, and detection misses items in a dense pile. I do not measure how much material the app diverts. What I can claim is the direction: each deal moves a lot from the informal chain to the formal one.
The next step is the one a hackathon cannot do: put it in front of a real collector and watch where he hesitates.
Live app: https://main.dbidovmuqj3gr.amplifyapp.com/
Code: https://github.com/jatin300107/Scrapsync
Demo video: https://www.youtube.com/watch?v=D-zfJFgcR30
Source: NITI Aayog and TERI, Advancing Circular Economy of Waste Electronic and Electrical Equipment (E-waste) and Lithium-Ion Batteries in India (January 2026), https://www.niti.gov.in/node/2108
Enjoyed reading this content? Let the author know!
Your likes, comments, shares, and saves help creators reach more builders.
Loading recommendations
Loading article