I am trying to fulfill this rest api:
public async Task AddTimetracking(Issue issue, int spentTime)
{
// POST /rest/issue/{issue}/timetracking/wo
You might want to set the mediaType in StringContent like below:
var httpContent = new StringContent(workItem.XDocument.ToString(), Encoding.UTF8, "application/xml");
You could use
var respone = await httpClient.PostAsXmlAsync(requestUri, workItem);
https://msdn.microsoft.com/en-us/library/system.net.http.httpclientextensions_methods