Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RAML 1.0 does not support repeatable keys #1

Closed
sichvoge opened this issue Feb 16, 2016 · 2 comments
Closed

RAML 1.0 does not support repeatable keys #1

sichvoge opened this issue Feb 16, 2016 · 2 comments

Comments

@sichvoge
Copy link

The example starting with line 102 is not correct as RAML does not support any repeatable keys. So there should be only one possible get.

@nogates
Copy link

nogates commented Feb 16, 2016

Thanks for opening this issue @sichvoge.

Question related to this. What would it happen if instead of using an object to describe the methods, the resource defines an array? Like this:

/:
 - get: 
    200: 
      # rest of the first response
 - get: 
    200: 
      # rest of the second response

In this case, yaml would build an array of methods and the keys wouldn't be overridden. Still, I think this is not correct because using an array would mean that the resource object can't have no properties, only methods.

@sichvoge
Copy link
Author

I would not prefer that, and maybe that is a discussion for #raml-org/raml-spec repo. IMHO, HTTP methods should be defined uniquely to remove anything that can be ambiguous around your API.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants