I have been asked to implement HATEOAS as part of our rest API and this is how the response is defined in Swagger specs
_links:
[
{
rel:
string
The relationship to the request e.g. self which contains the resource that was requested or {object name}, a link to a resource that is related to the requested resource
action:
[
{
httpVerb:
string
Allowed actions for this link based on the users permissions
Enum:
Array[4]
0:"GET"
1:"POST"
2:"PUT"
3:"DELETE"
}
]
href:
string
A fully qualified URL to the resource.
}
]
rel and href make sense and I could find many examples for these two but I could not find anything for actions. Is it part of the standard? Should I really send it back?
I am using Spring hateoas library and that for sure does not support actions. Any guidance on this will be appreciable.
Thanks.