title: Configure mod_rest module for the ejabberd server
body: <p>I am in the process of configuring the ejabber server for one of our project.In this we need to configure the mod_rest module (<a href="https://github.com/processone/ejabberd-contrib" rel="nofollow">https://github.com/processone/ejabberd-contrib</a>) from ejabberd-contrib. Below are my configuration (YAML)
  in listen </p>
  
  <pre><code> port: 5280
      module: ejabberd_http
      request_handlers:
        "/rest": mod_rest
      web_admin: true
      http_poll: true
      http_bind: true
      ## register: true
      captcha: true
  
  
  modules:
    mod_rest:
      allowed_ips:
        - "host_one_ip"
        - "host_one_ip"
      access_commands:
        - "registered_users"
        - "connected_users"
      allowed_destinations:
        - "all"
  </code></pre>
  
  <p>But whenever i am trying to hit the ejabberd command using the rest (curl call)  its giving me "TryPOSTING Stanza"</p>
  
  <pre><code>    prompt# curl --data 'registered_users domain' -X POST http://host:5280/rest/
  
  Try POSTing a stanza. 
  </code></pre>
  
  <p>I tried to go though the forum but couldn't find ...anything helpful</p>
  
  <p>I am new to ejabber and erlang. Any pointer in this direction will be very helpful. Please let me know if any more details are required.</p>