You need to observe the POST request via fiddler and see how it's structured.
for instance :
{"userName":"you","password":"pwd"}
Usually, a site would recognize that you are logged in by receiving their cookie in your requests.
HttpClient by default sends the cookies received from a specific domain with each sequential request to that domain (Until you dispose that HttpClient instance)
1) Create a cookie container and assigned it to your HttpClient instance.
2) Use HttpClient to make the login POST request.
3) Use HttpClient to make the data GET request.
4) Read the html string from the response.
5) Use HtmlAgilityPack HtmlDocument to load the document from the html string and not from the web (as most examples show).
string baseUrl = "https://www.yourwebsite.com";
string loginUrl = "/Account/LogOn";
string sessionUrl = "/Data";
var uri = new Uri(baseUrl);
CookieContainer cookies = new CookieContainer();
HttpClientHandler handler = new HttpClientHandler();
handler.CookieContainer = cookies;
using (var client = new HttpClient(handler))
{
client.BaseAddress = uri;
var request = new { userName = "you", password = "pwd" };
var resLogin = client.PostAsJsonAsync(loginUrl,request).Result;
if (resLogin.StatusCode != HttpStatusCode.OK)
Console.WriteLine("Could not login -> StatusCode = " + resLogin.StatusCode);
// see what cookies are returned
IEnumerable<Cookie> responseCookies = cookies.GetCookies(uri).Cast<Cookie>();
foreach (Cookie cookie in responseCookies)
Console.WriteLine(cookie.Name + ": " + cookie.Value);
var resData = client.GetAsync(dataUrl).Result;
if(resSession.StatusCode != HttpStatusCode.OK)
Console.WriteLine("Could not get data html -> StatusCode = " + resSession.StatusCode);
var html = resSession.Content.ReadAsStringAsync().Result;
var doc = new HtmlDocument();
doc.LoadHtml(html);
}