Integration Testing ASP.NET Core 6 Minimal APIs
This post is about implementing integration testing in ASP.NET Core Minimal APIs. Usually when I talk about Minimal APIs, one of the question I used to get is how to implement integration testing and I saw some questions related to this in Stack Overflow as well. In this blog post...
Bring your own functions to Azure Static Web Apps
Azure Static Web Apps APIs are supported by two possible configurations: managed functions and bring your own functions. This post is about using your existing functions in Azure Static Web apps. Bring your own functions is only available in the Azure Static Web Apps Standard plan. By default Azure Static...
Handling file uploads in Open API with ASP.NET Core
This post is about implementing handling file uploads in Open API with ASP.NET Core. Open API is one way to document REST API endpoints. When we using Web API and IFormFile class to upload a file, Open API will display a File Upload control in the UI like this. Here...
Create Azure Functions with GraphQL Support
This post is about creating .NET Core Azure Functions with GraphQL Support. For supporting GraphQL we are using the HotChocolate package. First we need create an Azure Function using the func init GraphQL-Azure-Function --dotnet command. Or if you’re using VSCode create a function with dotnet runtime and HTTP Trigger. Next...
GraphQL Subscriptions in ASP.NET Core
This post is about implementing Subscriptions in GraphQL. Subscriptions are a GraphQL feature that allows a server to send data to its clients when a specific event happens. Subscriptions are usually implemented with WebSockets. The subscription type is almost implemented like a query. Most cases subscriptions are raised through mutations,...
GraphQL Mutations in ASP.NET Core
This post is about GraphQL in ASP.NET Core with EF Core. In this post we will explore how to implement mutations using ASP.NET Core. Mutations help you to update the data in the database. Here is the Mutation class. In this class, we are adding the link object to database...
Azure Functions - Could not load file or assembly System.Text.Encoding.CodePages
This post is about how to fix the exception Could not load file or assembly System.Text.Encoding.CodePages when you’re using any HTML parser in Azure Functions. Recently while working on Azure Static Web App, I faced an issue like this. I created an Azure Function in Dotnet, which helps to parse...
Working with model validation in Minimal APIs
This post is about implementing model validation in ASP.NET Core Minimal APIs. Minimal APIs do not come with any built-in support for validation. In this post we will explore how to build one and we explore will use some other libraries which can be used to implement validations. You can...