Add @id if the objet is a Hypermedia::Resource