Let's say we have a RESTful API method:
POST /people
{
"name" : "John",
"_links" : {
"address" : {
"href" : "/addresses/2"
}
}
}
You can see that address
has a link to another resource.
To resolve the address_id
of that resource, should the server:
Break up the URL and identify the "id" part of the route
Even make a curl request to itself, in order to get the
address_id
of that linked resource?