All Projects → serilog-contrib → serilog-sinks-slackclient

serilog-contrib / serilog-sinks-slackclient

Licence: Apache-2.0 License
Slack Sink for Serilog

Programming Languages

C#
18002 projects
F#
602 projects

Projects that are alternatives of or similar to serilog-sinks-slackclient

PoShLog
🔩 PoShLog is PowerShell cross-platform logging module. It allows you to log structured event data into console, file and much more places easily. It's built upon great C# logging library Serilog - https://serilog.net/
Stars: ✭ 108 (+350%)
Mutual labels:  serilog-sink, serilog
serilog-sinks-rabbitmq
Serilog Sink for RabbitMq
Stars: ✭ 49 (+104.17%)
Mutual labels:  serilog-sink, serilog
serilog-sinks-seq
A Serilog sink that writes events to the Seq structured log server
Stars: ✭ 132 (+450%)
Mutual labels:  serilog-sink, serilog
serilog-sinks-xamarin
A Serilog sink that writes events to Xamarin mobile targets
Stars: ✭ 46 (+91.67%)
Mutual labels:  serilog-sink, serilog
google-cloud-build-slack
Slack integration for Google Cloud Container Builder, using Google Cloud Functions
Stars: ✭ 76 (+216.67%)
Mutual labels:  slack
serilog-enrichers-clientinfo
Enrich logs with client IP and UserAgent.
Stars: ✭ 42 (+75%)
Mutual labels:  serilog
serilog-sinks-richtextbox
A Serilog sink that writes log events to a WPF RichTextBox control with colors and theme support
Stars: ✭ 48 (+100%)
Mutual labels:  serilog
hubot-code-review
A Hubot script for GitHub code review on Slack.
Stars: ✭ 38 (+58.33%)
Mutual labels:  slack
ASPNETcoreAngularJWT
Angular in ASP.NET Core with JWT solution by systemjs
Stars: ✭ 48 (+100%)
Mutual labels:  serilog
pingmote
Cross-platform Python global emote picker to quickly insert custom images/gifs
Stars: ✭ 24 (+0%)
Mutual labels:  slack
arcus.observability
Observability with Microsoft Azure in a breeze.
Stars: ✭ 24 (+0%)
Mutual labels:  serilog
slack-php-app-framework
Robust PHP framework for building Slack apps in PHP
Stars: ✭ 29 (+20.83%)
Mutual labels:  slack
monolog-http
A collection of monolog handlers that use a PSR-18 HTTP Client to send your logs
Stars: ✭ 34 (+41.67%)
Mutual labels:  slack
slack widgets
An abstraction of the JSON structure needed to create widgets in Slack message attachments
Stars: ✭ 14 (-41.67%)
Mutual labels:  slack
google-calendar-slack-status
Automatically sync your Google Calendar events to your Slack status
Stars: ✭ 33 (+37.5%)
Mutual labels:  slack
NLog.Slack
An NLog target for Slack - your logs in one place and instantly searchable, everywhere.
Stars: ✭ 46 (+91.67%)
Mutual labels:  slack
concourse-slack-notifier
A structured Slack notification resource for Concourse
Stars: ✭ 17 (-29.17%)
Mutual labels:  slack
burnout-barometer
A simple Slack tool to log, track, and assess you or your team's stress and work-life
Stars: ✭ 29 (+20.83%)
Mutual labels:  slack
slack-reminder
Slack remind generator
Stars: ✭ 31 (+29.17%)
Mutual labels:  slack
iris
Watch on Kubernetes events, filter and send them as standard wehbook to any system
Stars: ✭ 57 (+137.5%)
Mutual labels:  slack

Serilog.Sinks.Slack

Contributors needed!


Build status NuGet Version NuGet Version

A Serilog sink that writes events as messages to Slack. Slack client was developed in F#.

Package - Serilog.Sinks.SlackClient | Platform - .NET 4.5.1

Package - Serilog.Sinks.Slack.Core | Platform - .NET Standard 2.0.1

.NET Core now supported - Just download this package NuGet Version (only incoming webhooks are supported in this package)

You'll need to have a Channel Id and a Token on your Slack team to be able to send messages. To manage tokens go to Slack Tokens. In the example shown, the Channel Id in use is XXXXXXXXX and the token is yyyyyyyyyyyy.

var log = new LoggerConfiguration()
    .WriteTo.Slack("XXXXXXXXX", "yyyyyyyyyyyy", LevelAlias.Maximum)
    .CreateLogger();
log.Fatal("This is an fatal message!");

Example:

Simple Message

Other option is to use incoming webhooks:

var log = new LoggerConfiguration()
	.WriteTo.Slack("https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX")
	.CreateLogger();
log.Fatal("This is an fatal message!");

Example:

Simple Message

To change the default renderization pass a delegate as an additional parameter:

var log = new LoggerConfiguration()
	.WriteTo.Slack("https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX",
                (LogEvent l) => l.RenderMessage())
	.CreateLogger();

For more information about the default render function take a look to:

string RenderMessage(LogEvent logEvent)

at SlackSink.cs

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].