Xojo.Net.HTTPSocket and compressed data

I have a class based on the Xojo.Net.HTTPSocket. My web services team has pointed out that my iOS app isn’t requesting compressed data in the header of each request and they say that compressed data is now very common, is supported by all modern browsers and makes a big difference on mobile devices.

In my desktop app I use the MBS CURLS library to access web services and it is able to automatically deflate/gzip compressed data. Apparently NSURLSession natively supports compression/decompression of data too.

Does anybody know whether the Xojo.Net.HTTPSocket does this?

Have you tried to add the Accept-Encoding:gzip in the header request?

Thanks Antonio. Yes I’ve added that to the header and my app just seems to work. So that worried me. :wink:

With the MBS CURL plugin I need to add:

CURL.OptionAcceptEncoding = "gzip"

in order for the returned JSON to be uncompressed and parse-able.

So I am really just looking for some verification that the Xojo.Net.HTTPSocket will just do this without setting any extra properties. :slight_smile: