// On top of logger file const Sentry = require('winston-sentry-log'); .... .... // Inside the transports array new Sentry({ config: { dsn: process.env.SENTRY_DSN }, level: "warn" })