Skip to content

Instantly share code, notes, and snippets.

@superstructor
Last active December 18, 2015 08:29
Show Gist options
  • Save superstructor/5754903 to your computer and use it in GitHub Desktop.
Save superstructor/5754903 to your computer and use it in GitHub Desktop.
"/rels/delete" could tell the client "this is the link to follow to delete the context resource", whereas "/profiles/delete" could tell the client that to do so you DELETE /api/customer/42 ? Since there is no entity body the generic /profiles/delete provides enough semantics for any resource i.e. just use the DELETE method. "/rels/update-form" c…
{
"_links": {
"self": {
"href": "/api/customers/42"
},
"profile": {
"href": "/profiles/customer"
},
"/rels/delete": {
"href": "/api/customers/42",
"profile": "/profiles/delete"
},
"/rels/update": {
"href": "/api/customers/42",
"profile": "/profiles/customer/update"
},
"/rels/update-form": {
"href": "/forms/customer/update",
"profile": "/profiles/form"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment