Skip to content

Commit

Permalink
docs: add pino-slack-webhook to list of v7+ compatible transports (#1730
Browse files Browse the repository at this point in the history
)
  • Loading branch information
youngkiu committed Jun 8, 2023
1 parent 872934c commit 802171c
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions docs/transports.md
Original file line number Diff line number Diff line change
Expand Up @@ -398,6 +398,7 @@ PRs to this document are welcome for any new transports!
+ [pino-sentry-transport](#pino-sentry-transport)
+ [pino-airbrake-transport](#pino-airbrake-transport)
+ [pino-datadog-transport](#pino-datadog-transport)
+ [pino-slack-webhook](#pino-slack-webhook)
### Legacy
Expand Down Expand Up @@ -908,6 +909,29 @@ $ node app.js | pino-websocket -a my-websocket-server.example.com -p 3004
For full documentation of command line switches read the [README](https://github.com/abeai/pino-websocket#readme).
<a id="pino-slack-webhook"></a>
### pino-slack-webhook
[pino-slack-webhook][pino-slack-webhook] is a Pino v7+ compatible transport to forward log events to [Slack][Slack]
from a dedicated worker:
```js
const pino = require('pino')
const transport = pino.transport({
target: '@youngkiu/pino-slack-webhook',
options: {
webhookUrl: 'https://hooks.slack.com/services/xxx/xxx/xxx',
channel: '#pino-log',
username: 'webhookbot',
icon_emoji: ':ghost:'
}
})
pino(transport)
```
[pino-slack-webhook]: https://github.com/youngkiu/pino-slack-webhook
[Slack]: https://slack.com/
[pino-pretty]: https://github.com/pinojs/pino-pretty
<a id="communication-between-pino-and-transport"></a>
Expand Down

0 comments on commit 802171c

Please sign in to comment.