
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
swagger-plugin-for-sphinx
Advanced tools
This is a handy plugin to bring Swagger and Sphinx together.
It can generate one or multiple swagger HTML pages with a custom configuration that hosts an OpenAPI specification.
Just run pip install swagger-plugin-for-sphinx
First, add the plugin to the extensions list:
extensions = ["swagger_plugin_for_sphinx"]
Swagger uses two JavaScript and one CSS file to render the output.
These can be set in conf.py
:
swagger_present_uri = ""
swagger_bundle_uri = ""
swagger_css_uri = ""
These correspond to the modules explained here. By default, the latest release is used from here.
To include a Swagger API specification into an HTML page specify the swagger-plugin
directive
and the relative path to the specification:
.. swagger-plugin:: path/to/spec.yaml
The spec is automatically copied into the _static
build output directory.
The directive supports the following options
id
: specifies an unique ID for the specification per page (see below)full-page
: if set, all other content on the page is dropped and only the Swagger part is renderedpage-title
: the name of the HTML page if full-page
is specifiedswagger-options
: JSON string that is passed to Swagger to enable additional options as described
on the configuration
page of the Swagger documentation.By default, the directive creates a <div>
element with the ID swagger-ui-container
.
If you put more than one swagger-plugin
directive in a file, specify unique IDs:
.. swagger-plugin:: path/to/one.yaml
:id: spec-one
.. swagger-plugin:: path/to/two.yaml
:id: spec-two
This project uses setuptools
as the dependency management and build tool.
To publish a new release, follow these steps:
pyproject.toml
vX.X.X
to trigger the releaseThis project is open to feature requests/suggestions, bug reports etc., via GitHub issues. Contribution and feedback are encouraged and always welcome. For more information about how to contribute, the project structure, as well as additional contribution information, see our Contribution Guidelines.
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone. By participating in this project, you agree to abide by its Code of Conduct at all times.
Copyright 2025 SAP SE or an SAP affiliate company and swagger-plugin-for-sphinx contributors. Please see our LICENSE for copyright and license information. Detailed information including third-party components and their licensing/copyright information is available via the REUSE tool.
FAQs
Sphinx plugin which renders a OpenAPI specification with Swagger
We found that swagger-plugin-for-sphinx demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.