Java library for creating a session on server side to an XMPP server using BOSH prebinding
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

XMPP Prebind for Java

This class is for prebinding a XMPP Session with Java.

The code is based on the Candy Chat XMPP Prebind code for PHP ( Usage

  • Clone the repo

Example usage:

 * Create a new XMPP Object with the required params
 * @param String boshHost Jabber Server Host
 * @param String xmppDomain XMPP Domain
 * @param String boshUri    Full URI to the http-bind
 * @param String resource   Resource identifier (example "Work")
 * @param String boshPort	Bosh Port Number (usually 7070)
 * @param boolean   useSsl     Use SSL 
 * @param boolean   debug      Enable debug
	XMPPPrebind xmppPrebind = new XMPPPrebind(boshHost, xmppDomain, boshUri, resource, boshPort, useSsl, debug);
        xmppPrebind.connect(username, password);
        SessionInfo sessionInfo = xmppPrebind.getSessionInfo();
        System.out.println("jid:" + sessionInfo.getJid());
        System.out.println("sid:" + sessionInfo.getSid());
        System.out.println("rid:" + sessionInfo.getRid());
  • You should now have a working prebinding with Java!


If something doesn't work, you can enable Debug.

Here be dragons

This class is in no way feature complete. There may also be bugs.