1.0.2 • Published 8 years ago

bunyan-hipchat v1.0.2

Weekly downloads
14
License
MIT
Repository
github
Last release
8 years ago

bunyan-hipchat

Bunyan Illustration by Brendan Corris

Stream to write bunyan logs to HipChat.

Usage

var bunyan = require('bunyan');
var BunyanHipchat = require('bunyan-hipchat');

var token = '1234512345123451234512345123451234512345'
var roomID = '12345';

// Add HipChat plugin/stream to Bunyan
var logger = bunyan.createLogger({
  name: 'API',
  streams: [
    {
      level: 'trace',
      stream: process.stdout
    }, {
      level: 'trace',
      stream: new BunyanHipchat({
        token: token,
        roomId: roomId
      }),
      type: 'raw'
    }
  ]
});

// Log different levels
logger.trace('trace');
logger.debug('debug');
logger.info('info');
logger.warn('warn');
logger.error('error');
logger.fatal('fatal');

Example

Note: Don't forget to fill with a valid token and roomId

TOKEN="" ROOMID="" npm run example

Contributors

This project was created by Thales Pinheiro (@thalesfsp)

Roadmap

  • Next version: 2.0
  • Features:
    • Add tests
    • Move to ES6
    • Allow selection between api V1/V2
1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago

0.0.4

8 years ago

0.0.3

8 years ago

0.0.2

8 years ago

0.0.1

8 years ago