Unable to cast object of type 'System.Threading.Tasks.Task`1
public async Task<int> UpdateMediaAppCart(int cartId, int qty, decimal amount, DateTime updatedAt)
{
var client = new HttpClient();
var cartValue = new CartValues
{
CartId = cartId,
Quantity = qty,
Amount = amount,
UpdatedAt = updatedAt
};
var httpContent = new StringContent(JsonConvert.SerializeObject(cartValue), Encoding.UTF8, "application/json");
var result = await client.PutAsync(ConfigurationManager.AppSettings.Get("WebServiceUrl") + "/cart/update", httpContent);
return Convert.ToInt32(result.Content.ReadAsStringAsync());
}