What is this model?
It is a model created by Leonard Richardson that breaks the elements of a REST API on 3 levels. So for you to achieve the "real" REST you would have to reach level 3.
It is related to Apis REST only?
Yes
We must try to reach the highest level of maturity ever?
You must do what makes sense for your application. For this I will give a brief explanation of each level.
Level 0: HTTP
You use HTTP as a form of communication without any criteria for using verbs, or routes.
Level 1: HTTP + Resources
Your API is exposed (routed) by following the resource model. Like /users/ to list all users and /users/123/ to get a specific user.
Level 2: HTTP + Resources + Verbs
HTTP verbs are used semantically in your API. GET to read, POST to insert, PUT to replace a record, DELETE to delete...
Level 3: HTTP + Resources + Verbs + HATEOAS
Your API should return a list of resources (routes) with everything you can do from the original call.
GET /products/123
{
"id": 123,
"name": "Orange"
"links": [
{"rel": "Suppliers", "href": "/suppliers/?product=123"}
]
}
What does that mean HATEOAS? It’s an acronym?
– Costamilam
HATEOAS means "Hypertext as the engine of application state" -- See this other link in Stackoverflow for more information -- https://answall.com/questions/49492/por-que-hateoas-%C3%A9-important
– siga0984