diff --git a/apps/njau_bot/src/http_handler/api_handler.erl b/apps/njau_bot/src/http_handler/api_handler.erl index ca8f95a..37efc47 100644 --- a/apps/njau_bot/src/http_handler/api_handler.erl +++ b/apps/njau_bot/src/http_handler/api_handler.erl @@ -30,6 +30,7 @@ init(Req0, Opts) -> }, Resp, Req1), {ok, Req2, Opts}; false -> + lager:debug("[api_handler] invalid sign: ~p", [Sign]), Req2 = cowboy_req:reply(500, #{ <<"Content-Type">> => <<"text/html;charset=utf-8">> }, <<"Internal Server Error">>, Req1), @@ -39,7 +40,7 @@ init(Req0, Opts) -> handle_request("POST", "/api/device_info", _, Params) -> njau_bot_logger:write(jiffy:encode(Params, [force_utf8])), - {ok, 200, json_data(<<"hello world">>)}; + {ok, 200, json_data(<<"ok">>)}; handle_request(_, Path, _, _) -> Path1 = list_to_binary(Path),