Wednesday, 23 October 2024

add header to the web api globally

 builder.Services.AddSwaggerGen(c =>

{ c.OperationFilter<AddRegionCodeHeaderParameter>(); c.EnableAnnotations(); c.SwaggerDoc("v1", new OpenApiInfo { Title = "Patient Web API", Version = "v1" }); c.OperationFilter<AddRegionCodeHeaderParameter>(); });

No comments:

Post a Comment

API run block issue run api from cmd

  ✅ Debug Checklist – “Access is Denied” (.NET / Visual Studio) 🔹 Identify Problem ☐ Error: Unable to start program (.exe) – Access is deni...