@byu-oit/prepare-swagger-for-wso2

Prepare swagger documents to work with an old (~2015) version of WSO2's API manager that has some quirks

Usage no npm install needed!

<script type="module">
  import byuOitPrepareSwaggerForWso2 from 'https://cdn.skypack.dev/@byu-oit/prepare-swagger-for-wso2';
</script>

README

BYU logo"> prepare-swagger-for-wso2

A command-line interface tool to prepare Swagger or OpenAPI documents for importing into WSO2

Installation:

Using Node 10 or newer, install globally using npm by running

npm i -g @byu-oit/prepare-swagger-for-wso2

This should make the command wso2 available.

Usage:

Navigate to the directory containing your swagger.json file and run the command wso2. It will create a file called wso2_swagger.json. It's that easy.

For OpenAPI 3.0.x, use the -i flag to specify where to find your openapi.json file (e.g., wso2 -i openapi.json). This tool will convert your OpenAPI specification to Swagger in addition to its usual processes.

There are some flags you can use to tweak behavior and specify input/output file paths. To learn more about them, run wso2 --help.

Contributing:

I wrote this as a side project to save myself some time. If you'd like to contribute, feel free to send a pull request or message me on Slack. You can run the existing tests by navigating to this project's directory and running the command npm t.