Skip to content
No description, website, or topics provided.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src/Serilog.Sinks.Logz.Io #8 bugfix: restrictedToMinimumLevel not respected Dec 26, 2018
tests
.gitignore #8 bugfix: restrictedToMinimumLevel not respected Dec 26, 2018
LICENSE Reimplementation of LogzIo. Mar 1, 2018
README.md Update README.md with valid setup information Jun 15, 2018
Serilog.Sinks.Logz.Io.sln

README.md

Serilog.Sinks.Logz.Io - A Serilog sink sending log events over HTTP

NuGet Version NuGet Documentation Join the chat at https://gitter.im/serilog/serilog Help

Package - Serilog.Sinks.Logz.Io | Platforms - .NET 4.5, .NET Standard 2.0

Table of contents


Super simple to use

In the following example, the sink will POST log events to https://app.logz.io over HTTPS.

ILogger log = new LoggerConfiguration()
  .MinimumLevel.Verbose()
  .WriteTo.LogzIo("<logzio token>", "<log type>", useHttps: true)
  .CreateLogger();

log.Information("Logging {@Heartbeat} from {Computer}", heartbeat, computer);

More advanced configuration is also available:

ILogger log = new LoggerConfiguration()
  .MinimumLevel.Verbose()
  .WriteTo.LogzIo("<logzio token>", "<log type>",
    new LogzioOptions 
    { 
        UseHttps = true, 
        RestrictedToMinimumLevel = LogEventLevel.Debug,
        Period = TimeSpan.FromSeconds(15),
        BatchPostingLimit = 50
    })
  .CreateLogger();

Install via NuGet

If you want to include the HTTP sink in your project, you can install it directly from NuGet.

To install the sink, run the following command in the Package Manager Console:

PM> Install-Package Serilog.Sinks.Logz.Io
You can’t perform that action at this time.