public string Login(LoginAPIModel model)
        {
            var response = webRequestHelper.Post("/api/account/login", JsonConvert.SerializeObject(model), "application/json; charset=UTF-8", "");

            if (response.HasError)
            {
                return("");
            }

            return(response.ContainsHeader("Authorization") ? response["Authorization"] : "");
        }
Beispiel #2
0
 public IHttpRequest Post(string uri, string postData)
 {
     return(_webRequestHelper?.Post(uri, postData).SetEventCallback(OnEventCallback));
 }
Beispiel #3
0
 public void AddItem(ItemAPIModel model)
 {
     var response = webRequestHelper.Post("/api/operations/items", JsonConvert.SerializeObject(model), "application/json; charset=UTF-8", authToken);
 }