swagger-api/swagger-codegen

Codegen doesn't use "example" for response body

Open

#2,387 建立於 2016年3月15日

在 GitHub 查看
 (5 留言) (0 反應) (0 負責人)HTML (5,474 fork)batch import
Enhancement: FeatureServer: Nodejshelp wanted

倉庫指標

Star
 (12,701 star)
PR 合併指標
 (30 天內沒有已合併 PR)

描述

Not sure if this is by design or bug. I have example for every object under definitions section. When I use codegen to generate a nodejs server, I am hoping at least the response body for GET should use the example data, but it doesn't.

Example data shows up under "Response Class", but when I click "Try it out!", in stead of example data, I get generic json object generated by Codegen using the schema. Like {"userName": "aeiou"}

Do I miss anything? Thanks

貢獻者指南