openapi-to-skills
Convert an OpenAPI specification into a skill folder with SKILL.md and API references.
Workflow
-
Determine the spec source and output directory from the request. Input must be OpenAPI 3.x in JSON or YAML; convert Swagger 2.0 first.
-
Read the relevant sections of references/cli.md to choose options:
- Options for naming, grouping, and filtering.
- Compact Layout for resource pages that consolidate list-call details.
- Overlays to modify the spec before generation.
- Validator to include an offline input checker.
- Case-Insensitive Filesystem Safety for schemas whose names differ only in case.
- Static Assets and External References when preserving hand-authored files or bundling external
$refs.
-
Run the CLI with the selected options:
bashnpx openapi-to-skills <spec-path-or-url> -o <output-dir>Use
--forcewhen replacing existing generated output is intended: it deletes and recreates the skill directory. Keep hand-authored content in an external--assetsdirectory so it can be reapplied. -
Inspect
<output-dir>/<skill-name>/SKILL.mdand its linked references. Check that the intended operations are present and filters took effect; the file layout depends on the selected layout.
Maintenance
Keep CLI options and behavior documented in references/cli.md. README links to this skill and reference rather than maintaining another options table.


