Output Compression

API methods are able to compress output traffic via gzip or deflate compression. Given that both JSON and XML are text based formats with highly repetitive content, compression can effectively save 60% to 80% of response size. Many HTTP clients use simple flags to enable compression (if not enabled by default) and make decompression process completely transparent.

For example .NET’s HttpClientHandler and HttpWebRequest, Java’s HttpClientBuilder, JavaScript’s XMLHttpRequest and one of the most widely spread HTTP client libraries, libcurl supports such an option. For other HTTP clients, please consult your client’s documentation.