import sleekxmpp client = sleekxmpp.Client("address@example.net", "password") client.connect() client.process(blocking=False) client.send_message(mto="remote@example.net", mbody=self.msg)
XMPPTCPConnection connection = new XMPPTCPConnection("user", "password", "example.org") connection.connect().login(); Message message = new Message("otheruser@example.net", "Hi, how are you?"); connection.sendStanza(message); connection.disconnect();