This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

req-info

1.0.7 • Public • Published

req-info

Grab request info from express req

Install

npm install req-info

Usage

const reqInfo = require('req-info');

console.log(reqInfo.userId)               //  Out: Auth0 user_id: auth0|5b558b1155f1632b0bxxxxxx
console.log(reqInfo.user  )               //  Out: Auth0 user: object
console.log(reqInfo.url)                  //  Out: GET http://localhost:3000/api/users
console.log(reqInfo.body)                 //  Out: body object
console.log(reqInfo.headers.authorization)//  Out: Authorization: Bearer xxxxx
console.log(reqInfo.params)               //  Out: params object
console.log(reqInfo.query)                //  Out: query object

Readme

Keywords

Package Sidebar

Install

npm i req-info

Weekly Downloads

1

Version

1.0.7

License

MIT

Unpacked Size

3.22 kB

Total Files

4

Last publish

Collaborators

  • benjrei