Skip to content
Raven is a C# client for Sentry (
Branch: master
Clone or download
Pull request Compare This branch is 481 commits behind getsentry:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Instantiate the client with your DSN:

var ravenClient = new RavenClient("");

Capturing Exceptions

Call out to the client in your catch block:

    int i2 = 0;
    int i = 10 / i2;
catch (Exception e)

Logging Non-Exceptions

You can capture a message without being bound by an exception:

ravenClient.CaptureMessage("Hello World!");

Additional Data

The capture methods allow you to provide additional data to be sent with your request. CaptureException supports both the tags and extra properties, and CaptureMessage additionally supports the level property.

The full argument specs are:

CaptureException(Exception e, IDictionary<string, string> tags = null, object extra = null)
CaptureMessage(string message, ErrorLevel level =, Dictionary<string, string> tags = null, object extra = null)

Get it!

You can clone and build SharpRaven yourself, but for those of us who are happy with prebuilt binaries, there's a NuGet package.


You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.