xdmp:set-response-compression( $value as xs:boolean, [$options as xs:string] ) as empty-sequence()
Enabble/disables HTTP GZIP Response compression
http://marklogic.com/xdmp/privileges/xdmp-add-response-header
xdmp:set-response-compression(fn:true(),"compression-level=6")
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.