Returning created/updated resources to clients after editing requests
Issue
JSON:API allows for servers to respond to successful editing requests with 204 - No Content
, indicating to the client that the desired request was successfully processed but without returning any payload in the response.
This may be a problem in some situations as changes may occur to the resource in an unexpected way to the client. Example, when creating a resource, the client does not provide metadata, links, ID, or fields that should be assigned as null. Also, in updates that do not cause real changes do the resource's "lastUpdate" field isn't changed.
Proposal
Require from servers to not use the 204 - No Content
response and always return the resulting resource to the client. This should improve the trust of clients on servers and we would remain aligned with the "never be silent about possible unexpected behavior" we have been adopting so far.