-
Notifications
You must be signed in to change notification settings - Fork 890
Relationships object #625
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
Relationships object #625
Conversation
…e from resource `"links"`
Now that we have a consistent `links` format everywhere, which is always optional, this object seemed analogous to the `meta` object, so I restructured its section to better match the structure of the “Meta Information” section.
The name of the relationship declared in the key **SHALL NOT** be `"self"`. | ||
Relationships may be to-one or to-many. Relationships can be specified by | ||
including a member in a resource's relationship's object. The name of the | ||
relationship is its key in the the relationship object. | ||
|
||
The value of a relationship **MUST** be one of the following: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dgeb @tkellen How would you guys feel now about getting rid of the "name": "related resource url"
representation of a relationship? There was an argument for removing it before, and I think that argument's much stronger now, as this would be the only instance in the spec of a URL occuring outside of a "links"
object.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ethanresnick I agree that representation should be removed from this proposal, since it no longer merges the concept of links and relationships.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
b7aefca
to
d781618
Compare
@ethanresnick thanks for all your hard work on this! @tkellen and I will review and discuss first thing tomorrow. |
@dgeb Sounds good! |
Late night 👍 on this. Excited to take a more considered look tomorrow AM. Thanks for proposing this @ethanresnick! |
Thanks for the proofreading, @hhware! Much appreciated! |
9b9e6db
to
cecf671
Compare
@ethanresnick at this point, @tkellen and I think that |
To expand on that thought - it establishes |
@ethanresnick sounds great - thanks in advance! |
@ethanresnick I'm going to rebase and merge this along with the |
Rebased and merged (see https://github.com/json-api/json-api/commits/gh-pages). I'll open a separate PR for the |
Thanks @dgeb! Sounds good, and sorry I wasn't able to open that last night. |
I'll have a PR in shortly with some minor revisions for cleanup/clarity and then I'm out for the day. |
A PR for #618. See the inline comments for some new issues that arose while I was creating it.