How I Made $3,000 with 90 Lines of Code
Ah, hello, I see my linkbait headline worked.
This story begins in 2011 when I lived in New York and was working for the Hype Machine. Svpply had just raised a series A and reached out to me about a possible job opportunity. As a vocal advocate and user of the site, this intrigued me, however ultimately it wasn't the right time, as I was moving to the Bay Area.
Shortly after moving to Oakland, Wanelo reached out to me about a job opportunity. I was busy, so I declined, but mused about all these new pinning sites like Clipboard, Svpply, Pinterest, and now Wanelo, all going after different niches. Then I played with their site, quickly coming across a bug in the bookmarket. So I began looking through their Javascript, watching their api requests, noticed that while the bookmarklet was borked, the on-site product save page worked fine.
Then it all came together
For those of you who aren't aware, Amazon has an affiliate program which sends payouts for directing consumers to their website who then buy products. Svpply and Pinterest both replace/append these affiliate ID's on any Amazon links saved on their platform. While not lucrative, it can definitely keep the lights on. With this in mind, I realized a few things:
- It would be trivial to inject products into Wanelo.
- Wanelo didn't strip Amazon affiliate ID's from URLs.
- Svpply already had a highly curated list of Amazon products availible from their API.
I was working on Folindux at the time, so I took a day off that project, and whipped up a Ruby script. The script grabbed products from Svpply, properly mapped their categories to Wanelo's categories, and then added these products to my fake Wanelo user's account. Originally I tried to just send POST requests to Wanelo, as I'd been using Charles to snoop through requests and thought I had all the cookies I needed to preserve my user session. However after fighting with that for an hour or two I decided to dump lists of iframes into an HTML file, and go through and click all the links. Janky as shit but it worked like a charm.
I watched a movie and clicked "save" button after "save" button, adding ~20k products to Wanelo that night, before deciding to stop.
Over the next month I watched the numbers in the Amazon affiliate panel climb day by day. First $20, then $200. Ultimately Amazon sold $25,933.87 worth of products. Everything from Penis Pasta and anal lube, to Pink Skeleton Flamingos (no worries, these links don't have the super secret affiliate ID "olenaw-20").
The jig was finally up when Wanelo deleted all of our fake user's products and started replacing affiliate ID's with their own—smart move.
Rose and I took the 3k of affiliate kickback money that had accrued from this little scheme and vacationed all over Costa Rica for a month.
We traveled from Quepos and Manuel Antonio, to Liberia, Monteverde, Playa Penca, and finally Tamarindo. Personally I enjoyed Tamarindo the best, incredibly beautiful, waves you can surf on, good food, and seclusion if you want (across the river mouth). We stayed at a very nice German run villa I would definitely stay in again.
I'm currently building Gymsurfing, we sell discounted day passes to gyms. Use the promo code "dustin" after signup for $5 of free credit.