Closed tijn closed 2 years ago
well JSON:API 1.1 is not fully supported by our library, does it?
well JSON:API 1.1 is not fully supported by our library, does it?
@auvipy oh, I put the wrong link there, I meant this one: https://jsonapi.org/format/#document-structure . A document is nothing new.
What Changed & Why
In JSON:API the server responds with data structure called a document. Devour-client will process it for us; it combines attributes and relationships etc. to obtain resources that are very easy to handle. However Devour will omit certain things in the deserialisation process. URLs in relationships for example. In most cases you don't need these, but if you do, there's really no way to obtain them and you're stuck.
This PR exposes the whole document as it was returned by the server to allow for a way around the deserialisation process.