Catch up on stories from the past week (and beyond) at the Slashdot story archive

 



Forgot your password?
typodupeerror
×
Social Networks

Journal zukinux's Journal: Facebook automation script?

Once I've done that "send message to all the girls" (*it started with a bet though*) on one social network, I've had lots of request for scripts (see the related journal - Ultimate computer usage ).
Some of them, as you can guess are not in some weird social security sites without any security or randomization stuff, so I had to change my ways in order to do automatic stuff on lets say, facebook.com;
When I've started to check what can I do, it looked weird, no longer possible to send some wget posts with post-data stuff in-order to change some variables. Well, Yeah, it's possible, but facebook is using some techniques to make it harder and with some random variables for sessions and stuff like that. So using wget to post stuff is out of the question
I've thought hard what to do? Well, I can start a session using python, act like a browser and do my thing, but facebook actually detects which browser are not scripts and doesn't want script to do stuff on it (like you think).
So, I've remembered there's a library for python called PyWinAuto which uses the gui of programs you want (enumerate windows and such, i.e : Click on the program File Menu and afterward click on New, then enter in the box 1.txt and click okay)
But guess what, I'm not a windows user, and wanted more general solution for Linux... so I've searched for automation for python/firefox and havn't found anything spectacular.
I've decided to use mozrepl and saw that it can be an interactive debugger for javascript (so cool!). But it's not what I've wanted:

it's not in python
it's interactive and cannot be made as a script

So What I've decided to do is build a python wrapper for it (on sourceforge soon), and uses javascript to interact with the objects on facebook.com
I didn't know it before that javascript can be ridiculously powerful!
There's so much you can do using it, so what's ended up is that I've made a pythonish javascript debugger using mozrepl so I can use javascript on the session of firefox using python! so fucking cool.
Afterward I've made a script that sends automatic messages , and I guess I'm not limited to nothing, the skies are the limit with javascript dynamic debugger and python powerful stuff.
I can auto reply on messages, I can auto status updates, etc!

So my tour forward my goal had a bit of research but it was really a nice project. Soon I will post links to download it :]
This discussion has been archived. No new comments can be posted.

Facebook automation script?

Comments Filter:

Any circuit design must contain at least one part which is obsolete, two parts which are unobtainable, and three parts which are still under development.

Working...