Installations
npm install swagger-markdown
Developer Guide
Typescript
Yes
Module System
CommonJS
Node Version
18.17.1
NPM Version
10.8.0
Score
57.5
Supply Chain
92.3
Quality
76.8
Maintenance
100
Vulnerability
99.6
License
Releases
Contributors
Languages
TypeScript (96.4%)
JavaScript (3.41%)
Shell (0.19%)
Developer
syroegkin
Download Statistics
Total Downloads
745,464
Last Day
123
Last Week
1,841
Last Month
10,194
Last Year
138,259
GitHub Statistics
244 Stars
510 Commits
87 Forks
5 Watching
3 Branches
13 Contributors
Package Meta Information
Latest Version
2.3.2
Package Id
swagger-markdown@2.3.2
Unpacked Size
84.91 kB
Size
21.52 kB
File Count
65
NPM Version
10.8.0
Node Version
18.17.1
Publised On
26 May 2024
Total Downloads
Cumulative downloads
Total Downloads
745,464
Last day
-78.6%
123
Compared to previous day
Last week
-34.4%
1,841
Compared to previous week
Last month
-13.7%
10,194
Compared to previous month
Last year
0.3%
138,259
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dev Dependencies
29
swagger-markdown
CLI script to turn swagger yaml into markdown files. Supports swagger 2.0 format only
The version 2.0 is a breaking change. The project was rewritten in typescript.
Along with addressing multiple issues, it is more strict now with the openapi version.
In case if version 3 is provided, the application will throw an error.
The support of v3 is at the roadmap, although it is possible to overcome this restriction by using --force-version flag: --force-version 2
. It will process v3 documents as it is v2, although it may fail and it may generate the markdown with errors.
As soon as v3 support will be added, the flag will be removed.
see examples folder
Installation
1npm install -g swagger-markdown
Usage
swagger-markdown [-h] [-v] -i [-o] [--skip-info]
Options:
-h, --help Show this help message and exit.
-v, --version Show program's version number and exit.
-i , --input Path to the swagger yaml file
-o , --output Path to the resulting md file
--skip-info Skip the title, description, version etc, whatever is in the info block.
--force-version Set the document version, ignore version provided in the yaml file
Npx (requires no installation)
1npx swagger-markdown -i ./basic-auth.yaml
Example
1swagger-markdown -i path/to/swagger/file.yaml
By default it will create the new file within the same directory with the same name as swagger file but with .md extension.
So, if swagger file is placed in project/api-doc/swagger.yaml
the new file will be created as project/api-doc/swagger.md
You can also use it as a npm script in your package.json:
1npm i --save-dev swagger-markdown
1{ 2 "scripts": { 3 "md-docs": "swagger-markdown -i path/to/swagger.yaml", 4 //... 5 } 6}
1npm run md-docs
Related
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
3 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36
Reason
SAST tool is not run on all commits -- score normalized to 6
Details
- Warn: 18 commits out of 28 are checked with a SAST tool
Reason
Found 0/8 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Score
3.6
/10
Last Scanned on 2024-12-16
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More