0

RPC: 404 not found

netit 3 months ago in Devices / Other 0

Hello,

Is there a way to troubleshoot 404 errors on RPC or Comfortlick port 80 address ?

RPC is working perfectly well, and I have multiple devices/clients sending requests to RPC (eg : SetValue).

Meanwhile, I have one device/client (Shelly Plus Plug S) that I don't get to work and get the following error :

{ "code": 404,"message": "Not Found","headers": {"Connection": "close"}}

Some tests I did :

1/ A GET request to the toor address of Comfortclick is working (http)

2/ A POST request without the Authorization header is returning a 401 error as expected (http)

3/ In general, the device is not altering URLs (eg : uppercase/lowercase)

When I copy/past everything into https://reqbin.com/ to test the request, it works... This drives me crazy.

The problem is likely not on Comfortclick's side. But I'm unable to troubleshoot.

Any suggestions ?

Thank you !

----

let h = {
method: "POST",
url: "http://192.168.1.10/API/RPC/SetValue",
headers : {
'Content-Type': "application/json; charset=utf-8",
'Authorization': "Basic UlBDeWQ6ZGhZNjdhxxx4MlNpdWFo"
},
body : '{"objectName":"Devices\\KNX\\Light 1","valueName":"Value","value":"false"}',
timeout: 4
};

Shelly.call("HTTP.REQUEST", h, function (result,error_code,error_message) {

print(result);
});