title: Can't send a group message - Error 400 - Modify - BadRequest
body: <p>The user is online, inside the room, can listen but it cannot send any message.
  Why?</p>
  
  <p>I am using JAXL in PHP!</p>
  
  <p>XML Message:</p>
  
  <pre><code>&lt;presence xmlns="jabber:client" id="3"&gt;
      &lt;status&gt;available!&lt;/status&gt;
      &lt;show&gt;dnd&lt;/show&gt;
      &lt;priority&gt;10&lt;/priority&gt;
  &lt;/presence&gt;
  &lt;presence
      xmlns="jabber:client" 
      from="bot@peoplebus/jaxl#notificator" 
      to="rota_1@conference.peoplebus/bot" 
      id="4"&gt;
      &lt;x xmlns="http://jabber.org/protocol/muc"&gt;
          &lt;history maxstanzas="0" seconds="0"&gt;&lt;/history&gt;
      &lt;/x&gt;
  &lt;/presence&gt;
  &lt;message 
      xmlns="jabber:client" 
      type="groupchat" 
      to="rota_1@conference.peoplebus/bot" 
      from="bot@peoplebus/jaxl#notificator"&gt;
      &lt;body&gt;teste&lt;/body&gt;
  &lt;/message&gt;
  </code></pre>
  
  <p>Error:</p>
  
  <pre><code>jaxl_socket_client:189 - 2014-03-07 23:09:59 - or"/&gt;&lt;/x&gt;&lt;/presence&gt;
  &lt;presence from="rota_1@conference.peoplebus/bot" to="bot@peoplebus/jaxl#notificator" id="4"&gt;
    &lt;x xmlns="http://jabber.org/protocol/muc#user"&gt;
      &lt;item jid="bot@peoplebus/jaxl#notificator" affiliation="none" role="participant"/&gt;
    &lt;/x&gt;
  &lt;/presence&gt;
  &lt;message type="groupchat" from="rota_1@conference.peoplebus" to="bot@peoplebus/jaxl#notificator"&gt;
    &lt;body&gt;Esta sala permite anônimos.&lt;/body&gt;
    &lt;x xmlns="http://jabber.org/protocol/muc#user"&gt;&lt;status code="100"/&gt;&lt;/x&gt;
  &lt;/message&gt;
  &lt;message type="error" to="bot@peoplebus/jaxl#notificator" from="rota_1@conference.peoplebus/bot"&gt;
    &lt;body&gt;teste&lt;/body&gt;
    &lt;error code="400" type="modify"&gt;
      &lt;bad-request xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"/&gt;
    &lt;/error&gt;
  &lt;/message&gt;
  </code></pre>
  
  <p>Here is a part of debug (just with what I think that is important):</p>
  
  <pre><code>jaxl_socket_client:95 - 2014-03-07 23:09:59 - trying tcp://10.208.4.180:5222
  jaxl_socket_client:104 - 2014-03-07 23:09:59 - connected to tcp://10.208.4.180:5222
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 182/182 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;?xml version='1.0' encoding='UTF-8'?&gt;&lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" from="peoplebus" id="4453b273" xml:lang="en" version="1.0"&gt;
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 51/719 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;success xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/&gt;
  jaxl_socket_client:201 - 2014-03-07 23:09:59 - sent 178/440 of data
  jaxl_socket_client:202 - 2014-03-07 23:09:59 - &lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" version="1.0" to="peoplebus#" xmlns="jabber:client" xml:lang="en" xmlns:xml="http://www.w3.org/XML/1998/namespace"&gt;
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 411/1130 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;?xml version='1.0' encoding='UTF-8'?&gt;&lt;stream:stream xmlns:stream="http://etherx.jabber.org/streams" xmlns="jabber:client" from="peoplebus" id="4453b273" xml:lang="en" version="1.0"&gt;&lt;stream:features&gt;&lt;compression xmlns="http://jabber.org/features/compress"&gt;&lt;method&gt;zlib&lt;/method&gt;&lt;/compression&gt;&lt;bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"/&gt;&lt;session xmlns="urn:ietf:params:xml:ns:xmpp-session"/&gt;&lt;/stream:features&gt;
  jaxl_socket_client:201 - 2014-03-07 23:09:59 - sent 140/580 of data
  jaxl_socket_client:202 - 2014-03-07 23:09:59 - &lt;iq xmlns="jabber:client" type="set" id="1"&gt;&lt;bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"&gt;&lt;resource&gt;jaxl#notificator&lt;/resource&gt;&lt;/bind&gt;&lt;/iq&gt;
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 149/1279 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;iq type="result" id="1" to="peoplebus/4453b273"&gt;&lt;bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"&gt;&lt;jid&gt;bot@peoplebus/jaxl#notificator&lt;/jid&gt;&lt;/bind&gt;&lt;/iq&gt;
  jaxl_socket_client:201 - 2014-03-07 23:09:59 - sent 112/692 of data
  jaxl_socket_client:202 - 2014-03-07 23:09:59 - &lt;iq xmlns="jabber:client" type="set" id="2"&gt;&lt;session xmlns="urn:ietf:params:xml:ns:xmpp-session"&gt;&lt;/session&gt;&lt;/iq&gt;
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 62/1341 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;iq type="result" id="2" to="bot@peoplebus/jaxl#notificator"/&gt;
  notificator:43 - 2014-03-07 23:09:59 - got on_auth_success cb, jid bot@peoplebus/jaxl#notificator
  jaxl_exception:66 - 2014-03-07 23:09:59 - error handler called with 8, Undefined index: id, /var/www/jaxl/xmpp/xmpp_stanza.php, 81
  jaxl_socket_client:201 - 2014-03-07 23:09:59 - sent 484/1176 of data
  jaxl_socket_client:202 - 2014-03-07 23:09:59 - &lt;presence xmlns="jabber:client" id="3"&gt;&lt;status&gt;available!&lt;/status&gt;&lt;show&gt;dnd&lt;/show&gt;&lt;priority&gt;10&lt;/priority&gt;&lt;/presence&gt;&lt;presence xmlns="jabber:client" from="bot@peoplebus/jaxl#notificator" to="rota_1@conference.peoplebus/bot" id="4"&gt;&lt;x xmlns="http://jabber.org/protocol/muc"&gt;&lt;history maxstanzas="0" seconds="0"&gt;&lt;/history&gt;&lt;/x&gt;&lt;/presence&gt;&lt;message xmlns="jabber:client" type="groupchat" to="rota_1@conference.peoplebus/bot" from="bot@peoplebus/jaxl#notificator"&gt;&lt;body&gt;teste&lt;/body&gt;&lt;/message&gt;
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 168/1509 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;presence id="3" from="bot@peoplebus/jaxl#notificator" to="bot@peoplebus/jaxl#notificator"&gt;&lt;status&gt;available!&lt;/status&gt;&lt;show&gt;dnd&lt;/show&gt;&lt;priority&gt;10&lt;/priority&gt;&lt;/presence&gt;
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 1024/2533 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - &lt;presence from="pidgin@peoplebus/fbaff75c" to="bot@peoplebus/jaxl#notificator"&gt;&lt;priority&gt;1&lt;/priority&gt;&lt;c xmlns="http://jabber.org/protocol/caps" node="http://pidgin.im/" hash="sha-1" ver="I22W7CegORwdbnu0ZiQwGpxr0Go="/&gt;&lt;x xmlns="vcard-temp:x:update"&gt;&lt;photo/&gt;&lt;/x&gt;&lt;/presence&gt;&lt;message to="bot@peoplebus/jaxl#notificator" from="pidgin@peoplebus" id="pidgin@peoplebus__bot@peoplebus__52D8K"&gt;&lt;event xmlns="http://jabber.org/protocol/pubsub#event"&gt;&lt;items node="http://jabber.org/protocol/tune"&gt;&lt;item id="4ebd50d9-2c64-4c70-9fe5-45b8cffa5fda3"&gt;&lt;tune xmlns="http://jabber.org/protocol/tune"/&gt;&lt;/item&gt;&lt;/items&gt;&lt;/event&gt;&lt;delay xmlns="urn:xmpp:delay" stamp="2014-03-07T22:40:10.155Z"/&gt;&lt;/message&gt;&lt;presence to="bot@peoplebus/jaxl#notificator" from="rota_1@conference.peoplebus/pidgin"&gt;&lt;priority&gt;1&lt;/priority&gt;&lt;c xmlns="http://jabber.org/protocol/caps" node="http://pidgin.im/" hash="sha-1" ver="I22W7CegORwdbnu0ZiQwGpxr0Go="/&gt;&lt;x xmlns="http://jabber.org/protocol/muc#user"&gt; ...
  jaxl_fsm:61 - 2014-03-07 23:09:59 - calling state handler 'logged_in' for incoming event 'stanza_cb'
  jaxl_fsm:71 - 2014-03-07 23:09:59 - current state 'logged_in'
  jaxl_socket_client:188 - 2014-03-07 23:09:59 - read 698/3231 of data
  jaxl_socket_client:189 - 2014-03-07 23:09:59 - or"/&gt;&lt;/x&gt;&lt;/presence&gt;&lt;presence from="rota_1@conference.peoplebus/bot" to="bot@peoplebus/jaxl#notificator" id="4"&gt;&lt;x xmlns="http://jabber.org/protocol/muc#user"&gt;&lt;item jid="bot@peoplebus/jaxl#notificator" affiliation="none" role="participant"/&gt;&lt;/x&gt;&lt;/presence&gt;&lt;message type="groupchat" from="rota_1@conference.peoplebus" to="bot@peoplebus/jaxl#notificator"&gt;&lt;body&gt;Esta sala permite anônimos.&lt;/body&gt;&lt;x xmlns="http://jabber.org/protocol/muc#user"&gt;&lt;status code="100"/&gt;&lt;/x&gt;&lt;/message&gt;&lt;message type="error" to="bot@peoplebus/jaxl#notificator" from="rota_1@conference.peoplebus/bot"&gt;&lt;body&gt;teste&lt;/body&gt;&lt;error code="400" type="modify"&gt;&lt;bad-request xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"/&gt;&lt;/error&gt;&lt;/message&gt;
  jaxl_fsm:61 - 2014-03-07 23:09:59 - calling state handler 'logged_in' for incoming event 'stanza_cb'
  jaxl_exception:66 - 2014-03-07 23:09:59 - error handler called with 8, Undefined index: type, /var/www/jaxl/xmpp/xmpp_stanza.php, 81
  </code></pre>