An unhandled exception occurred while processing the request. SwaggerGeneratorException:…
- Assistant
Hello! How can I assist you today?
- User
An unhandled exception occurred while processing the request. SwaggerGeneratorException: Ambiguous HTTP method for action - A11Api.Controllers.HomeController.Index (A11Api). Actions require an explicit HttpMethod binding for Swagger/OpenAPI 3.0 Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator.PrepareGenerateOperation(IGrouping<string, ApiDescription> group)
Stack Query Cookies Headers Routing SwaggerGeneratorException: Ambiguous HTTP method for action - A11Api.Controllers.HomeController.Index (A11Api). Actions require an explicit HttpMethod binding for Swagger/OpenAPI 3.0 Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator.PrepareGenerateOperation(IGrouping<string, ApiDescription> group) System.Linq.Enumerable+IteratorSelectIterator<TSource, TResult>.MoveNext() Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator.GenerateOperationsAsync(OpenApiDocument document, IEnumerable apiDescriptions, SchemaRepository schemaRepository) Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator.GeneratePathsAsync(OpenApiDocument document, IEnumerable apiDescriptions, SchemaRepository schemaRepository, Func<OpenApiDocument, IGrouping<string, ApiDescription>, SchemaRepository, Task<Dictionary<OperationType, OpenApiOperation>>> operationsGenerator) Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator.GeneratePathsAsync(OpenApiDocument document, IEnumerable apiDescriptions, SchemaRepository schemaRepository) Swashbuckle.AspNetCore.SwaggerGen.SwaggerGenerator.GetSwaggerAsync(string documentName, string host, string basePath) Swashbuckle.AspNetCore.Swagger.SwaggerMiddleware.Invoke(HttpContext httpContext, ISwaggerProvider swaggerProvider) Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context) Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)
- Assistant
The error message:
SwaggerGeneratorException: Ambiguous HTTP method for action - A11Api.Controllers.HomeController.Index (A11Api). Actions require an explicit HttpMethod binding for Swagger/OpenAPI 3.0