![]() |
VOOZH | about |
dotnet add package MinimalApis.Extensions --version 0.11.0
NuGet\Install-Package MinimalApis.Extensions -Version 0.11.0
<PackageReference Include="MinimalApis.Extensions" Version="0.11.0" />
<PackageVersion Include="MinimalApis.Extensions" Version="0.11.0" />Directory.Packages.props
<PackageReference Include="MinimalApis.Extensions" />Project file
paket add MinimalApis.Extensions --version 0.11.0
#r "nuget: MinimalApis.Extensions, 0.11.0"
#:package MinimalApis.Extensions@0.11.0
#addin nuget:?package=MinimalApis.Extensions&version=0.11.0Install as a Cake Addin
#tool nuget:?package=MinimalApis.Extensions&version=0.11.0Install as a Cake Tool
A set of extensions and helpers that extend the functionality of ASP.NET Core Minimal APIs.
This package is currently available from nuget.org:
> dotnet add package MinimalApis.Extensions
If you wish to use builds from this repo's main branch you can install them from this repo's package feed.
Create a personal access token for your GitHub account with the read:packages scope with your desired expiration length:
At the command line, navigate to your user profile directory and run the following command to add the package feed to your NuGet configuration, replacing the <GITHUB_USER_NAME> and <PERSONAL_ACCESS_TOKEN> placeholders with the relevant values:
~> dotnet nuget add source -n GitHub -u <GITHUB_USER_NAME> -p <PERSONAL_ACCESS_TOKEN> https://nuget.pkg.github.com/DamianEdwards/index.json
You should now be able to add a reference to the package specifying a version from the repository packages feed
See these instructions for further details about working with GitHub package feeds
> dotnet add package MinimalApis.Extensions
Program.cs, call the AddEndpointsMetadataProviderApiExplorer() method on builder.Services to enable enhanced endpoint metadata in ApiExplorer:
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddEndpointsMetadataProviderApiExplorer(); // <-- Add this line in .NET 6.0 projects
builder.Services.AddSwaggerGen();
...
app.MapPut("/todos/{id}", async Task<Results<NotFound, NoContent>> (int id, Todo todo, TodoDb db) =>
{
var existingTodo = await db.Todos.FindAsync(id);
if (existingTodo is null)
return TypedResults.NotFound();
existingTodo.Title = todo.Title;
existingTodo.IsCompleted = todo.IsCompleted;
await db.SaveChangesAsync();
return TypedResults.NoContent();
})
.WithParameterValidation();
This library provides types that help extend the core functionality of ASP.NET Core Minimal APIs in the following ways:
IParameterBinder and Bind<TValue>, Body<TValue>, JsonFormFile, and othersResults.Extensions including PlainText, Html, and UnsupportedMediaTypeIResult objects for easier unit testing (available via TypedResults) including the IStatusCodeHttpResult, IContentTypeHttpResult, and IValueHttpResult interfacesIEndpointParameterMetadataProvider and IEndpointMetadataProviderIResult return types via Results<TResult1, TResultN> that enable route handler delegates to declare all the possible IResult types they can return, enabling compile-time type checking and automatic population of all possible responses in Swagger/OpenAPI from type informationAn example Todos application using ASP.NET Core Minimal APIs and the Dapper library for data storage in SQLite.
Contains small examples for other types in this library.
Shows many examples of using the types in this library along with other things related to ASP.NET Core Minimal APIs.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0 net6.0 is compatible. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 is compatible. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
Showing the top 1 NuGet packages that depend on MinimalApis.Extensions:
| Package | Downloads |
|---|---|
|
VeoTech.Core.Api.Shared
Shared repo between repos in cloud team in Veo. No business logic, secrets or any other sensitive data in this repo only just shared functionality between repos and a few common test classes as well. |
Showing the top 7 popular GitHub repositories that depend on MinimalApis.Extensions:
| Repository | Stars |
|---|---|
|
DamianEdwards/MinimalApiPlayground
A place I'm trying out the new ASP.NET Core minimal APIs features.
|
|
|
mehdihadeli/food-delivery-modular-monolith
🌭 A practical and imaginary food and grocery delivery modular monolith, built with .Net 8, Domain-Driven Design, CQRS, Vertical Slice Architecture, Event-Driven Architecture, and the latest technologies.
|
|
|
andrewlock/asp-dot-net-core-in-action-3e
Source code examples for ASP.NET Core in Action, Third Edition
|
|
|
davidfowl/uController
A source generator for minimal APIs
|
|
|
dotnet-presentations/eshop-app-workshop
This workshop will teach you ASP.NET Core & .NET Aspire by building the product catalog & order placement features of the eShop reference application.
|
|
| asesidaa/EXVS2-POC | |
|
bitwarden/passwordless-server
Bitwarden Passwordless.dev infrastructure/backend (API, database, Docker, etc).
|
| Version | Downloads | Last Updated |
|---|---|---|
| 0.11.0 | 720,384 | 6/22/2023 |
| 0.10.1 | 42,905 | 12/21/2022 |
| 0.10.0 | 13,105 | 11/29/2022 |
| 0.9.1-pre.20221114.39 | 1,059 | 11/14/2022 |
| 0.9.0-pre.20221011.36 | 6,843 | 10/11/2022 |
| 0.8.0-pre.20220915.33 | 4,156 | 9/15/2022 |
| 0.7.2-pre.20220906.32 | 311 | 9/6/2022 |
| 0.7.1-pre.20220712.30 | 4,762 | 7/12/2022 |
| 0.7.0-pre.20220528.28 | 18,797 | 5/28/2022 |
| 0.6.0-pre.20220429.27 | 4,489 | 4/29/2022 |
| 0.5.2-pre.20220322.22 | 2,373 | 3/22/2022 |
| 0.5.1-pre.20220322.18 | 336 | 3/22/2022 |
| 0.5.0-pre.20220321.15 | 6,969 | 3/21/2022 |
| 0.4.1-pre.20211113.13 | 3,370 | 11/13/2021 |
| 0.4.0-pre.20211113.12 | 729 | 11/13/2021 |
| 0.3.1-pre.20211113.11 | 446 | 11/13/2021 |
| 0.3.1-pre.20211111.10 | 755 | 11/11/2021 |
| 0.3.0-pre.20211110.9 | 385 | 11/10/2021 |
| 0.1.0-pre.20211027.5 | 883 | 10/27/2021 |