wekan/openapi
Benjamin Tissoires 39f8a138d7 openapi: rework the allowedValues to allow for imported variables
Previously I was assuming all variables were declared in the same file.
Turns out that imports exists too, and we need to recurse one more time
in those imports./

Also "clean" up a bit the function to do the parsing in 2 steps:
- first find out the actual matching node in js
- then convert it based on its type
rinse wash repeat.

Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
2021-04-14 11:32:03 +02:00
..
generate_openapi.py openapi: rework the allowedValues to allow for imported variables 2021-04-14 11:32:03 +02:00
README.md - More whitelabeling. 2019-03-21 20:27:21 +02:00

OpenAPI tools and doc generation

Open API generation

This folder contains a script (generate_openapi.py) that extracts the REST API of Wekan and exports it under the OpenAPI 2.0 specification (Swagger 2.0).

dependencies

calling the tool

python3 generate_openapi.py --release v1.65 > ../public/wekan_api.yml

Generating docs

Now that we have the OpenAPI, it's easy enough to convert the YAML file into some nice Markdown with shins and api2html, or even ReDoc:

api2html -c ../public/logo-header.png -o api.html ../public/wekan_api.yml

or

redoc-cli serve ../public/wekan_api.yml