5 ms·
> The typical ways that folks - especially folks who don’t program - bump into bots are things like ticket scalping and restaurant reservation bots. Bots that f
by hunter2_ 2y ago
> The typical ways that folks - especially folks who don’t program - bump into bots are things like ticket scalping and restaurant reservation bots. Bots that feel selfish and unfair and antisocial.
This reminded me of how a ski resort, Palisades Tahoe, implemented free but scarce parking reservations for weekend parking last winter. Since it's one of the most popular ski destinations from the Bay Area, you can imagine that bots were written. Every time new spots would "drop" (become available for the following weekend) I think on Tuesdays and Fridays or something like that, they'd be gone in seconds. Clearly bots! So naturally I had no choice but to write one. It just alerted me (via Pushover) when cancelations would lead to open slots, it didn't actually reserve spots on its own, but that was good enough to get the job done for me and my crew.
Several Reddit threads had non-bot-writers discussing that bots must be slurping everything up. I felt so antisocial, but really had no choice.
- beachy 2y agoI use a bot for booking overnight huts on the more popular hiking trails in my country. They become available for booking online at a fixed time each year and are all taken a few seconds later. Using a bot is the only reliable way to get one. Amusingly there are news articles every year about whether or not people are using bots to book these huts and the operators always deny it vehemently. Whereas I know my bot is up against loads of other bots.
- MattJ100 2y agoOut of curiosity, what tech do you reach for when building something like this?
- beachy 2y agoSelenium
- hunter2_ 2y agoFor mine, I just used a $1/mo VPS with a cron job running a bash script that used curl to poll the parking system and determine if its response was interesting. I used "copy as cURL" from browser dev tools to find something usable (which incorporated a slightly fragile, but very long lived, session token corresponding to my "cart") and I actually had to use curl-impersonate [0] for Cloudflare bot detection to stay out of my way. And then curl to alert me via Pushover. [0] https://github.com/lwthiker/curl-impersonate https://github.com/lwthiker/curl-impersonate
- foobarian 2y agoWe used to run into the same issue booking camping spots in Massachusetts, which open many months in advance. I don't know what the situation is nowadays but it used to be very competitive, with spots vanishing in seconds after opening. Amusingly, one camper family we came across said they manually register at the stroke of midnight, but they all do it together from like 6 computers in their house.
- hunter2_ 2y ago> the operators always deny it I assume they deny knowing about bots. Nobody knows you're a dog, as the saying goes.
- maxbond 2y agoIt's a shame because the solution is very simple. You have a period of time where people can register interest which is long enough that everyone can do it at their leisure. After this window closes you draw lots. Whoever wins the lottery gets the opportunity to buy (eg by receiving an email with a magic link). If they don't, you draw another person and offer it to them. Otherwise you have an "auction" where instead of giving the resource to the people willing to pay the most, you give it to the people with the best programming skills (who then turn around and flip it to the people willing to pay the most). Which is pretty unfair, since programming is a specialty, and since presumably we're in a context where giving it to the people who pay the most isn't considered acceptable (or we would just hold an auction). I believe this is used in parts of the sneaker/fashion industry.
- hunter2_ 2y agoThat's good if there's something to buy, but in my scenario it's free. The resort's goal isn't to charge for this parking, it's to ensure that the number of vehicles on the roads leading to their parking lot doesn't exceed the number of parking spaces. So if they have N parking spaces, they allow N reservations to be made, but people are cautiously greedy and make a reservation (when the opportunity begins on the prior Tuesday) before they even know that they're planning to ski that weekend, leading to near-immediate depletion. If the weather isn't looking great, they'll eventually cancel their reservation (lest they get on the resort's no-show shit-list, which ultimately leads to the resort refusing your business -- you must cancel or be found to have parked) and those cancellations are what the bot alerts on. How would a lottery work for this situation? Everyone thinking of maybe skiing signs up on Monday, then on Tuesday an email is sent to N people saying "you won the parking lottery," then someone canceling last-minute (to avoid the no-show penalty) causes another "you won" email to go out randomly to the wait list? What if the person on the wait list doesn't see that they've won at the last minute, do they get a penalty for not having proactively removed themselves from the wait list upon deciding to ignore email the rest of the week? I guess this could work, but it's pretty dicey...
- maxbond 2y agoIt works the same, the price is just $0. I'm sure I'm missing nuances since I don't know this resort's business, but here's what I'd propose. You let people register interest by Monday (potentially weeks in advance). You draw N lots on Tuesday. People get an email, they have the option to reserve a space and 24 hours to exercise it. M people do so. On Wednesday you draw N - M lots. You keep going until either you've assigned all the spaces or you've run out of time. People will still exercise a greedy strategy, and they might cancel their interest ahead of time, but if the lottery hasn't started that's a free operation. If they click the link and indicate they aren't interested any longer, we can offer the spot to someone else immediately. If they never click the link, then it gets bumped to Wednesday. Hopefully that's tolerable. How far you may register in advance and how long you have to exercise your option are variables that you can tune. If you're getting overwhelmed and failing to assign spaces, you reduce one or the other. Last minute cancellations or spots that people repeatedly failed to click the link for, need to be assigned ASAP to avoid a dead weight loss; for these, you can fail back to the old system. Maybe you email everyone who hadn't gotten a space, and the first to click the link wins. If that were the edge case instead of the norm, it probably wouldn't be a big deal to give it to the bot folk. At that point, they're playing an important role in making this market efficient, the sort of HFTs of the ski resort. Alternatively, you can do just one round and then go to first-to-click. That gives the people who aren't botting room to breathe, at least. (After typing this all out though, I do see that this is conceptually simple but complex to implement.)
- eiiot 2y agoIt's so funny you mention this, I actually just launched something super similar today for the California DMV (as a Bay Area student). It checks for openings from cancellations and notifies people. There's a special kind of magic that comes from meaningfully improving your life from software :) (the project is https://dmvfilter.com https://dmvfilter.com if you want to check it out!)
- jddj 2y agoThe government services booking system has received this treatment in some parts of some southern european countries. Organised groups have monopolised the system and go on to sell appointments. It's an open secret that you can either battle the bots to try to get an appointment slot in 6 to 12 weeks, or you can pay 50€ to the right person and have one in a few days.
- Cthulhu_ 2y agoI should write a bot for making a parking reservation at work too. At least if there's no-shows people get told off for it (I wonder if they get barred from the parking reservation if they really take the piss after that though).
- seattle_spring 2y agoAt least you were actually using the parking spots for yourself and friends. Bots become truly problematic when they're used for reselling.
- appplication 2y agoDuring Covid I was forced to write a bot just to sign up for swim lane reservations at our local pool. Spots opened up at midnight two calendar days before. Most folks looking to regularly swim at 7am don’t make it a habit of starting up to midnight, and all spots were always booked up by the time I would wake up at 6am. So I wrote myself a bot, which was surprisingly fun and effective!
- onelesd 2y agoI had to do similar during the first summer of COVID to get my boat onto Lake Tahoe. Lake Tahoe (and most lakes in CA) requires boat inspections immediately prior to getting onto the water (mostly to prevent Quagga contamination). Those inspections had to be scheduled online during COVID, and there was similar supply & demand to what you describe for parking, so I wrote a bot that notified me (also via Pushover) when a slot became available. Once I got the reservation I had to tow the boat 9 hours, praying the whole time I didn't have a drop of water on the boat, for which most inspectors will immediately fail you and send you away. The inspection crew there turned out to be pretty awesome though, and they actually washed my whole boat down with hot water which apparently kills any (baby? egg? idk) Quagga muscles.