Phurple is the libpurple PHP binding, which makes the use of the instant messaging protocols such AIM (ICQ, Oscar), MSN, Yahoo etc. in PHP possible. It's implemented as a set of the internal classes. Learn more about the libpurple at http://developer.pidgin.im/wiki/WhatIsLibphurple. libpurples docs can be found at http://developer.pidgin.im/doxygen/dev/html/files.html
Actually, the Phurple is using the g_main_loop_run() function from the GLib to run the main loop. This makes impossible to use it within some webserver process. One of the possible models to use the extension for some web application could be AJAX web interface, which communicates with the Phurple through the inetd sevice. At the moment I'm working on the possibility to integrate the glibs main loop into some other main loop, which could give a chance to use this extension within a webserver (may be even multithreaded).
The last development news can be found at http://thinker.rubay.de/ or at http://sourceforge.net/projects/phurple/