1.3.3 • Published 11 months ago

swagger-modifier v1.3.3

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

Swagger Modifier

This tool modifies Swagger files by adding prefixes and suffixes to operation IDs and references.

Installation

npm install -g swagger-modifier

Usage

swagger-modifier -i <inputFilePath> -o <outputFilePath> -c <configMapping>

Options:

-i, --input : Path to the input Swagger file. -o, --output : Path to the output directory. -c, --config : Path to the JSON file containing a map of operation IDs to prefixes and suffixes.

Example:

swagger-modifier -i swagger.json -o modified-swagger.json -c config.json

config.json:

{
  "endpoints": [
    {
      "packageName": "users-create-service",
      "path": "/users",
      "method": "post",
      "prefix": "USER_CREATE_",
      "suffix": "_V1",
      "inputSuffix": "_Input",
      "ignore": [],
      "openapi-config": {}
    },
    {
      "packageName": "users-get-service",
      "path": "/users",
      "method": "get",
      "prefix": "USER_GET_",
      "suffix": "_V1",
      "inputSuffix": "_Input",
      "inputSuffix": "_Input",
      "ignore": []
    }
  ]
}

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

License

This project is licensed under the MIT License.

1.3.3

11 months ago

1.3.2

11 months ago

1.3.1

11 months ago

1.3.0

11 months ago

1.2.9

12 months ago

1.2.8

12 months ago

1.2.7

12 months ago

1.2.6

12 months ago

1.2.5

12 months ago

1.2.4

12 months ago

1.2.3

12 months ago

1.2.2

12 months ago

1.2.1

12 months ago

1.2.0

12 months ago

1.1.9

12 months ago

1.1.8

12 months ago

1.1.7

12 months ago

1.1.6

12 months ago

1.1.5

12 months ago

1.1.4

12 months ago

1.1.3

12 months ago

1.1.2

12 months ago

1.1.1

12 months ago

1.1.0

12 months ago

1.0.9

12 months ago

1.0.8

12 months ago

1.0.7

12 months ago

1.0.6

12 months ago

1.0.5

12 months ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago