我正在尝试使用 REST 登录或 SugarCrm。我有这个代码,,
//Login
var data = new JObject();
data["user_name"] = "admin";
data["password"] = @"xxx";
var client = new RestClient(@"http://ubuntu-server");
var request = new RestRequest(@"service/v2/rest.php", Method.POST);
request.AddParameter("method", "login");
request.AddParameter("input_type", "json");
request.AddParameter("response_type", "json");
request.AddParameter("rest_data", data);
var response = client.Execute(request);
var content = response.Content;
我得到的响应是“无效登录”
我在做什么错??
//lasse