-
Notifications
You must be signed in to change notification settings - Fork 9.1k
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
$ref value must be accessible URL for external reference? #1887
Comments
|
I removed my comment, I had the same thought there is no contradiction but I overthought it. |
Is it accurate to say that URI must be addressable? |
@Shulamite there are no restrictions on the value of |
Some sorts of URI will also no doubt have much better tooling support. |
@darrelmiller @webron @tedepstein I think we touched on this related to #2092. There is a valid reading of JSON Reference that requires the value of So I think this should be closed as answered in 3.0 and fixed in 3.1? Or maybe tracked under #2099 if we think we need to explain this further in OAS 3.1 and can't just fold it into #2092. |
I vote for "fixed in v3.1" and close this. |
@Shulamite for OAS 3.0.x, the relevant language from the JSON Reference draft is (bolding added):
Per discussion with @darrelmiller in a recent TSC meeting, that is interpreted to require a URL, not just a URI. So OAS 3.0.x does not allow non-URL URIs, and therefore doesn't need to explain how one might resolve them. In OAS 3.1 that draft is no longer referenced, and we are tracking the implications of that through #2099 and related issues. |
Based on JSON reference spec, the $ref value is an URI, which by definition is a resource identifier only, and is independent of access.
It seems it is valid to use a well formed URI, but not an accessible URL (assuming http).
However, if it is not a valid URL for external reference, how would different tools resolve the references?
The text was updated successfully, but these errors were encountered: