在RAML,有提供基于查询参数不同的例子的方式 [英] In RAML, is there a way to provide different examples based on a query parameter

查看:159
本文介绍了在RAML,有提供基于查询参数不同的例子的方式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想问题是pretty言自明。我有一个名为的查询参数展开其中,如果提供,将提供相关的资源埋嵌重presentations。否则,它提供链接到上述资源。有没有办法提供基于价值这两个例子的方式展开在肾错构瘤?

I guess the question is pretty self-explanatory. I have a query parameter called expand which, when provided, will provided embedded representations of related resources. Otherwise it provides links to said resources. Is there a way to provide these two examples based on the value of expand in RAML?

推荐答案

肾错构瘤1.0配备了这种支持,看到的 https://github.com/raml-org/raml-spec/issues/107 详情

RAML 1.0 come with this support, see https://github.com/raml-org/raml-spec/issues/107 for details

这篇关于在RAML,有提供基于查询参数不同的例子的方式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆