Comments (4)
I agree that a relative path is valid.
Relative references are resolved using the URLs defined in the Server Object as a Base URI.
I wonder should your url be: "/API/flows/NewCustomer-Flow.html" and can you confirm whatever your server(s) is that your {server url}/API/flows/NewCustomer-Flow.html
exists?
from redocly-cli.
No it actually doesn't exist at the server URL.
Currently there is a disparity between the official spec for OpenAPI3 and how both Redoc2 and Swagger UI render it. The spec says a relative URL should be relative to the servers in the server list. But, at least for the externalDocs:
both swagger UI and redoc2 use the URL of the web page embedding the openapi3 viewer as the root (which in my opinion makes more sense). And that's how i am using it in this case.
So if my show_openapi.html
is at my-domain.com/api/show_openapi.html
./API/flows/file.html
becomes: my-domain.com/api/API/flows/file.html
and
/API/flows/file.html
becomes: my-domain.com/API/flows/file.html
Neither of which is according to the OpenAPI3 spec, but it is sensible.
Links inside markdown descriptions work the same way.
from redocly-cli.
@stevenj , thank you for using openapi-cli
. As for now, you can disable the urls validation for the externalDocs using the .redocly.yaml
config similar to following:
# apiDefinitions:
# ...
lint:
# ...
rules:
# ...
oas3-schema/external-docs:
url: off
# ...
And we will update the validation rules to support the relative links in relativeDocs & license url's fields.
from redocly-cli.
Thank you for the workaround, works as expected.
from redocly-cli.
Related Issues (20)
- $ref replaces object on bundle, 3.1.0 spec not working when using siblings HOT 1
- redocly bundle with a reference to a JSON schema root object produces invalid OpenAPI spec HOT 2
- Detect properties with no type defined HOT 5
- Support SARIF as output for redocly lint command.
- Example validation is not done against the schema HOT 7
- bundle command converts floating point numbers to integers HOT 1
- Self-referencing circular pointer HOT 2
- Allow specifying an overwrite conflict strategy for the `join` command HOT 1
- Add docs for Arazzo linting
- Linting does not catch default value types not conforming to specified field type HOT 2
- Translations and eject command wrapper
- Using curl instead of the cli interface HOT 2
- Add `boolean-schema-prefixes` (analogue to `boolean-parameter-prefixes`) rule to schema/model validation HOT 2
- root level paths `/` are not split correctly HOT 1
- Suppress update now logging HOT 1
- Pattern properties casing triggers error after upgrade, possible regression with 1.18.1 release HOT 1
- [OAS 3 spec] License object `identifier` and `url` keys are mutually-exclusive HOT 6
- Cannot find module './types/arazzo' HOT 6
- Remove all usages of component marked x-internal HOT 5
- hideRightPanel configuration does not have any effect
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from redocly-cli.