READ and Create tickets using API for KACE SME 12.1 in asp.net Core
I am trying to read and create tickets in KACE SME using API call. I am using asp.net MVC to make the calls.
I am able to login using API and get JWT authorization token. But when I try to use the token to make sub sequent API calls I am getting 401 "Unauthorized" error.
I contacted KACE support and they mentioned version 12 and later need to JWT token instead of CSRF token.
Here is below code that I am using to make my API call.
HttpClient client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, Endpoint);
var response = await client.SendAsync(request);
Not sure what I should be sending in the Header to make a successful API Call.
The version of KACE sme :12.1.168
Thanks in Advance!