QueueHawk.Agent 1.1.1

dotnet add package QueueHawk.Agent --version 1.1.1
                    
NuGet\Install-Package QueueHawk.Agent -Version 1.1.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="QueueHawk.Agent" Version="1.1.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="QueueHawk.Agent" Version="1.1.1" />
                    
Directory.Packages.props
<PackageReference Include="QueueHawk.Agent" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add QueueHawk.Agent --version 1.1.1
                    
#r "nuget: QueueHawk.Agent, 1.1.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package QueueHawk.Agent@1.1.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=QueueHawk.Agent&version=1.1.1
                    
Install as a Cake Addin
#tool nuget:?package=QueueHawk.Agent&version=1.1.1
                    
Install as a Cake Tool

QueueHawk.Agent

The Hangfire dashboard you already have doesn't survive a restart, doesn't cover more than one app, and doesn't tell anyone when a job silently stops running. QueueHawk does.

QueueHawk.Agent is a lightweight NuGet package that plugs into your existing Hangfire setup and streams job history, failures, and worker heartbeats to QueueHawk — a hosted dashboard built for teams and agencies running Hangfire across multiple apps, clients, and environments.

QueueHawk dashboard showing four applications with health status, environment, and last activity

  • 📊 One dashboard for every app — stop tab-hopping between a dozen /hangfire dashboards for a dozen client projects.
  • 🕓 Persistent history — job history survives redeploys and restarts, unlike Hangfire's own dashboard.
  • 🔔 Real alerting — get a Slack, Teams, or email alert when error rates spike or a server stops sending heartbeats, instead of finding out when a client calls.
  • 💓 Heartbeat monitoring — catches the scary case a pure job-event feed can't: a worker that's alive but has quietly stopped picking up jobs at all.
  • 🔒 Privacy by design — job arguments/payloads are never sent unless you explicitly opt in; only metadata (job type, queue, timing, state, exception details) leaves your infrastructure, and exception content itself can be redacted or dropped before it ever leaves the process via OnBeforeSend.
  • ðŸ“Ī Push-only, one outbound hostname — the agent only ever makes outbound HTTPS calls; nothing needs to be opened inbound in your firewall.
  • ðŸŠķ Negligible overhead — job state changes are captured via Hangfire's own filter pipeline and dropped onto an in-memory channel; a background service batches and ships them, so nothing in your job execution path waits on a network call.
  • ðŸ›Ąïļ Fails safe — the agent can never throw into your job pipeline. Every internal operation is exception-guarded; if QueueHawk is unreachable, jobs keep running and events buffer locally (oldest dropped first past 5,000 events) until it recovers.

Install

dotnet add package QueueHawk.Agent

Quick start

Get an API key by creating a free account and an application at queuehawk.com, then register the agent alongside your existing Hangfire setup:

builder.Services.AddHangfire(config => config.UseSqlServerStorage(connectionString));
builder.Services.AddHangfireServer();

// QueueHawk integration — one line, no changes to existing job code
builder.Services.AddQueueHawk(options =>
{
    options.ApiKey = builder.Configuration["QueueHawk:ApiKey"];
    options.Environment = "Production"; // free-text label, e.g. also useful as a client/tenant name
});

That's it — no Hangfire storage access required, no extra process to run. Job events and heartbeats start showing up in your QueueHawk dashboard within seconds.

Configuration

All options are optional except ApiKey:

Option Description Default
ApiKey Identifies your QueueHawk tenant/application (required)
Environment Free-text label shown in the dashboard (e.g. "Production", "Client XY - Staging") "Default"
IncludeJobPayloads Also send job argument values (opt-in — off by default to avoid exfiltrating PII/business data) false
OnBeforeSend Callback invoked per event before it enters the local buffer — redact/mask fields or return null to drop the event entirely. See below. null
MaxStackTraceLength Truncates long stack traces before sending 4000
BatchIntervalSeconds How often buffered events are flushed 5
HeartbeatIntervalSeconds How often each Hangfire server reports a heartbeat 30
Enabled Global on/off switch (e.g. disable for local development) true
MaxBufferedEvents Local ring-buffer size (oldest dropped first once full) 5000
IngestionBaseUrl Ingestion API hostname — override only for local testing/self-hosting "https://ingest.queuehawk.com"

Redacting sensitive exception content

Exception messages and stack traces are sent as-is by default (only truncated to MaxStackTraceLength) — job payloads are the thing that's off by default (IncludeJobPayloads), not exception text. If an exception message itself can contain PII (e.g. a validation error that echoes a customer's email address), use OnBeforeSend to redact or drop the event before it's ever buffered in memory:

builder.Services.AddQueueHawk(options =>
{
    options.ApiKey = builder.Configuration["QueueHawk:ApiKey"];
    options.Environment = "Production";

    options.OnBeforeSend = jobEvent =>
    {
        if (jobEvent.ExceptionMessage is null)
        {
            return jobEvent;
        }

        return jobEvent with
        {
            ExceptionMessage = Regex.Replace(
                jobEvent.ExceptionMessage,
                @"[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}",
                "[REDACTED-EMAIL]"),
        };
    };
});

The callback runs for every state-change event (not just failures), can return a rewritten JobEventDto, and returning null drops that event entirely — nothing is buffered or sent. Like every other agent operation, an exception thrown from your callback never propagates into your Hangfire job pipeline; that one event is simply dropped. Full option reference: queuehawk.com/docs/agent-configuration.

How it works

QueueHawk.Agent hooks into Hangfire's own IElectStateFilter/IApplyStateFilter extension points — the same mechanism Hangfire itself uses — so it sees every job state transition (Enqueued → Processing → Succeeded/Failed, including retries) without touching your job code or your Hangfire storage. Each event is written to a non-blocking in-memory channel; a background service batches and ships them over HTTPS. A second background service reports a periodic heartbeat per Hangfire server, which is how QueueHawk detects the failure mode a job-event stream alone can't: a server that's still running but has stopped processing anything at all.

Compatibility

  • .NET: 8, 9, and 10
  • Hangfire: works against any Hangfire storage backend (SQL Server, PostgreSQL, Redis, ...) — the agent only uses Hangfire's filter API, never talks to storage directly

Learn more

  • queuehawk.com — sign up, pricing, and full product overview
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.1 289 8/17/2026
1.1.0 467 8/13/2026
1.0.3 564 7/29/2026
1.0.2 362 7/24/2026
1.0.1 116 7/22/2026
1.0.0 121 7/21/2026