Thursday, September 01, 2005

VIP SMS from Python

Croatian mobile phone service provider VIP offers its users a way to send SMS through a web page on the VIP portal. Users are limited to 15 messages per day, but these messages are free, so it's a nice feature :)

Unfortunately, I don't use it much because I'm not regular visitor to the VIP portal, so logging in, navigating to the Web2SMS page and filling out the form is too much hassle for me. I'd rather have an utility, GUI or CLI, for doing this. VIP provides no such client, nor specifies a web service, which would allow others to create clients.

Luckily, their web implementation is fairly simple. There's one html form for login, another for sending message, and the session variables are being carried around in Cookies. With a little help of urllib and cookielib I was able to hack up a working code in a half an hour.

So here it is. I've been testing it under Cygwin/WinXP, but it should work everywhere. The command line usage is:

    vipsms.py user password phone_number 'text of the message'

Now, a GUI version would be cool. I'm using GNOME (at home; at work i'm on Windows, hence Cygwin), so I'll try to hack up something with PyGtk.

2 Comments:

Anonymous Anonymous said...

EXCELLENT! Could you please do the same for the other Croatian Mobile Phone Network? I am going to use your code for a Konfabulator widget if that's all right with you.

10:06 PM  
Anonymous Anonymous said...

w00t! I pwn3d j00!
btw zas u mojim mueslima ima tolko ljuske od oraha?

10:10 PM  

Post a Comment

Subscribe to Post Comments [Atom]

<< Home