Hiding routes from OpenAPI Schema Documentation #1188
Closed
DaelonSuzuka
started this conversation in
Ideas / Feature Requests
Replies: 3 comments 3 replies
-
That would indeed be a nice addition. Anybody interested in creating a pull request? |
Beta Was this translation helpful? Give feedback.
1 reply
-
This is very similar to what I was drawing attention to in #1175, though I'd like to be able to hide all of the docs (/docs, /redoc, /openapi.json). More granular control on a route-by-route basis would be great as well. |
Beta Was this translation helpful? Give feedback.
2 replies
-
With the merge of #1196, this feature is now implemented. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm working on an application that has both pages and a REST API, and I want to be able to direct other developers to the generated docs page that FastAPI makes.
Currently this page contains an entry for every
@ui.page()
decorated endpoint, which are not relevant to my target audience.It also contains endpoints for
/_nicegui/{version}/libraries/{key}
and/_nicegui/{version}/components/{key}
, which are probably not relevant for anybody's target audience.Individual pages can be hidden via
ui.page(..., include_in_schema=False)
, but this is sort of annoying because I'd have to do it for every page.I think both of these should be hidden from the API docs by default, and a new option should be added to
ui.run()
letting the user specify the desired level of documentation. Maybe something like:This is similar to how the (now removed) exclude option worked, it provides granular configurability, and can allow creating new categories in the future(not that I can imagine what those would be).
Beta Was this translation helpful? Give feedback.
All reactions