Here is my config:
{mod_rest, [ {allowed_ips, [ {127,0,0,1} ]} ]},
{5280, ejabberd_http, [
{request_handlers,
[
{["rest"], mod_rest}
...
when I post
wget --server-response --post-data 'World'
--2013-02-19 08:27:25--
Connecting to 127.0.0.1:5280... connected.
HTTP request sent, awaiting response... No data received.
Retrying.
--2013-02-19 08:27:26-- (try: 2)
Connecting to 127.0.0.1:5280... connected.
HTTP request sent, awaiting response... No data received.
Retrying.
Here's the ejabberd.log
I(<0.357.0>:ejabberd_listener:281) : (#Port<0.3943>) Accepted connection
{{127,0,0,1},32993} -> {{127,0,0,1},5280}
=INFO REPORT==== 2013-02-19 08:27:28 ===
I(<0.434.0>:ejabberd_http:146) : started: {gen_tcp,#Port<0.3943>}
=INFO REPORT==== 2013-02-19 08:27:31 ===
I(<0.357.0>:ejabberd_listener:281) : (#Port<0.3944>) Accepted connection
{{127,0,0,1},32994} -> {{127,0,0,1},5280}
And when I go to the page :5280/rest, the page says:Try POSTing a stanza.
Everything looks find but I can't get response. I tried other command with no luck...
Any idea will be appreciate!!!
Maybe it's a problem with the
Maybe it's a problem with the domain name. If you have
{hosts, ["localhost"]}.Then make a request like this::
Are you using a recent ejabberd version (like 2.1.11) and recent mod_rest?
Hi, I have the same problem.
Hi, I have the same problem. But in the log, there's 1 more row:
=INFO REPORT==== 2013-03-08 07:02:53 === I(<0.404.0>:ejabberd_listener:281) : (#Port<0.3791>) Accepted connection {{127,0,0,1},42142} -> {{127,0,0,1},5280} =INFO REPORT==== 2013-03-08 07:02:53 === D(<0.411.0>:ejabberd_http:142) : S: [{["rest"],mod_rest}, {["captcha"],ejabberd_captcha}, {["admin"],ejabberd_web_admin}, {["http-bind"],mod_http_bind}, {["http-poll"],ejabberd_http_poll}] =INFO REPORT==== 2013-03-08 07:02:53 === I(<0.411.0>:ejabberd_http:146) : started: {gen_tcp,#Port<0.3791>} =INFO REPORT==== 2013-03-08 07:02:53 === D(<0.411.0>:ejabberd_http:268) : (#Port<0.3791>) http query: 'POST' /rest/ =INFO REPORT==== 2013-03-08 07:02:53 === D(<0.411.0>:ejabberd_http:447) : client data: "World" =INFO REPORT==== 2013-03-08 07:02:53 === D(<0.411.0>:ejabberd_http:346) : ["rest"] matches ["rest"]But after that, it went silent and no response back.
My config are as simple as the readme:
{mod_rest, [{allowed_ips, [{127,0,0,1}]}]} {5280, ejabberd_http [ {request_handlers, [ {["rest"], mod_rest}Can somebody help, many thanks.