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

Consolidated $ref-to-Some Object feature request #3853

Open
handrews opened this issue May 24, 2024 · 1 comment
Open

Consolidated $ref-to-Some Object feature request #3853

handrews opened this issue May 24, 2024 · 1 comment
Labels
re-use: ref-everywhere Requests to support referencing in more / all places
Milestone

Comments

@handrews
Copy link
Member

handrews commented May 24, 2024

This issure consolidates and replaces the numerous "can the OAS allow $ref for..." issues:

@handrews
Copy link
Member Author

handrews commented Nov 21, 2024

It's worth noting that all of these are at least a bit more complex than they initially seem:

  • Tag Objects are in an array, and JSON Pointer fragments to an array are confusing and fragile
  • Security Requirement Objects involve an unusual lookup to Security Scheme Objects (although see Use URI references for Security Requirements in 3.2 #3776)
  • Server Objects are looked up based on their parent Object – I think that wouldn't be too much of a problem because you'd look up based on the $ref source and not on the actual location of the Server Object, but that would be a new complication to resolving things
  • Operation Objects require context from parent Path Item and Paths Objects to function, which is already a problem for Link Objects (see Link Object: require referencing operation with unambiguous path template #4084 for more information)
  • Media Type Objects require the media type from the parent field - while it is possible that the same Media Type Object could be used for different Media Types, this pattern would be a bit unusual and would require some thought
  • It's not all that clear to me how $ref for Contact and License would be used. If we just want to avoid having to repeat these objects in each document in a multi-document OAD, I'd probably rather just relax the requirement that they be present in non-entry documents

@handrews handrews modified the milestones: v3.2.0, v3.3.0 Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
re-use: ref-everywhere Requests to support referencing in more / all places
Projects
None yet
Development

No branches or pull requests

2 participants