Typhoeus Issue when receiving a request from a test server

I am using Typhoeus gem to send HTTP requests to the API. It works from my system. But, sending the same thing from the TESTING server, it does not give the desired answer. I want to know what is the problem? Please help me.

MY code:

data = {"auth_token"=>"abcd" ,"employee" => {"method" => "add_employee"}}
header =  { "Content-Type" => "application/json","Accept"=>"application/json"}
request = Typhoeus::Request.post("www.example.com",:body=> data.to_json,:headers => header)
+4
source share

Source: https://habr.com/ru/post/1536720/


All Articles