Skip to content

Commit cb3fe40

Browse files
Add OpenAPI spec file to docs to show REST API
1 parent bd5be17 commit cb3fe40

File tree

4 files changed

+12
-1
lines changed

4 files changed

+12
-1
lines changed

docs/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,6 @@ myst-parser
22
sphinx-autobuild
33
sphinx-book-theme
44
sphinx-copybutton
5+
sphinxcontrib-openapi
56
sphinxext-opengraph
67
sphinxext-rediraffe

docs/source/api.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
.. _api:
2+
3+
=============
4+
REST API
5+
=============
6+
7+
.. openapi:: ../../jupyter_server_proxy/api.yml
8+
:examples:

docs/source/conf.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,10 @@
2323
"sphinx_copybutton",
2424
"sphinxext.opengraph",
2525
"sphinxext.rediraffe",
26+
"sphinxcontrib.openapi",
2627
]
2728
root_doc = "index"
28-
source_suffix = [".md"]
29+
source_suffix = [".md", ".rst"]
2930
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
3031

3132

docs/source/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ install
3030
server-process
3131
launchers
3232
arbitrary-ports-hosts
33+
api
3334
```
3435

3536
## Convenience packages for popular applications

0 commit comments

Comments
 (0)