In this blog we are going to learn about the URL parameter used in RAML(Restfull api modelling language).
A Uniform Resource Identifier (URI), as the name suggests, is responsible for identifying a resource uniquely. For example, we can use it to search for Video based on the song ID – /video/{videoId}:
/video:
/{videoId}:
get:
description: To get all the video based in the video-box
displayName: Get all video.
responses:
200:
body:
application/json:
example: {
"1": "Chalo chle",
"2": "See You Again (feat. Charlie
Puth) Wiz Khalifa",
"3": "Maan Mere jaan",
"4": "King- Tu Aake dekhle"
}
This is what an actual request would look like: http://<host>/video/234.
So here, /{videoId} is the URI parameter to fetch a particular song from the records.
Comments
Post a Comment
Please Write your comment here.