Blog

Blog posts on .NET, Azure, and more.

Bring your own functions to Azure Static Web Apps

December 10, 2021 by Anuraj

Azure StaticWebApp Serverless

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 web apps support only HTTP Trigger functions. It is recommended in use cases like if we want to add some extra triggers like CosmosDB or Queue trigger or we need to manage the functions ourself. Once we enable this feature, we can’t use the default functions support in Azure Static Web App.

Handling file uploads in Open API with ASP.NET Core

December 09, 2021 by Anuraj

AspNetCore OpenAPI

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.

Create Azure Functions with GraphQL Support

December 05, 2021 by Anuraj

DotNetCore GraphQL Serverless Azure Azure Functions

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 we need to add the HotChocolate.AzureFunctions package - which will help you to configure the Azure Function with GraphQL attribute. Here is the code for the Azure Function.

GraphQL Subscriptions in ASP.NET Core

December 01, 2021 by Anuraj

AspNetCore GraphQL DotNet6

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, but subscriptions could also be raised through other backend systems.

GraphQL Mutations in ASP.NET Core

November 27, 2021 by Anuraj

AspNetCore GraphQL DotNet6 EFCore

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 using Entity Framework Core.

Copyright © 2024 Anuraj. Blog content licensed under the Creative Commons CC BY 2.5 | Unless otherwise stated or granted, code samples licensed under the MIT license. This is a personal blog. The opinions expressed here represent my own and not those of my employer. Powered by Jekyll. Hosted with ❤ by GitHub