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

Define "primary key" for objects #587

Open
ralfhandl opened this issue Mar 1, 2016 · 5 comments
Open

Define "primary key" for objects #587

ralfhandl opened this issue Mar 1, 2016 · 5 comments

Comments

@ralfhandl
Copy link
Contributor

OData APIs are based on an entity-relationship model, so the top-level resources are collections of identically structured objects, and there's a subset of properties whose values uniquely identify an object (think: records in a database table).

A similar issue has been addressed in the JSON Schema discussion group, see https://groups.google.com/d/msg/json-schema/CYd8xk1Czyg/XLNxEzDOPj4J

We currently solve this with an extension keyword "x-keys" whose value is an array of strings listing the names of the "primary key" properties.

Anyone else seeing a need for this and wanting to have it in OpenAPI.Next?

@webron
Copy link
Member

webron commented Jul 21, 2016

Tackling PR: #741

@avkonst
Copy link

avkonst commented May 22, 2017

Yes, I do the same with x-keys. Would be good to have standardized to just "keys"

@ePaul
Copy link
Contributor

ePaul commented May 29, 2017

#741 (or #894) did not contain anything for this issue.

@webron
Copy link
Member

webron commented May 31, 2017

Yup, not everything was resolved in #741, and this is why this ticket was not closed.

@demonking
Copy link

@ralfhandl something new there? or should we use an extension ?

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

No branches or pull requests

6 participants