winston-rocketchat-transport

0.1.0 • Public • Published

Winston Transport for Rocket Chat chat integration.

npm install --save winston-rocketchat-transport

Basic transport that works just like all other winston transports. Sends logged messages to a specified Slack chat channel.

Configuration options:

  • webhook_url: required The webhook URL, something like https://yourworkspace.rocket.chat/hooks/XXXXXXXXX/YYYYYYYYY/ZZZZZZZZZZZZZZZZZZZZZZZZ
  • level: If specified, this logger will only log messages at the specified level of importance and more important messages
  • custom_formatter: a function (level, msg, meta) which returns a Slack payload object

var winston = require('winston');
var RocketChat = require('winston-rocketchat-transport');

winston.add(RocketChat, {
    webhook_url: "https://hooks.slack.com/services/XXXXXXXXX/YYYYYYYYY/ZZZZZZZZZZZZZZZZZZZZZZZZ",
    level: 'error',
    handleExceptions: true
});

Package Sidebar

Install

npm i winston-rocketchat-transport

Weekly Downloads

0

Version

0.1.0

License

none

Unpacked Size

4.15 kB

Total Files

4

Last publish

Collaborators

  • gleidsonf