简体   繁体   中英

Save swagger-ui output to a file

I have an application that provide some REST API. This API can be changed from version to version. I want to maintain change log, but it is difficult to remember all api-changes and log them by hand. I have a swagger-ui and i can see mi API any time i need it:

Swagger UI imgur

My idea is to save (some way) this output to file every time new version is released and then analyze it using some diff utility.

So the question is: how i can save my API (which I see on the screen) to a file?

You could save the json file (typically what is in the text box in the header) and do a diff on that.

If that url doesn't contain the json, append /swagger.json

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM