コード例 #1
0
 public async Task AddUserAsync(RegisterAccountViewModel model)
 {
     var url         = "/Account/register";
     var json        = JsonConvert.SerializeObject(model);
     var httpContent = new StringContent(json, Encoding.UTF8, "application/json");
     var result      = await _httpService.ExecuteQuery(url, HttpOperationMode.POST, httpContent);
 }
コード例 #2
0
        public async Task <GetDetailsPostBlogView> ShowDetailedPost()
        {
            var url    = $"/Blog/getPost";
            var result = await _httpService.ExecuteQuery(url, HttpOperationMode.GET);

            var parsedResult = await _httpService.ProcessJson <GetDetailsPostBlogView>(result);

            return(parsedResult);
        }