Ben,

> On 10 Sep 2018, at 20:36, Ben Coman <b...@openinworld.com> wrote:
> 
> Hi Sven,
> 
> I had a sample http request specified to have ```Accept-Encoding: gzip```
> and too a guess the following would work... ```client := ZnClient new accept: 
> 'gzip' ```
> but it doesn't since ZnClient>>accept:  
> effectively does ``` 'gzip' asZnMimeType  ```
> which expects the string to contain a forward-slash
> 
> However this page seems to indicate no slash is required...
> https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Accept-Encoding
> 
> If I call ```client request setAccept: 'gzip'  ``` 
> I am able to match what is expected (checked with WireShark)
> but I'm not sure the sample I was provided is legit or I'm doing something 
> wrong
> 
> cheers -ben

You seem to be confusing two different headers, Accept and Accept-Encoding 
(there are many more: 
https://en.wikipedia.org/wiki/List_of_HTTP_header_fields#Request_fields).

#accept: does indeed take a mime-type as argument, as it should.

I think you are looking for #setAcceptEncodingGzip

Sven

Reply via email to