Okay, so a few days ago I posted about a different method of distributing Steam keys to people without me actually being online to send out PMs to everyone. I've come up with a possible idea and would like some opinions, advice, and possible help with cookies and HTTP requests. Mostly wondering if I can login to CP with C# and store cookies allowing my software to send out PMs and modify a post. But let's get on with the software.
Instead of creating a web page or software that allows people to request Steam keys, I simply create a web scraper. It'll watch the topic and keep track of posts. Granted, I'll have to enforce people to start requesting in a certain way e.g. "REQUEST: Sanctum 2". The web scraping is the easy part and keeping track of posts would also be easy. I'd store every parsed post into a database so the software wouldn't accidentally do the same request. It'd also track dates to prevent multiple requests. It'd also be the database for all the keys I have so when someone asks for a key and we don't have it, simply have the software post "Sorry, we don't have that key." Also keeping track of multiple keys for the same game. Everytime a PM would get sent out, it'll modify the original post with the list of remaining games.
Things it'll do in order to keep the rules and fairness of Steam keys
- Read topic every X minutes to check for new posts
- Parse all unread posts according to the software, store them as read so we don't parse them again. Check post body for request.
- Check last three REQUEST posts, to make sure the post hasn't requested recently, also check to see if 48 hours have passed since last post
- If request is legitimate, get username and send out a PM.
- Remove key from database, generate new topic, modify the original post with list
- Software will ignore any posts that don't have REQUEST: Game Name so normal discussions and questions can still go on.
- Machine will ignore all posts made by my account for obvious reasons.
Obviously, I'll throw in a few more checks and timers to make sure the system works properly. And I'll also do some tests with the machine in SPAM before making it go public obviously. Before I go into this, I remember Blizzad said that something shouldn't really need to be done as the system in place works now. It just takes time for me to send out keys when I'm working a lot.