I am looking to send an image inline through Jabber similar to how you can send a screen snip. I am currently using BotKit, and I am looking at creating my own message stanza but can't find any examples of how to properly do this. I have seen two methods where one is to upload to an http server and then use a url in the message doing something like <img>url here</img> or doing a base64 encode of the image and puting that in the message stanza.
What is the preferred method and is there a real trivial example of sending a basic image inline using Cisco Jabber and the actual XML message stanza that would be sent to achieve it?