Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@forfuture/apidoc-openapi
Advanced tools
Generate OpenAPI definition file from apiDoc comments in your source code.
$ npm install @forfuture/apidoc-openapi
It is important to note that this tool supports any programming language that apiDoc supports. However, we shall use JavaScript in our documentation.
The tool expects a certain style of writing your apiDoc comments. For example,
/**
* @api {put} /users/:userId Update user
* @apiName UpdateUser
* @apiGroup Users
* @apiDescription Update user's information
*
* @apiParam {String} userId User's unique ID
* @apiParam {String} [firstName] User's first name
* @apiParam {String} [lastName] User's last name
*
* @apiSuccess (200) {Object} data Data object
* @apiSuccess (200) {Boolean} data.ok Set to `true` always
*/
@apiName
)@apiGroup
)@apiDescription
)@apiSuccess
) in the
responses group.(200)
You operate the tool from your command-line. For example (in BASH),
$ apidoc-openapi --help
Usage: apidoc-openapi [options]
Options:
-V, --version output the version number
-p, --project <path> path to apidoc config file
-s, --src <path> path to source files
-o, --out <path> path to output file
-v, --verbose be verbose
-h, --help output usage information
To generate an OpenAPI definition file:
$ apidoc-openapi --project ./apidoc.json --src src/ --out ./openapi.json
The MIT License (MIT)
Copyright (c) 2018 Forfuture LLC <we@forfuture.co.ke>
FAQs
Generate OpenAPI definition file from apiDoc comments
The npm package @forfuture/apidoc-openapi receives a total of 55 weekly downloads. As such, @forfuture/apidoc-openapi popularity was classified as not popular.
We found that @forfuture/apidoc-openapi demonstrated a not healthy version release cadence and project activity because the last version was released 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
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.