From 8f8adde231cd9dbb345bbc801a453105a1b0d677 Mon Sep 17 00:00:00 2001 From: Vignesh Rao Date: Sun, 5 Jan 2025 18:37:45 -0600 Subject: [PATCH] Dynamically generate the API description for SwaggerUI --- doc_gen/index.rst | 7 ++- docs/README.html | 2 +- docs/_sources/index.rst.txt | 7 ++- docs/genindex.html | 40 ++++++++++++---- docs/index.html | 86 +++++++++++++++++++++++++++++++---- docs/objects.inv | Bin 2332 -> 2426 bytes docs/searchindex.js | 2 +- pyninja/executors/routers.py | 2 +- pyninja/main.py | 83 +++++++++++++++++++-------------- pyninja/modules/enums.py | 14 +++++- pyninja/modules/models.py | 18 ++++++++ 11 files changed, 202 insertions(+), 59 deletions(-) diff --git a/doc_gen/index.rst b/doc_gen/index.rst index e04e776..405a87a 100644 --- a/doc_gen/index.rst +++ b/doc_gen/index.rst @@ -93,6 +93,11 @@ Exceptions Models ------ +.. autoclass:: pyninja.modules.models.RoutingHandler(BaseModel) + :exclude-members: _abc_impl, model_config, model_fields, model_computed_fields + +==== + .. autoclass:: pyninja.modules.models.ServiceStatus(BaseModel) :exclude-members: _abc_impl, model_config, model_fields, model_computed_fields @@ -124,7 +129,7 @@ Models ==== .. automodule:: pyninja.modules.models - :exclude-members: ServiceStatus, Architecture, Session, WSSession, RateLimit, EnvConfig, session, ws_session, env, database, architecture + :exclude-members: RoutingHandler, ServiceStatus, Architecture, Session, WSSession, RateLimit, EnvConfig, session, ws_session, env, database, architecture Payloads -------- diff --git a/docs/README.html b/docs/README.html index b30b427..7910e68 100644 --- a/docs/README.html +++ b/docs/README.html @@ -4,7 +4,7 @@ - + PyNinja — PyNinja documentation diff --git a/docs/_sources/index.rst.txt b/docs/_sources/index.rst.txt index e04e776..405a87a 100644 --- a/docs/_sources/index.rst.txt +++ b/docs/_sources/index.rst.txt @@ -93,6 +93,11 @@ Exceptions Models ------ +.. autoclass:: pyninja.modules.models.RoutingHandler(BaseModel) + :exclude-members: _abc_impl, model_config, model_fields, model_computed_fields + +==== + .. autoclass:: pyninja.modules.models.ServiceStatus(BaseModel) :exclude-members: _abc_impl, model_config, model_fields, model_computed_fields @@ -124,7 +129,7 @@ Models ==== .. automodule:: pyninja.modules.models - :exclude-members: ServiceStatus, Architecture, Session, WSSession, RateLimit, EnvConfig, session, ws_session, env, database, architecture + :exclude-members: RoutingHandler, ServiceStatus, Architecture, Session, WSSession, RateLimit, EnvConfig, session, ws_session, env, database, architecture Payloads -------- diff --git a/docs/genindex.html b/docs/genindex.html index 2ed9616..369935e 100644 --- a/docs/genindex.html +++ b/docs/genindex.html @@ -75,10 +75,14 @@

A

  • APIEndpoints (class in pyninja.modules.enums)
  • apikey (pyninja.modules.models.EnvConfig attribute) +
  • +
  • APIResponse