Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@newstudios/express-middleware-requestid

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@newstudios/express-middleware-requestid - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

2

package.json
{
"name": "@newstudios/express-middleware-requestid",
"version": "0.0.1",
"version": "0.0.2",
"description": "A middleware that generates a unique Request ID for every incoming HTTP request in express.",

@@ -5,0 +5,0 @@ "main": "index.js",

<div align="center">
<h1>koa2-middleware-requestid</h1>
<h1>express-middleware-requestid</h1>
</div>
<p align="center">
A middleware that generates a unique Request ID for every incoming HTTP request in Koa2.
A middleware that generates a unique Request ID for every incoming HTTP request in express.
</p>

@@ -34,6 +34,6 @@

# Using NPM
$ npm install --save @newstudios/koa2-middleware-requestid
$ npm install --save @newstudios/express-middleware-requestid
# Using Yarn
$ yarn add @newstudios/koa2-middleware-requestid
$ yarn add @newstudios/express-middleware-requestid
```

@@ -45,3 +45,3 @@

Use `@newstudios/koa2-middleware-requestid` as a middleware for a [koa](https://github.com/koajs/koa) app. By default, it generates a unique uuid (v4) and exposes it on the response via the `X-Request-ID` header. The id is also saved as part of the *ctx.req.id*、*ctx.request.id*、*ctx.id*.
Use `@newstudios/express-middleware-requestid` as a middleware for a [koa](https://github.com/koajs/koa) app. By default, it generates a unique uuid (v4) and exposes it on the response via the `X-Request-ID` header. The id is also saved as part of the *ctx.req.id*、*ctx.request.id*、*ctx.id*.

@@ -52,3 +52,3 @@ In the following example, the generated uuid is manually exposed on the body for debugging purposes:

const Koa = require('koa');
const requestId = require('@newstudios/koa2-middleware-requestid');
const requestId = require('@newstudios/express-middleware-requestid');
const app = new Koa();

@@ -55,0 +55,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc