Flurl.Http sends in every Request the following Header:
Accept-Encoding: gzip, deflate
This behaviour is since Update to Version 4.
I would contact API, which returns Error 406 when i send a request with this Header. How can i remove the Header in Flurl.Http to resolve this issue?
Here is my example request:
var request = $"https://{IP}"
.AllowAnyHttpStatus()
.AppendPathSegment(Endpoint)
.WithHeader("Authorization", authHeader)
.WithHeader("Content-Type", "application/json");
request.GetJsonAsync<JsonDocument>().Result;
before Update from Version 3 to Version 4, there was no Header “Accept-Encoding” sent.
New contributor
mavo1848 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.