I\'m trying to set the Content-Type header of an HttpClient object as required by an API I am calling.
Content-Type
HttpClient
I tried setting the Content-Ty
Content-Ty
try to use TryAddWithoutValidation
var client = new HttpClient(); client.DefaultRequestHeaders.TryAddWithoutValidation("Content-Type", "application/json; charset=utf-8");