DITA Bootstrap Swagger is a DITA Open Toolkit plug-in that extends HTML output. It renders each Swagger operation as a collapsed Bootstrap accordion item, matching
petstore.swagger.io's own collapsed-by-default endpoint list, when building with
DITA Bootstrap's html5-bootstrap transtype.
The DITA Bootstrap Swagger plug-in has been tested with DITA-OT 4.x. Use the latest version for best results.
-
Download the latest distribution package from the project website at dita-ot.org/download.
-
Extract the contents of the package to the directory where you want to install DITA-OT.
-
Optional: Add the absolute path for the
bindirectory to the PATH system variable.This defines the necessary environment variable to run the
ditacommand from the command line.
See the DITA-OT documentation for detailed installation instructions.
- Run the plug-in installation commands:
dita install fox.jason.extend.css
dita install org.dita-bootstrap.html
dita install fox.jason.passthrough.swagger
dita install org.dita-bootstrap.swaggerSpecify the html5-bootstrap format when building output with the dita command, same as any other
html5-bootstrap build - no extra parameters are needed:
dita --input=path/to/your.ditamap \
--format=html5-bootstrapApache 2.0 © 2026 Jason Fox
Note
The sample documentation is rendered from the Swagger Petstore example API definition, which is published by the Swagger API project under the Apache 2.0 license.
