Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How do I get notified via text/notification any time a guest joins a chatroom?

Vipin Chamakkala May 12, 2013

I'd like to get an alert each and every time a guest joins the chatroom, so that I can get on and talk to them. I understand I may need to create a bot to do this. I don't have any coding experience though, so is there an easy step by step way to add a bot with this functionality? Or another way to do it?

Hipchat support directed me to here to pose this question... Any and all help would be greatly appreciated.

1 answer

1 vote
crivers
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 13, 2013

Unfortunately, most bots are designed to respond to messages and perform actions rather than respond to users entering the room. In order to accomplish what you're looking for, your best bet is probably to take an existing bot and extend it to respond to XMPP presence messages.

Once you have a bot that can detect presence messages, you can detect guests entering the room by looking for <presence> stanzas sent to the desired room where the role attribute on inner <item> node is "visitor". For example:

&lt;presence xmlns="jabber:client" to="1_5@chat.hipchat.com/osx" from="1_hipchat@conf.hipchat.com/Chris Rivers"&gt;
	&lt;x xmlns="http://jabber.org/protocol/muc#user"&gt;
		&lt;item affiliation="member" jid="1_2@chat.hipchat.com" role="visitor"/&gt;
	&lt;/x&gt;
&lt;/presence&gt;

You can view our instructions for running a bot at http://help.hipchat.com/knowledgebase/articles/64359-running-a-hipchat-bot.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events