{"library":"tamper","type":"library","category":null,"description":"tamper is a Node.js middleware designed for intercepting and modifying HTTP response bodies before they are sent to the client. It provides a simple API for Connect/Express-compatible applications, allowing developers to inspect request and response headers and conditionally apply transformations to the response body. The current stable version, 1.1.0, indicates a mature but largely feature-complete codebase with infrequent updates. Its primary differentiation lies in its focused scope of response body manipulation, offering a callback-based or Promise-based mechanism for transformations. It's particularly useful for tasks like injecting scripts, performing server-side content rewrites, or debugging response payloads without directly altering original handlers. It ships with TypeScript types, enhancing developer experience for type-safe applications.","language":"javascript","status":"maintenance","version":"1.1.0","tags":["javascript","connect","middleware","capture","modify","response","typescript"],"last_verified":"Wed May 27","install":[{"cmd":"npm install tamper","imports":["const tamper = require('tamper');","import { Request, Response, NextFunction } from 'express';\nconst tamper = require('tamper');\n\n// To type the result of tamper()\ntype TamperHandler = (req: Request, res: Response, next: NextFunction) => void;"]},{"cmd":"yarn add tamper","imports":[]},{"cmd":"pnpm add tamper","imports":[]}],"homepage":null,"github":"https://github.com/fgnass/tamper","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/tamper","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/tamper/compatibility"}}