• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

problem with protocolhttp - otc mehah the lastest source

sinrage

New Member
Joined
Jun 23, 2018
Messages
2
Reaction score
0
Hello, I have a problem with the http protocol, the HTTP functions (HTTP.post, HTTP.get, HTTP.postJSON, HTTP.getJSON) are not working properly. I'm using the lastest source of mehah otc. I have tried sending this request to different websites, it always gets this error.

{
"files": {
"test.txt": "00000000",
"CMakeLists.txt": "f4c9b288"
}
}HTTP/1.1 400 Bad Request
Date: Fri, 07 Oct 2022 18:16:28 GMT
Server: Apache
Content-Length: 226
Connection: close
Content-Type: text/html; charset=iso-8859-1

<title>400 Bad Request</title>

i think i am using this function correctly:
Lua:
HTTP.postJSON(url, {build = g_app.getVersion(), os = g_app.getOs(), platform = g_window.getPlatformType()}, function(data, err)
    if err then    
      return Updater.error(err)
    end
    print(data)
  end)

From apache.log:
[08/Oct/2022:11:02:42 +0200] "POST /updater/files.php HTTP/1.1" 200 0 "-" "Mozilla/5.0"
 
Last edited:
Back
Top