Open geekybaiyi opened 7 years ago
The "x_example" annotation is for this. The swagger importer already implements that. I think the generator just needs to preserve it. Also, structured type examples don't apparently work. Will try to fix this.
Hi, @boynton
could you help share if there is any update?
Thanks, SC
The examples will need to be encoded as JSON strings to be compatible with swagger. This is a bigger change than I initially thought, might take some days to get in place. If "x_example" attributes are used in the meantime, I'd recommend encoding as JSON, i.e. "x_example": "{\\"foo\\":23}"
Hi, @boynton
could you help also cover "rdl-gen-markdown" for RDL's markdown files generators?
Thanks, SC
Yes, I'll include markdown when adding this feature.
@boynton great! thanks for your help
@boynton any update on this issue ? can RDL support examples for fields, requests and responses? similar to what Sagger provides http://swagger.io/docs/specification/adding-examples/
No update yet, it hasn't been forgotten, though.
do you have an estimation on when this will be available ?
hi @boynton May I know what the overall plan and commitment on RDL are?
thx!
Hi @geekybaiyi, sorry about being away for so long, this is one of the enhancements that got left hanging last year. I now plan to implement OpenAPI3 import/export, and the examples would be part of that. It requires an RDL model change, which I've been resistant to. But I now plan a v2 of RDL to address this, as well as how the generators are implemented in the tooling. Other API management tools have come a long ways since I wrote RDL, so I will be more focused on inter-op moving forward, treating RDL largely an IDL to generate other formats.
hi,
can RDL support examples for fields, requests and responses? similar to what Sagger provides http://swagger.io/docs/specification/adding-examples/ Maybe also allow users to provide a short description/comments on the examples.
thx!