Finding An XMPP/Jabber Client or Library That Can Be Used in Scripts

I have been trying to find a command-line XMPP/Jabber client for the Linux platform that can be called from scripts. More specifically, I want to run it on OpenWrt, which poses a unique challenge; unless its pre-compiled binary is provided from its repository, it is hard to build it on your own because you will have to cross-compile it on a Linux box.

My primary objective is to use it so I can exchange information with my OpenWrt router by way of Google Hangouts. One requirement is that it support embedded images. This seems to mean in the XMPP world that the extension “XEP-0231: Bits of Binary” is supported.

I know Xmpp client written in bash / ash (openwrt). It’s only dependency is ncat (or similar) for the actual ssl connection doesn’t support XEP-0231, but I gave it a shot anyway. I thought even if it doesn’t support XEP-0231, I could get away with a simple approach described in “How can I send an image on the web in an XMPP (Jabber) message?

The system simply didn’t work on my OpenWrt router, unfortunately. I did not bother trying to investigate why it was not working, because it does not support XEP-0231 anyway.

Matthew Wild publishes his projects related to Lua and XMPP, which include the Verse XMPP library for Lua and the Riddim Verse-based bot framework. Verse unfortunately does not support XEP-0231. Perhaps you could implement it relatively easily, but I have no idea at this point.

SleekXMPP Python XMPP library is the only package that I found that supports XEP-0231. “Supported XEPs” says otherwise, but I confirmed that it is included in the stable 1.3.1 version. I have also found a sample code to send an image in a chat message with SleekXMPP. Installing SleekXMPP on my OpenWrt router was a lot of work, though.

Hangups is a very young Python library to access Google Hangouts.

By the way, I run Asterisk with its XMPP/Jabber support enabled. If there was an XMPP/Jabber equivalent of the SMSq command, I would have used it, but no such luck. You could access your Asterisk instance using its AMI or AGI interfaces and have it take care of your XMPP/Jabber needs. But I decided against it because working with the AMI or AGI interfaces seemed like an overkill; plus Asterisk would not be able to handle embedded images.

Finding An XMPP/Jabber Client or Library That Can Be Used in Scripts」への2件のフィードバック

  1. ピンバック: OpenWrtにSleekXMPPをインストール | あくまで暫定措置としてのブログ
  2. ピンバック: Androidスマホへの電力消費の少ないメッセージ通知法 | あくまで暫定措置としてのブログ


以下に詳細を記入するか、アイコンをクリックしてログインしてください。 ロゴ アカウントを使ってコメントしています。 ログアウト /  変更 )

Twitter 画像

Twitter アカウントを使ってコメントしています。 ログアウト /  変更 )

Facebook の写真

Facebook アカウントを使ってコメントしています。 ログアウト /  変更 )

%s と連携中

このサイトはスパムを低減するために Akismet を使っています。コメントデータの処理方法の詳細はこちらをご覧ください