Soenneker.Controllers.Alerts 11.0.907

Prefix Reserved
dotnet add package Soenneker.Controllers.Alerts --version 11.0.907
                    
NuGet\Install-Package Soenneker.Controllers.Alerts -Version 11.0.907
                    
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="Soenneker.Controllers.Alerts" Version="11.0.907" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Controllers.Alerts" Version="11.0.907" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Controllers.Alerts" />
                    
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 Soenneker.Controllers.Alerts --version 11.0.907
                    
#r "nuget: Soenneker.Controllers.Alerts, 11.0.907"
                    
#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 Soenneker.Controllers.Alerts@11.0.907
                    
#: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=Soenneker.Controllers.Alerts&version=11.0.907
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Controllers.Alerts&version=11.0.907
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

Soenneker.Controllers.Alerts

Adds an MVC endpoint that accepts Azure Monitor common alert schema payloads and forwards them to IAlertsCoordinator.

Install

dotnet add package Soenneker.Controllers.Alerts

Register the controller and coordinator

using Soenneker.Controllers.Alerts;
using Soenneker.Coordinators.Alerts.Registrars;

builder.Services
    .AddControllers()
    .AddApplicationPart(typeof(AlertsController).Assembly);

builder.Services.AddAlertsCoordinatorAsSingleton();

The coordinator requires these application settings in addition to the Microsoft Teams settings used by Soenneker.MsTeams.Util:

{
  "Api": {
    "Alerts": {
      "AzureApiKey": "replace-with-a-random-secret"
    }
  },
  "Environment": "Production"
}

Endpoint

POST /alerts/azure?apiKey=<secret>
Content-Type: application/json

The body is a CasRequest from Azure Monitor's common alert schema.

Response Meaning
201 Created The coordinator accepted and forwarded the alert
400 Bad Request The payload did not contain the required alert data

The controller is excluded from API Explorer and marked AllowAnonymous; the configured API key is its application-level credential. Authentication failure is surfaced by the coordinator through the application's exception handling.

Security and operation

  • Azure Monitor's ordinary webhook model commonly places a token in the callback URL. Query strings are frequently captured by gateways, access logs, traces, and deployment state. Use HTTPS, redact the apiKey query value throughout the request path, rotate it when exposed, and never place the callback URL in source control.
  • For stronger authentication, prefer an Azure Monitor Secure Webhook protected by Microsoft Entra ID and an application endpoint configured for bearer authentication. That requires host-level authentication rather than this controller's static-key coordinator contract.
  • Cancellation is forwarded to the coordinator and Microsoft Teams delivery. It does not undo a message already accepted by the downstream service.
  • API version 1 is declared through ASP.NET API Versioning; the host determines whether versions are selected by query string, header, media type, or another configured reader.
Product Compatible and additional computed target framework versions.
.NET net11.0 is compatible. 
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
11.0.907 0 11/15/2026
11.0.906 0 11/14/2026
11.0.905 61 11/12/2026
11.0.904 54 11/12/2026
11.0.903 53 11/12/2026
11.0.902 48 11/12/2026
11.0.901 45 11/11/2026
11.0.900 58 11/11/2026
11.0.899 47 11/11/2026
11.0.897 67 11/11/2026
11.0.896 53 11/11/2026
11.0.895 42 11/11/2026
11.0.894 55 11/11/2026
11.0.892 164 11/3/2026
11.0.891 94 11/3/2026
11.0.890 93 11/3/2026
11.0.889 87 11/3/2026
11.0.888 83 11/3/2026
11.0.887 91 11/3/2026
11.0.886 90 11/3/2026
Loading failed

Update dependency Soenneker.Coordinators.Alerts to 11.0.1095 (#1463)