skip to Main Content

Minimal API and XML formatters – Asp.net

Trying out minimal APIs in .NET 6 and can't make it work with XML content type. If I use standard controllers, using .AddXmlSerializerFormatters() extension does the job: builder.Services.AddControllers().AddXmlSerializerFormatters(); But when I switch from controller to .MapPost(..), I start getting 415…

VIEW QUESTION
Back To Top
Search