JSPM

http-capture

1.0.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q25529F
  • License MIT

Express/Connect middleware for capturing HTTP request and responses

Package Exports

  • http-capture

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (http-capture) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

http-capture

NPM Version NPM Downloads

Node.js express middleware for capturing HTTP request and responses

Install

$ npm install http-capture

API

var httpCapture = require ('http-capture')

httpCapture ()

Returns the HTTP capture middleware function, which by default writes to the current working directory under .capture and formats the files as such: #_YYYY_MM_DD_hh_mm_ss_METHOD

Examples

Express / Connect

When using this module with express or connect, simply app.use the module. Requests and responses that pass through the middleware will be captured to in the current working directory under .capture

var httpCapture = require ('http-capture'),
    express = require ('express')

var app = express()

app.use (httpCapture())

License

MIT