Soenneker.Controllers.Base
4.0.86
Prefix Reserved
dotnet add package Soenneker.Controllers.Base --version 4.0.86
NuGet\Install-Package Soenneker.Controllers.Base -Version 4.0.86
<PackageReference Include="Soenneker.Controllers.Base" Version="4.0.86" />
<PackageVersion Include="Soenneker.Controllers.Base" Version="4.0.86" />
<PackageReference Include="Soenneker.Controllers.Base" />
paket add Soenneker.Controllers.Base --version 4.0.86
#r "nuget: Soenneker.Controllers.Base, 4.0.86"
#:package Soenneker.Controllers.Base@4.0.86
#addin nuget:?package=Soenneker.Controllers.Base&version=4.0.86
#tool nuget:?package=Soenneker.Controllers.Base&version=4.0.86
Soenneker.Controllers.Base
Provides an abstract ASP.NET Core ControllerBase that exposes injected IConfiguration to derived controllers through a protected Config property.
Install
dotnet add package Soenneker.Controllers.Base
Usage
using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Configuration;
using Soenneker.Controllers.Base;
[ApiController]
[Route("api/status")]
public sealed class StatusController : BaseController
{
public StatusController(IConfiguration configuration) : base(configuration)
{
}
[HttpGet]
public IActionResult Get()
{
string? environment = Config["Environment"];
return Ok(new { environment });
}
}
BaseController adds no routes, filters, authorization policy, API-versioning behavior, or service registration. Derived controllers remain responsible for their normal ASP.NET Core attributes and must pass IConfiguration to the base constructor.
Config references the application's composed configuration. Whether values update at runtime depends on the underlying providers. Avoid returning secrets or raw configuration values from controller actions.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | 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. |
-
net10.0
- Asp.Versioning.Mvc (>= 10.2.1)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on Soenneker.Controllers.Base:
| Package | Downloads |
|---|---|
|
Soenneker.Controllers.Alerts
AlertsController provides endpoints for receiving Azure alerts and other similar requests |
|
|
Soenneker.Controllers.Health
HealthController provides a public, anonymous-accessible HTTP GET endpoint that returns a simple health check response indicating if the API is online |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.86 | 458 | 10/14/2026 |
| 4.0.85 | 154 | 10/14/2026 |
| 4.0.84 | 86 | 10/14/2026 |
| 4.0.80 | 154 | 10/12/2026 |
| 4.0.79 | 138 | 10/12/2026 |
| 4.0.78 | 201 | 10/11/2026 |
| 4.0.77 | 747 | 9/24/2026 |
| 4.0.76 | 468 | 9/15/2026 |
| 4.0.75 | 341 | 9/12/2026 |
| 4.0.74 | 819 | 8/30/2026 |
| 4.0.73 | 208 | 8/29/2026 |
| 4.0.72 | 1,057 | 8/7/2026 |
| 4.0.71 | 183 | 8/6/2026 |
| 4.0.70 | 199 | 7/30/2026 |
| 4.0.69 | 346 | 7/27/2026 |
| 4.0.68 | 585 | 7/16/2026 |
| 4.0.67 | 1,384 | 6/18/2026 |
| 4.0.66 | 953 | 6/5/2026 |
| 4.0.65 | 1,261 | 4/22/2026 |
| 4.0.64 | 207 | 4/21/2026 |
Update dependency dotnet-sdk to v10.0.402 (#696)