get the origin of api request node express code example
Example: express get request origin
app.use((req, res, next) => {
const host = req.get('host');
const origin = req.get('origin');
});
app.use((req, res, next) => {
const host = req.get('host');
const origin = req.get('origin');
});