1. So, got error when sending Content-Type: application/json post request
    Code:
    webrequest.EnqueuePost(url, data,
                    (code2, response2) =>
                    {
                        PrintWarning(String.Format("{0}: {1}", code2, response2));                
                    }, this, headers);
    
    the error is
    [​IMG]

    by the API specification the server returns empty result with 204 http code, checked the same request in browser, all working, in the c# plugin - don't
    upload_2018-1-14_12-32-44.png
     
    Last edited by a moderator: Jan 14, 2018
  2. Wulf

    Wulf Community Admin

    Are you using HTTPS? Mono (what Unity uses and our webrequests) do not work with a lot of modern SSL certs.
     
  3. no, thats http url
     
  4. Wulf

    Wulf Community Admin

    Looks to be going through CloudFlare, so likely something stopping it there.
     
  5. strange, because only two api methods are not working, other are, about 10-15 tried
     
  6. Wulf

    Wulf Community Admin

    What other API methods? There's only one API for web requests. The error isn't coming from Oxide though, that's the server's response, which to me looks like the Mono web request library couldn't handle the request.
     
  7. I'm writing discord api plugin, so I meant it's API, delete and bulk-delete methods can't be called
     
    Last edited by a moderator: Jan 14, 2018
  8. well, don't know what i've done or what was wrong with code/api, but it seems all working now, omg
    sorry