Overlays in RAML | Overlays in Mule 4
An overlay is used to extend non-behavioural aspects of an API, such as descriptions, usage directions, and user documentation items. If we have an API working for different countries and we need to do documentation in multiple languages then overlays can be used.
Overlays in RAML is widely used concept in RAML 1.0 in Mule 4. In the example below we will see how we can implement overlays in our RAML.
Here is the overlays.raml which is used to documentation in multiple languages.
#%RAML 1.0 Overlay
title: API documentation in multiple languages
extends: documentation.raml
documentation:
- title: Introducción
content: El acceso automatizado a los libros
- title: Licencias
content: Por favor respeta los derechos de autor de los libros
Here is documentation.raml.
#%RAML 1.0 DocumentationItem
title: User details
content: The API performs CRUD operations about user details
No comments:
Post a Comment