Greetings, Programs
Welcome to my blog.
This website is an attempt to write ideas down so I can refer to them later. If someone else finds these ideas useful, then I am glad.
Matthew Edgar
edgamat@outlook.com
https://github.com/edgamat
Latest Posts
Scripting .NET CLI CI/CD Commands
You submit your code for review and the CI/CD pipeline for your branch fails. I wish I could have known about it before I submitted the PR!
Use JSON Property Names in ASP.NET Validation Error Messages
ASP.NET Web API projects using controllers have a powerful validation mechanism that provides callers with detailed messages when they have sent invalid payloads. One of the problems though, is that the messages don’t use JSON Property Names if the model properties are decorated with
[JsonPropertyName]
attributes. Let’s fix that.ASP.NET Model Binding Quirks
Awhile ago I wrote about using the new JSON library and model binding: Dealing with ASPNET Core 3 API Contract Changes. I only recently started to use it with ASP.NET 8. It has some quicks… let me explain.
Customizing OpenAPI Documentation In ASP.NET - Part 2
In Part 1 of Customizing OpenAPI Documentation In ASP.NET, we looked at how to ensure responses for each the status code were provided and that the payloads. There are still more customizations we can make.
Customizing OpenAPI Documentation In ASP.NET - Part 1
The default OpenAPI documentation generated from your ASP.NET code is rarely correct. Or rather, it is rarely what you want it to be. Let’s see how we can make it better.