express-request-cuid
v1.5.0
Published
A middleware, creating a new cuid for each request, adding a header and appending it to the request object"
Downloads
193
Maintainers
Readme
express-request-cuid
Overview
express-required-cuid provides a simple express/connect middleware for creating a new cuid for each request and appending an x-request-id
header to the request and adding the requestId
and id
property to the request-object.
Usage
Just like above:
import requestCuid from 'express-request-cuid';
import express from 'express';
const app = express();
app.use(requestCuid());
Import the module and use it. It works with CJS require
as well. For any additional configuration, please open a new issue
Have fun coding!
(Types are included)