How to add support for your IM client to IMVU. Usually this can be accomplished in fewer than 50 lines of python. Let's walk through an example for the Jabber Messenger client from Jabber.com. There are two parts to creating an IM plugin. First is the "detector" that interacts with the IM client directly to: find active chats, pulls the raw text out of them, and can cause them to send IM messages. The second part is the "service desc" which can parse the text pulled out by the detector. First the detector: class JabberMessengerDetector(ImDetector): def wantTopLevelWindow(self, hwnd): return win32functions.HwndIsClass(hwnd, "ATL:667D9E38") def serviceName(self): return "JabberMessenger" def supportsHtmlMessages(self): return False def internalContentTextFromWindow(self, hwnd, cachedContent): children = detector_FindChildWindows(hwnd, "RichEdit20W") childHwnd = children[0] length = win32functions.GetWindowTextLengthViaSendMessage(hwnd=childHwnd) if cachedContent and length == len(cachedContent): return cachedContent if length < 1: return None str = win32functions.GetWindowTextViaSendMessage(hwnd=childHwnd, bufLen=length) return str def rawSendImToWindow(self, hwnd, message): children = detector_FindChildWindows(hwnd, "RichEdit20W") childHwnd = children[1] win32functions.SetTextAndPressEnterPreservingContents(hwnd=childHwnd, message=message) This takes advantage of some IMVU modules, like win32functions, but this is not a requirement. You are welcome to use any normal win32 API calls using win32gui or win32api modules. As we move to other platforms, we'll add support for those systems' APIs as well. The detector works in three steps: 1) determine if it "wants" a top-level window. Usually you can tell if you want a window by looking at for its class name. If you have MSVC++ available, the tool Spy++ that comes with it is very handy for this purpose. 2) grab the raw text of the chat history. usually this is a simple as sending the WM_GETTEXT to the right child window. For some clients, it's more complex, and involves things like the MS Active Accessibility API or getting a handle to an embedded IE control. 3) sending an IM through this window. Most IM clients support setting the text in the right child window and sending a WM_CHAR or WM_KEYDOWN sequence to send the message. Now on to the service desc: class JabberMessengerServiceDesc(ImServiceDesc): def __init__(self): self.headerRe_ = re.compile( "^(JabberMessenger)\s+(.+)" ) self.mRe_ = re.compile("^(.+?): (.+)$", re.MULTILINE) def serviceName(self): return "JabberMessenger" def senderNameFromHeader(self, header): mo = self.headerRe_.match(header) if mo: return mo.group(2).strip() else: raise im.common.ImServiceError("No match for '%s'" % header) def messagesFromHistoryText(self, historyText): msgs = [] for match in self.mRe_.findall(historyText): imMsg = im.common.ImMessage() imMsg.from_ = match[0].strip() imMsg.message_ = match[1].strip() if not imMsg.message_: continue imMsg.timestamp_ = len(msgs) msgs.append(imMsg) return msgs This is composed of two parts. The first parses the title of the window (the "header") to determine the IM handle of the person you're chatting with. The second part takes the text provided by the detector and parses it into individual messages.