Azure Functions (Isolated Worker)

Sentry provides an integration with Azure Functions through the Sentry.Azure.Functions.Worker NuGet package. All triggers are supported.


Add the Sentry dependency to your Azure Functions application:

dotnet add package Sentry.Azure.Functions.Worker -v 3.41.3

This package extends Sentry.Extensions.Logging. This means that besides the Azure Functions related features, through this package you'll also get access to the ILogger<T> integration and also the features available in the main Sentry SDK.


Sentry integration with Azure Functions (when using the Isolated Worker Process execution mode) is done by calling .UseSentry() and specifying the options. E.g.:

var host = new HostBuilder()
    .ConfigureFunctionsWorkerDefaults((host, builder) =>
        builder.UseSentry(host, options =>
            options.Dsn = "";
            options.EnableTracing = true;
            // When configuring for the first time, to see what the SDK is doing:
            // options.Debug = true;
await host.RunAsync();


Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").