json-to-oas-component-cli
Command line tool for json-to-oas-component
Last updated 2 years ago by mheap .
MIT · Original npm · Tarball · package.json
$ cnpm install json-to-oas-component-cli 
SYNC missed versions from official npm registry.

This tool reads JSON on stdin and generates Open API Spec components based on the data types it finds. It's very basic at the moment, but it's a great starting point to start modifying by hand

Installation

npm install -f json-to-oas-component-cli

Usage

$ echo '{"foo":"bar", "baz": [{"hello":"world"}]}' | node json-to-oas-component
components:
  schemas:
    AnonymousObject:
      foo:
        type: string
        maxLength: 32
        description: Description goes here
        example: bar
      baz:
        type: array
        items:
          type: object
          properties:
            hello:
              type: string
              maxLength: 32
              description: Description goes here
              example: world

Current Tags

  • 1.0.2                                ...           latest (2 years ago)

3 Versions

  • 1.0.2                                ...           2 years ago
  • 1.0.1                                ...           2 years ago
  • 1.0.0                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 1
Last Day 0
Last Week 1
Last Month 2
Dependencies (2)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |