Not logged in. · Lost password · Register
Forum: agsXMPP RSS
ruin1998 #1
Member since Oct 2013 · 4 posts
Group memberships: Members
Show profile · Link to this post
Subject: I can't create&join muc room
Hello, Alex..

Thanks for advance.

how to create muc room then join it.
what mean "This room is locked from entry until configuration is confirmed."
what can I do?

Please helpme :(

  1. MucManager mm = new MucManager(XmppConn);             
  2. mm.JoinRoom(RoomJid, XmppConn.Username);

Debug xml
  1. Send: <presence to=""><x xmlns="" /></presence>
  2. Send: <iq id="agsXMPP_3" type="get"><query xmlns="jabber:iq:roster" /></iq>
  3. Recv: <presence xmlns="jabber:client" from="" to=""><x xmlns=""><item role="moderator" jid="" affiliation="owner" /><status code="201" /></x></presence>
  4. Recv: <message xmlns="jabber:client" to="" type="groupchat" from=""><body>This room is locked from entry until configuration is confirmed.</body></message>
  5. Recv: <iq xmlns="jabber:client" to="" id="agsXMPP_3" type="result"><query xmlns="jabber:iq:roster"><item jid="" subscription="both" /></query></iq>
  6. Send: <presence><status>aviable</status><priority>5</priority></presence>
  7. Recv: <presence xmlns="jabber:client" from="" to=""><status>aviable</status><priority>5</priority></presence>
This post was edited on 2013-10-21, 09:39 by Alex.
Alex #2
Member since Feb 2003 · 4296 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
The room gets created fine.
The rooms returns a status code of 201 which means its awaiting configuration. So you must configure it in the next step by requesting the room configuration, and submitting it.

  • You can also configure your server to not require the configuration
  • Or you can create an instant room and request the default configuration

see also:
ruin1998 #3
Member since Oct 2013 · 4 posts
Group memberships: Members
Show profile · Link to this post
thanks for your kind feedback.

I request and submit as below, but other user can't join this room. Persistent option didn't change.
what can i do?

  1. Recv: <iq xmlns="jabber:client" to="" id="agsXMPP_3" type="result" from=""><query xmlns=""><x xmlns="jabber:x:data" type="form"><title>Room configuration</title><instructions>The room "p.testgroupchat1" has been created. To accept the default configuration, click the "OK" button. Or, modify the settings by completing the following form:</instructions><field var="FORM_TYPE" type="hidden"><value></value></field><field label="Room Name" type="text-single" var="muc#roomconfig_roomname"><value>p.testgroupchat1</value></field><field label="Description" type="text-single" var="muc#roomconfig_roomdesc"><value>p.testgroupchat1</value></field><field label="Allow Occupants to Change Subject" type="boolean" var="muc#roomconfig_changesubject"><value>0</value></field><field label="Maximum Room Occupants" type="list-single" var="muc#roomconfig_maxusers"><option label="10"><value>10</value></option><option label="20"><value>20</value></option><option label="30"><value>30</value></option><option label="40"><value>40</value></option><option label="50"><value>50</value></option><option label="None"><value>0</value></option><value>0</value></field><field label="Roles for Which Presence is Broadcast" type="list-multi" var="muc#roomconfig_presencebroadcast"><option label="Moderator"><value>moderator</value></option><option label="Participant"><value>participant</value></option><option label="Visitor"><value>visitor</value></option><value>moderator</value><value>participant</value><value>visitor</value></field><field label="List Room in Directory" type="boolean" var="muc#roomconfig_publicroom"><value>1</value></field><field label="Room is Persistent" type="boolean" var="muc#roomconfig_persistentroom"><value>0</value></field><field label="Room is Moderated" type="boolean" var="muc#roomconfig_moderatedroom"><value>0</value></field><field label="Room is Members-only" type="boolean" var="muc#roomconfig_membersonly"><value>0</value></field><field type="fixed"><value>Note: by default, only admins can send invitations in an members-only room.</value></field><field label="Allow Occupants to Invite Others" type="boolean" var="muc#roomconfig_allowinvites"><value>0</value></field><field label="Password Required to Enter Room" type="boolean" var="muc#roomconfig_passwordprotectedroom"><value>0</value></field><field type="fixed"><value>If a password is required to enter this room, you must specify the password below.</value></field><field label="Password" type="text-private" var="muc#roomconfig_roomsecret" /><field label="Role that May Discover Real JIDs of Occupants" type="list-single" var="muc#roomconfig_whois"><option label="Moderator"><value>moderators</value></option><option label="Anyone"><value>anyone</value></option><value>anyone</value></field><field label="Log Room Conversations" type="boolean" var="muc#roomconfig_enablelogging"><value>0</value></field><field label="Only login with registered nickname" type="boolean" var="x-muc#roomconfig_reservednick"><value>0</value></field><field label="Allow Occupants to change nicknames" type="boolean" var="x-muc#roomconfig_canchangenick"><value>1</value></field><field type="fixed"><value>Allow Users to register with the room</value></field><field label="Allow Users to register with the room" type="boolean" var="x-muc#roomconfig_registration"><value>1</value></field><field type="fixed"><value>You may specify administrators of this room. Please provide one JID per line.</value></field><field label="Room Admins" type="jid-multi" var="muc#roomconfig_roomadmins" /><field type="fixed"><value>You may specify additional owners for this room. Please provide one JID per line.</value></field><field label="Room Owners" type="jid-multi" var="muc#roomconfig_roomowners"><value></value></field></x></query></iq>
  2. Send: <iq id="agsXMPP_5" type="set" to=""><query xmlns=""><x xmlns="jabber:x:data" type="form"><field type="boolean" var="muc#roomconfig_persistentroom">1</field><field type="boolean" var="muc#roomconfig_moderatedroom">1</field></x></query></iq>
  3. Recv: <iq xmlns="jabber:client" to="" id="agsXMPP_5" type="result" from="" />
This post was edited 2 times, last on 2013-10-21, 11:25 by Alex.
Alex #4
Member since Feb 2003 · 4296 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
The submission of your room configuration is totally wrong. This is the reason why it does not work. Your server should reply with error instead of result here ;-).

For room configuration submission please see Example 159 in the XEP I posted above.
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: agsXMPP RSS