Socket
Book a DemoInstallSign in
Socket

joi-openapi-generator

Package Overview
Dependencies
Maintainers
2
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

joi-openapi-generator

Generate OpenAPI specification from koa-joi-router

1.3.1
latest
npmnpm
Version published
Weekly downloads
0
Maintainers
2
Weekly downloads
 
Created
Source

OpenAPI generator

This is a tool for generating OpenAPI schemas from koa-joi-router definitions. It is compatible with joi 17.x.x.

Usage

You can create koa-joi-router as usual and provide some metadata in route definitions.

Router meta options:

  • name: string - name of the route (will be used as operationId)
  • group?: string
  • version
  • tags
    • assigned tags to the route can be matched during the build
    • tags with prefix openapi- will be included in tags property in the operation object
    • reserved tags: ignore-route

Moreover you can provide some meta options in Joi validation schemas.

Joi meta options:

  • name: string - when set the type will be extracted and exported with this name
  • deprecated: boolean

Generator also supports many Joi native features, such as examples, description, key presence or various flags.

FAQs

Package last updated on 06 Apr 2023

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.