use gzip compression for API requests

This will allow POST /hosts/statuses responses to be compressed, which
should speed up things on slow connections (e.g. VPN). This would be
welcome as the statuses for all hosts in our current test environment
exceeds 1MB uncompressed text.