AddHttpLogging is an ASP.NET Core extension method that registers the services required by HTTP logging middleware and configures its options. Call it through WebApplicationBuilder.Services before using HTTP logging. section 3.7.1
Configure logged request fields
builder.Services.AddHttpLogging(opts => opts.LoggingFields = HttpLoggingFields.RequestProperties); section 3.7.1
builder.Services.AddHttpLogging(opts => opts.LoggingFields = HttpLoggingFields.RequestProperties);
View the compact registration example showing how an options callback selects the HTTP fields to log. section 3.7.1
