Live data from Hacker News

RAML – RESTful API modeling language

raml.org

21–30 of 59 posts

Re: RAML – RESTful API modeling language

#21
We recently evaluated RAML, Swagger, and Blueprint.

RAML was the top choice for developer preference and syntax, but industry tooling was much stronger for Swagger.

What we chose was Swagger 2 with the new options for YAML syntax, which gives us good readability/writeability, plus excellent tooling.

Re: RAML – RESTful API modeling language

#22

I wrote a Python parser for this called RAMLfications ( https://ramlfications.readthedocs.org/en/latest/ ) I actually built the API console for my company - Spotify ( https://developer.spotify.com/web-api/console/ ) - based off of RAML and am in the process of open sourcing the tech behind it. The first bit being RAMLfications, and the second, called Griffin ( https://github.com/spotify/griffin ) is a super alpha ver…

What are you using for ref docs? https://developer.spotify.com/web-api/get-album/

Re: RAML – RESTful API modeling language

#24
post #16

Earlier quoted context omitted.

True REST shouldn't require a WSDL-like interface. The semantics of the graph it describes should be enough. This model, however, has yet to be fully realised; largely because of the large upfront cost in R&D. At my work, we are trying to develop in this area, but it's slow going.

Can you expand on that? I've got a mature API that's based around HATEOS, json-schema and HTTP content negotiation. It works really well, but client-side developers always need some time to get used to it, as they expect "REST" to mean "like Rails".

Our hope is that we can combine HATEOAS with an ontology to create autonomous clients and, otherwise, provide rich enough metadata in each resource to generate an appropriate UI (for human facing clients); the 'semantic web' approach.

Re: RAML – RESTful API modeling language

#26
It's nice, but because of the HAML-like format, there are a lot of empty space characters included.

That's great for readability, but it doesn't seem like a perfect choice for a webservice description language, since that content might get hosted and transferred often over the network for clients that might be interested in it.

You could convert to binary to compress it, but that makes it harder for the client, so the friendliest thing would be to convert it to JSON, e.g.: http://my.host/to/a/path/of/my_service.haml.json in addition to the more human-readable haml format at: http://my.host/to/a/path/of/my_service.haml

Re: RAML – RESTful API modeling language

#27

I wrote a Python parser for this called RAMLfications ( https://ramlfications.readthedocs.org/en/latest/ ) I actually built the API console for my company - Spotify ( https://developer.spotify.com/web-api/console/ ) - based off of RAML and am in the process of open sourcing the tech behind it. The first bit being RAMLfications, and the second, called Griffin ( https://github.com/spotify/griffin ) is a super alpha ver…

What are you using for ref docs? https://developer.spotify.com/web-api/get-album/

Currently this is just Wordpress, but we are (at some point, not when) moving to a static HTML generator. I'm not close to the doc generation/writing, so I don't know too much.

Re: RAML – RESTful API modeling language

#28
>RAML was first proposed in 2013. The initial RAML specification was authored by Uri Sarid, Emiliano Lesende, Santiago Vacas, and Damian Martinez. Development is managed by the RAML Workgroup.[4]

how do you create your own "specification" and your own "workgroup"? Can anyone invent some acronym, create their own "workgroup"? Do you need some blessings from YAML or someone else?

Re: RAML – RESTful API modeling language

#29
post #4

Very cool, it feels like WSDL for REST EDIT: spelling

True REST shouldn't require a WSDL-like interface. The semantics of the graph it describes should be enough. This model, however, has yet to be fully realised; largely because of the large upfront cost in R&D. At my work, we are trying to develop in this area, but it's slow going.

Quite true, but the benefit of something like this is the ability for humans and machines to parse in one spot.

This can be both a spec and documentation at once. Client libraries can be generated and services can be stubbed.

Personally, I'd love to see something in reverse: traverse an existing restful service and produce a RAML document.

Re: RAML – RESTful API modeling language

#30

It's nice, but because of the HAML-like format, there are a lot of empty space characters included. That's great for readability, but it doesn't seem like a perfect choice for a webservice description language, since that content might get hosted and transferred often over the network for clients that might be interested in it. You could convert to binary to compress it, but that makes it harder for the client, so th…

If size is a concern, have your webserver gzip it.

https://en.wikipedia.org/wiki/HTTP_compression

Post reply on HN