You may need to set the `defaultValue` attribute. The “example” and “defaultValue” are confusing in the swagger-core implementation in 2.0, it will be changed in the next major version
> On Mar 9, 2017, at 5:53 AM, Sergio Stateri <[email protected]> wrote: > > Hi, > > I'm using Swagger 2 and it isn't being possible to define the parameter > example value textbox, that's the example that can be used to try the service. > I already tried using: > @ApiImplicitParam( > ..., > example = "{\"channelCode\": \"WEB\", \"email\": > \"[email protected]\", \"password\": \"cleartextpassword\"}" > ) > public ... > > And I also tried this: > @ApiModelProperty(name = "loginRequest", example = "{\"channelCode\": > \"WEB\", \"email\": \"[email protected]\", \"password\": > \"cleartextpassword\"}") > public ... > > However, these approaches didn't work. How can I change the parameter example > value?? > > > Thanks > > Sergio Stateri Junior > [email protected] > > -- > You received this message because you are subscribed to the Google Groups > "Swagger" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] > <mailto:[email protected]>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. -- You received this message because you are subscribed to the Google Groups "Swagger" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
