Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for partial inclusion of relationships #177

Open
caiotoon opened this issue Jul 29, 2019 · 0 comments
Open

Support for partial inclusion of relationships #177

caiotoon opened this issue Jul 29, 2019 · 0 comments

Comments

@caiotoon
Copy link

JSON:API has support for optional inclusion of related objects.

The specification states that in case the request has an explicit include directive, it MUST NOT include unrequested entities.

If an endpoint supports the include parameter and a client supplies it, the server MUST NOT include unrequested resource objects in the included section of the compound document.

The problem is that calling MarshalPayload will include all related items, whereas MarshalPayloadWithoutIncluded includes none.

It does not seem to be possible to support this use case with the current version of the library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant