Skip to content

Instantly share code, notes, and snippets.

@apotonick
Last active November 26, 2015 06:10
Show Gist options
  • Save apotonick/728e7373306c72e4de19 to your computer and use it in GitHub Desktop.
Save apotonick/728e7373306c72e4de19 to your computer and use it in GitHub Desktop.
HAL collection document
{"_embedded"=>
{"things"=>
[{"name"=>"TRB",
"id"=>3,
"_embedded"=>
{"authors"=>
[{"email"=>"rob@trb.to",
"id"=>3,
"_links"=>{"self"=>{"href"=>"/api/users/3"}}}]},
"_links"=>{"self"=>{"href"=>"/api/things/3"}}},
{"name"=>"Rails",
"id"=>2,
"_embedded"=>
{"authors"=>
[{"email"=>"dhh@trb.to",
"id"=>2,
"_links"=>{"self"=>{"href"=>"/api/users/2"}}}]},
"_links"=>{"self"=>{"href"=>"/api/things/2"}}},
{"name"=>"Lotus",
"id"=>1,
"_embedded"=>
{"authors"=>
[{"email"=>"jacob@trb.to",
"id"=>1,
"_links"=>{"self"=>{"href"=>"/api/users/1"}}}]},
"_links"=>{"self"=>{"href"=>"/api/things/1"}}}]},
"_links"=>{"self"=>{"href"=>"/things"}}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment