Importing Style Guide
You can now create and manage custom style guides by importing Spectral rulesets. Rulesets in Spectral format may be in YAML, JavaScript, JSON, or pre-bundled in ZIP format. During import, you are prompted to name the new style guide. You can re-import a ruleset to replace an existing one, triggering validation. This enhancement ensures centralized and efficient control over API governance. SwaggerHub CLI now supports uploading and downloading rulesets, and Spectral rulesets now support the resolved: trueconfiguration.
Importing Style Guide
To import the style guide:
Click Governance on the sidebar.
Click Import Style Guide under Organization Style Guide .
In the Import Style Guide dialog box, enter a style guide name and click to select a style guide file.
Note
You can import Spectral style guides as a
.yaml,.jsor.jsonfile or bundle them as a.zipfolder. The.zipfolder must contain a valid Spectral ruleset at the root and can reference other files and functions within the bundle.Click Import to upload the file.
The list of imported style guides appears under the Organization Style Guide.
Turn the Enable Style Guide toggle on or off next to the style guide name you want to enable or disable.
Click the Edit or Delete icon to edit or delete a style guide.
Click the Export icon to export a style guide.