Get members nickname of MUC Room

被刻印的时光 ゝ 提交于 2019-12-04 11:01:06

On 6.5 Querying for Room Items from XEP 0045 when you send

<iq from='$user-name@$user-server/$user-resorce'
    id='someid'
    to='$chat-room-to-query@$chatserver'
    type='get'>
  <query xmlns='http://jabber.org/protocol/disco#items'/>
</iq> 

You have the following description

An implementation MAY return a list of existing occupants if that information is publicly available, or return no list at all if this information is kept private.(emphasis mine)

if the room is public them you get

<iq from='$chat-room-to-query@$chatserver'
    id='someid'
    to='$user-name@$user-server/$user-resorce'
    type='result'>
  <query xmlns='http://jabber.org/protocol/disco#items'>
    <item jid='$chat-room-to-query@$chatserver/$firstnick'/>
    <item jid='$chat-room-to-query@$chatserver/$secondnick'/>
    <...>
  </query>
</iq>

From my knowledge ejabberd implements this correctly.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!