Service DiscoveryΒΆ

Note

This documentation describes HipChat specific extensions to XEP-0030: Service Discovery, and parts of XEP-0045: Multi-User Chat. More information on the protocols used in this section can be found in these documents.

When making disco#items requests against the MUC service as defined in XEP-0045, you may also choose to specify the include_archived attribute to include or exclude (the default) archived rooms.

<iq id="1" type="get" to="conf.hipchat.com">
    <query xmlns="http://jabber.org/protocol/disco#items" include_archived="true" />
</iq>

The response MAY include HipChat-specific room information in an x element qualified by the http://hipchat.com/protocol/muc#rooms namespace. For example:

<!-- Client -->
<iq type="get" to="conf.hipchat.com">
  <query xmlns="http://jabber.org/protocol/disco#items"/>
</iq>

<!-- Server -->
<iq from='conf.hipchat.com' type='result' to='1_1@chat.hipchat.com/mac'>
  <query xmlns='http://jabber.org/protocol/disco#items'>
    <item jid='1_hipchat@conf.hipchat.com' name='HipChat'>
      <x xmlns='http://hipchat.com/protocol/muc#room'>
        <id>1</id>
        <topic>This is the topic</topic>
        <privacy>public</privacy>
        <owner>1_1@chat.hipchat.com</owner>
        <num_participants>0</num_participants>
        <guest_url/>
        <last_active>1343073497</last_active>
      </x>
    </item>
    <item>...</item>
    <item>...</item>
    <item>...</item>
  </query>
</iq>
raises:
  • jid-malformed – if no ‘to’ attribute is specified.
  • item-not-found – if an invalid host is specified.

Like disco#items requests sent to the MUC server, room disco#info requests may also contain HipChat-specific metadata:

<!-- Client -->
<iq type="get" to="1_hipchat@conf.hipchat.com">
  <query xmlns="http://jabber.org/protocol/disco#info"/>
</iq>

<!-- Server -->
<iq from='1_hipchat@conf.hipchat.com' type='result' to='1_1@chat.hipchat.com/linux'>
  <query xmlns='http://jabber.org/protocol/disco#info'>
    <identity category='conference' type='text' name='HipChat'/>
    <feature var='http://jabber.org/protocol/muc'/>
    <feature var='muc_membersonly'/>
    <x xmlns='http://hipchat.com/protocol/muc#room'>
      <id>1</id>
      <topic>testing topic change</topic>
      <privacy>public</privacy>
      <owner>1_1@chat.hipchat.com</owner>
      <num_participants>1</num_participants>
      <guest_url/>
      <last_active>1343073497</last_active>
    </x>
  </query>
</iq>
raises:
  • jid-malformed – if no ‘to’ attribute is specified.
  • item-not-found – if an invalid host is specified.