If I want to make a Cocoa application that communicates with Windows Live Messenger, is there an API to do that, so I can make something like, for example, the eBuddy app?
Look into LibPurple.
Also look at Adium, which is a Cocoa app that uses LibPurple, and is open source.