The API supports response compression using either gzip or brotli.
To use this, set the Accept-Encoding header. For example: Accept-Encoding: gzip, br
.
The response will be compressed if the request header is set, the response is larger than 500B and the Content-Type is application/json.
The response will include the Content-Encoding
header to show that it is compressed and which algorithm was used.
Some tools or libraries may automatically set the Accept-Encoding header for you. But we recommend you check that it is set correctly and always use compression if you can, as it will improve performance and reduce bandwidth usage.