swagger-api / swagger-core

Examples and server integrations for generating the Swagger API Specification, which enables easy access to your REST API
http://swagger.io
Apache License 2.0
7.36k stars 2.17k forks source link

Set parameter schema base on schema or array of the @Parameter annotation #4665

Open coder-hugo opened 2 months ago

coder-hugo commented 2 months ago

The current implementation ignores the content of schema and array of the @Parameter annotation, when generating the schema for a parameter. So it's impossible to specify the allowed values for a parameter of type String by using an enum. This PR will fix this.