I'm trying to use Dingo API to implement RESTful backend APIs for our webapp. Best practices say that response payload should contain links
to the returned resource objects. It can be in the form of _link
or href
. I don't see a way to include this in the response without handcrafting resource URL. I would like to have the response something like...
[
{
'person': "Joe",
'_link': 'http://ift.tt/1U7xa9S'
},
{
'person': "Pat",
'_link': 'http://ift.tt/1smJjBo'
}
]
Is there a way I can include a resource link in the response?
from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1U7xsgX
via IFTTT
Aucun commentaire:
Enregistrer un commentaire