Convert local Swagger 2.0 file to Postman 2.0, and then update Postman collection using Postman API
- Get a Postman API key from the Postman integrations dashboard
- Keep your key secret by creating a new file with your key called
secrets.jsin the root of this directory. For example:
module.exports = {
"key": "e3da74f605fa422b9323c0d6dad39771"
};- To update an existing collection, retrieve the
collection_uidandcollection_idby submitting aGETrequest using the Postman API. Use this information to update the relevant sections of theconfig.jsfile. - Clone this repository.
From the command line:
$ git clone https://github.com/loopDelicious/converter.git
- Install your dependencies.
From the command line:
$ npm install
Once you've completed the previous steps, run the following command to convert swagger.json to postman-collection.json, and then update your existing collection in the cloud using the Postman API.
From the command line:
$ node converter.js