Minimal API’s on .NET 6

Nelson Parente
3 min readNov 11, 2021
Photo by Bench Accounting on Unsplash

Hi there guys!

It’s been a while since my last article, lot’s of things going on in the last months but I’m glad to be back on writing. Sometimes you just don’t feel like it and that's ok.

(To be honest, Diablo 2 Resurrected came out and that didn’t help.)

So let’s get this started. As many of you already know .NET 6 was released and with it, we have some really new cool features among those we have Minimal APIs.

If you already looked at some other web frameworks such as Node.JS you know that you can run a web server from just a single file, in my opinion, that's one of the main value propositions of these kinds of lightweight frameworks.

When you just want a single endpoint API, setting up that on .NET would have lots of overhead, and compared to the single file server from Node.JS the choice would be easy to do.

The Minimal Apis came to solve exactly this issue, basically, this will allow us to create micro APIs without all this overhead that we are all aware of. As a Microsoft fanboy, this makes me very happy because I believe that this will have a very good adoption from the community.

--

--