Posts

Showing posts with the label FastEndPoints

Seamless API Versioning with .NET FastEndpoints: A Simple Step-By-Step Guide

Image
Handling Multiple versions of the same API gracefully is one of the common and yet difficult challenge in todays world of distributed application development.  This post will help you through the process of implementing API versioning using a .NET application. We will be creating a FastEndpoints project, focusing on custom middleware and route management. If you are new to FastEndPoints, Encourage you to go through this post : FastEndPoints Basics Why API Versioning? To ensure backward compatibility in a distributed application API-versioning plays a crucial role.  It allows programmers to introduce new features, fix bugs, and make improvements without affecting existing clients. By managing different versions of API, you can offer a smooth transition for users while continuously evolving your service. The Challenge with Duplicate Routes Duplicate Routes is one common issue when implementing API-Versioning. This can occur when you try to manage multiple versions of the...

Creating RESTful Minimal WebAPI in .Net 6 in an Easy Manner! | FastEndpoints

Image
  We might have developed Web APIs using MVC Controllers where we used to give Route Path Attributes to the Controller and  to identify individual methods we used to provide Actions in the Route. With the Controller approach we need to write boiler plate code in separate files which deals with the Configuration of the Web Service. Those who have worked in Node js would be aware of how easy it is to create a Web API and expose different Endpoints without the need of so much boiler plate code. Here we are going to discuss of similar approach for creating a Web API in .Net6 using FastEndpoints. Under the hood it uses Minimal API concept which tries to reduce the dependencies required to achieve a particular task. This approach is more suitable in the case of Microservice Architecture where we want to keep the dependencies to minimum. Must Read : Fluent API and Data Annotations What are FastEndpoints? FastEndpoints is a Framework compatible with .Net 6 which allows to build a...