Monday 7 March 2016

Using node, how can I login to websites and scrape the web?

As a hobby, I want to write scripts to automate certain things. For example, what if I wanted to reactivate my facebook, user cheerio.js to scrape it for info (nothing malicious), then deactivate it again all at once? Is this possible?I ask because I use the request library to get to reddit, and filling in the username and password options allowed me to log in to reddit. But doing the same thing didn't work with facebook. It's a little difficult with facebook because it seems to use some javascript click event on the login button to even log in (which you can't access except by trying to decipher the minified js file which at that point it's not worth it) so I can't figure out how to login from a script.I know some sites have APIs but I want to be a ninja and just write my own scripts from scratch.Is there some standard way to log into any website?

Submitted March 08, 2016 at 12:39AM by 98_Vikes

No comments:

Post a Comment