An OpenAPI 3.1 specification for the Ravelry API, generated from the official HTML documentation.
go install github.com/cxd309/simple-file-server@latestSetup the Python environment with uv:
uv syncParse api_documentation.html and write docs/openapi.json:
make generateBrowse the spec locally, emulating the GitHub Pages URL structure:
make serve
# -> http://localhost:8081/ravelry-openapi-specification/swagger.html
# -> http://localhost:8081/ravelry-openapi-specification/redoc.htmlapi_documentation.html # source: Ravelry API HTML docs
main.py # entry point
ravelry/
parser.py # HTML -> structured data
generator.py # structured data -> OpenAPI 3.1 spec
docs/
openapi.json # generated output
swagger.html # Swagger UI
redoc.html # ReDoc