SakurWebApiUtilities 1.1.3
See the version list below for details.
dotnet add package SakurWebApiUtilities --version 1.1.3
NuGet\Install-Package SakurWebApiUtilities -Version 1.1.3
<PackageReference Include="SakurWebApiUtilities" Version="1.1.3" />
<PackageVersion Include="SakurWebApiUtilities" Version="1.1.3" />
<PackageReference Include="SakurWebApiUtilities" />
paket add SakurWebApiUtilities --version 1.1.3
#r "nuget: SakurWebApiUtilities, 1.1.3"
#:package SakurWebApiUtilities@1.1.3
#addin nuget:?package=SakurWebApiUtilities&version=1.1.3
#tool nuget:?package=SakurWebApiUtilities&version=1.1.3
WebApiUtilities
Tiny nuget package to help with web api development in asp.net core. Nuget link: https://www.nuget.org/packages/SakurWebApiUtilities/
Rate limiting
Requires a distributed memory cache:
(in Program.cs or where your webapi is built)
builder.Services.AddDistributedMemoryCache();
Then add rate limiting:
app.UseRateLimiting();
Above controller methods you can now add:
[Limit(MaxRequests = 20, TimeWindow = 10)]
MaxRequests: The amount of requests allowed during the time specified in seconds in TimeWindow TimeWindow: The time window in seconds during which MaxRequests amount of requests are allowed
Auth
(in Program.cs or where your webapi is built)
builder.Services.SetupAuth();
Will setup the authentication for the service collection
Parameters:
services = The service collection to use
authDomain = The domain for the auth
authAudience = The audience for the auth
roles = The roles to have in the auth
authenticationScheme = The scheme to use, default is "Bearer"
Returns: The service collection again so that calls can be chained
Product | Versions 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 was computed. 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 was computed. 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. |
-
net8.0
- Microsoft.AspNetCore.Authentication.JwtBearer (>= 8.0.8)
- Npgsql (>= 8.0.3)
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.7.0 | 604 | 4/28/2025 |
1.6.2 | 167 | 4/23/2025 |
1.6.1 | 161 | 4/23/2025 |
1.6.0 | 177 | 4/22/2025 |
1.5.2 | 630 | 3/13/2025 |
1.5.1 | 134 | 12/21/2024 |
1.5.0 | 116 | 12/20/2024 |
1.4.0 | 119 | 12/19/2024 |
1.3.2 | 371 | 11/29/2024 |
1.2.1 | 184 | 10/30/2024 |
1.2.0 | 111 | 10/29/2024 |
1.1.3 | 117 | 10/25/2024 |
1.1.2 | 118 | 10/25/2024 |
1.1.1 | 185 | 9/17/2024 |
1.1.0 | 155 | 7/8/2024 |
1.0.0 | 3,292 | 5/22/2021 |