SCAPI Response Compression

Compressed responses reduce the amount of data transferred between B2C Commerce and your API client. The larger the response, the bigger the benefit.

SCAPI compresses a response only if the request includes the Accept-Encoding header.

Include both Brotli and Gzip in the Accept-Encoding header of every SCAPI request:

The B2C Commerce web tier compresses larger responses with Gzip, and the CDN compresses smaller responses with Brotli. SCAPI doesn’t compress the smallest responses or error responses.

To turn off compression, omit the Accept-Encoding header.

Accept-Encoding Request HeaderContent-Encoding of the Response
br, gzip (recommended)gzip (web tier) for larger responses, br (CDN) for smaller responses
gzipgzip
Not sentUncompressed