Reputation: 2883
I'm using RAML to document my REST API. In the RAML doc, I specify the base URL at the root-level
baseUri: http://api.example.org/api/{version}
version: v1
Then in the API endpoints section of the doc, I specify their URL relative to this base, e.g.
/foo/bar:
get:
description: blah blah blah
When I run raml2html
to generate a HTML page from the RAML doc, the relative URL /foo/bar
is shown in the docs for the API endpoint, but I would prefer to show the absolute URL http://api.example.org/api/v1/foo/bar
instead, is this possible?
Upvotes: 1
Views: 481
Reputation: 33413
raml2html
allows using custom templates for the overall documentation wrapper, each resources and each items.
In your case you want to customize the resource template and then use it with the -r custom-resource.handlebars
parameter.
Upvotes: 2