{"name":"decompress-response","version":"10.0.0","description":"Decompress a HTTP response if needed","license":"MIT","repository":{"type":"git","url":"git+https://github.com/sindresorhus/decompress-response.git"},"funding":"https://github.com/sponsors/sindresorhus","author":{"name":"Sindre Sorhus","email":"sindresorhus@gmail.com","url":"https://sindresorhus.com"},"type":"module","exports":{"types":"./index.d.ts","default":"./index.js"},"sideEffects":false,"engines":{"node":">=20"},"scripts":{"test":"xo && ava && tsd"},"keywords":["decompress","response","http","https","zlib","gzip","zip","deflate","unzip","ungzip","incoming","message","stream","compressed","brotli","zstd","zstandard"],"dependencies":{"mimic-response":"^4.0.0"},"devDependencies":{"@types/node":"^24.7.2","ava":"^6.4.1","get-stream":"^8.0.1","pify":"^6.1.0","tsd":"^0.33.0","xo":"^1.2.3"},"gitHead":"6e405435f5f1932875b2855048f7eff23d861314","types":"./index.d.ts","_id":"decompress-response@10.0.0","bugs":{"url":"https://github.com/sindresorhus/decompress-response/issues"},"homepage":"https://github.com/sindresorhus/decompress-response#readme","_nodeVersion":"24.9.0","_npmVersion":"11.6.1","dist":{"integrity":"sha512-oj7KWToJuuxlPr7VV0vabvxEIiqNMo+q0NueIiL3XhtwC6FVOX7Hr1c0C4eD0bmf7Zr+S/dSf2xvkH3Ad6sU3Q==","shasum":"d8abd2a4c136c3b99b49a08d1f9a709fe35675a4","tarball":"http://registry-npm.ywwl.com/decompress-response/download/decompress-response-10.0.0.tgz","fileCount":5,"unpackedSize":5965,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQD3JdAZVr+wy66juPQC8KAVJj3EyRH/iDT5iHhUzGI1gQIgeT4i8rbgoD6Y8kqEIE87PjH1IQYsnvEsQ5rcThoA2cQ="}],"size":2544,"noattachment":false,"key":"/decompress-response/-/decompress-response-10.0.0.tgz"},"_npmUser":{"name":"sindresorhus","email":"sindresorhus@gmail.com"},"directories":{},"maintainers":[{"name":"sindresorhus","email":"sindresorhus@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/decompress-response_10.0.0_1760378644634_0.3352585651171254"},"_hasShrinkwrap":false,"readme":"# decompress-response\n\n> Decompress a HTTP response if needed\n\nDecompresses the [response](https://nodejs.org/api/http.html#http_class_http_incomingmessage) from [`http.request`](https://nodejs.org/api/http.html#http_http_request_options_callback) if it's gzipped, deflated or compressed with Brotli, otherwise just passes it through.\n\nUsed by [`got`](https://github.com/sindresorhus/got).\n\n## Install\n\n```sh\nnpm install decompress-response\n```\n\n## Usage\n\n```js\nimport http from 'node:http';\nimport decompressResponse from 'decompress-response';\n\nhttp.get('https://sindresorhus.com', response => {\n\tresponse = decompressResponse(response);\n});\n```\n\n## API\n\n### decompressResponse(response)\n\nReturns the decompressed HTTP response stream.\n\n#### response\n\nType: [`http.IncomingMessage`](https://nodejs.org/api/http.html#http_class_http_incomingmessage)\n\nThe HTTP incoming stream with compressed data.\n","publish_time":1760378644805,"_cnpm_publish_time":1760378644805,"dist-tags":{"latest":"10.0.0"}}