Questions tagged [raml]

RESTful API Modeling Language (RAML)

RESTful API Modeling Language (RAML, http://raml.org/) is a simple and succinct way of describing practically-RESTful APIs. It encourages reuse, enables discovery and pattern-sharing, and aims for merit-based emergence of best practices. The goal is to help our current API ecosystem by solving immediate problems and then encourage ever-better API patterns. RAML is built on broadly-used standards such as YAML and JSON and is a non-proprietary, vendor-neutral open spec.

RESTful API Modeling Language (RAML) makes it easy to manage the whole API lifecycle from design to sharing. It's concise - you only write what you need to define - and reusable. It is machine readable API design that is actually human friendly.

369 questions
3
votes
1 answer

RAML resourceTypes and traits VS Swagger $ref

I really like how RAML focuses on reducing the amount of duplication and increasing consistency across APIs with the use of ResourceTypes and Traits. But after taking a closer look at the Swagger spec, it appears that you can accomplish the same…
Johnny Z
  • 14,329
  • 4
  • 28
  • 35
3
votes
2 answers

Cannot POST to Mule console mock service

I have enabled mule mock service via the API console. My get requests work fine, but not POST - gives 404; I'm testing through the 'try it' console, so the API def. exists: Response Request…
Gilbert
  • 3,584
  • 2
  • 26
  • 30
3
votes
1 answer

Generating API documentation from Java Cloud Endpoint

I'm looking for an efficient way to generate API documentation in a readable format, from the generated files from Cloud Endpoint (Java). The generated files are either: - my_api.api - my_api*.discovery Something that looks like this: -…
3
votes
1 answer

RAML: Referencing uriParameters in resources

I'm writing an API spec in RAML, and was wondering if it was possible to reference uri parameters in order to create dynamic mime types. Something along the lines of baseUri: http://api.mycompany.com/{version} /first_resource: get: …
Matt
  • 33
  • 4
2
votes
0 answers

Is it possible define an XML element in RAML 1.0 which has both text content and attributes?

Is it possible define an XML element in RAML which has both text content and attributes? For example: Here is some text From what I can tell, objects cannot have text content, and strings cannot have…
James Daily
  • 587
  • 6
  • 21
2
votes
1 answer

RAML override required field or

I'd like to change the required field for a type that I am inheriting in another type. Is it possible to override that value or abstract it somehow? In the example below, I'd like to override the required field for Passenger.firstName: Description:…
Shah Syed
  • 57
  • 7
2
votes
0 answers

Encrypted data types in RAML

Am trying to define an API spec, that is expecting the post body to be signed and encrypted. Is there any way we can define this in RAML? Security schemes etc allow you to define authN/authZ etc but not sure how to indicate that the data itself…
vgkris
  • 21
  • 2
2
votes
0 answers

Refactoring common code in responses section

I have some common RAML code that comes up in the responses section: /foo post: responses: 400: common_stuff 401: common_stuff I'd like to refactor this with traits, but I run into…
Matthew Cline
  • 2,312
  • 1
  • 19
  • 36
2
votes
1 answer

What is the default for the "required" property in RAML 1.0?

I'm defining entities in RAML 1.0, and I feel that it's wasteful that the required attribute must be defined for each item if we want to make sure that it's (non-)optional. Is there a default value for this, and if so, which?
JoseHdez_2
  • 4,040
  • 6
  • 27
  • 44
2
votes
1 answer

Validation of RAML file

suppose that we have some Swagger 2.0 document, e.g. http://petstore.swagger.io/v2/swagger.json I am trying to convert it to another formats using Apimatic. https://apimatic.io/transformer If I convert the Petstore Swagger document to WADL, the…
Cimlman
  • 3,404
  • 5
  • 25
  • 35
2
votes
2 answers

Make some of the query parameters dependent in RAML

I am writing an api spec with RAML. I have a GET api with three query parameters. One of them is optional. In the case of other two, one of them should be present at least. How do I define this in the api spec /api description: api end…
user12331
  • 486
  • 7
  • 22
2
votes
1 answer

Generate JSON body from RAML file

I am testing REST APIs with Ready! API tool and the documentation that I have received is the raml files with the REST APIs definitions. The RAML plugin of Ready! API works fine but the raml files don't include any example of the JSON bodies. There…
agv14
  • 43
  • 4
2
votes
1 answer

node module raml2html returning empty braces

I am using raml2http node package to convert my raml document to html document. Installed raml2http gloabally using npm install -g raml2html Command to convert raml to html raml2html -i [input file path] -o [output file path] result - Empty…
Tanay Mathur
  • 379
  • 2
  • 5
  • 16
2
votes
2 answers

How to deploy RAML API's to Mule standalone

I have created an API using RAML and I have been able to expose it as a Web site on my local Windows laptop. However, now I need to install Mule standalone on a server an install it there. The tutorial provided for this starts with downloading an…
fificito
  • 69
  • 1
  • 7
2
votes
1 answer

JSON schema reference ($ref) not expanded when using raml2html

I'm using raml2html to generate HTML pages from JSON schemas. But the schema reference ($ref) used in my JSON schema is not expanded as expected and I'm not sure why. I've followed instructions from raml-jsonschema-expander, the tool used by…
Jianxin Gao
  • 2,717
  • 2
  • 19
  • 32