immutability-io / vault-ethereum

A plugin that turns Vault into an Ethereum wallet.
243 stars 65 forks source link

Got that swagger #22

Closed zambien closed 6 years ago

zambien commented 6 years ago

Create a PoC swagger implementation for this plugin

Description

Setup swaggerdoc for Addresses and Convert Vault functions.

Motivation and Context

This allows for a familiar interface for devs to use the plugin. Many devs are used to using swagger so I thought there might be some value in building this. If it is deemed OK I will create the rest of the swagger doc for the rest of the operations in the plugin.

How Has This Been Tested?

Yes, this has been tested and the documentation has been included at the end of API.md in case others want to generate the swagger doc. I tested this by following the instructions on the immutability vault-ethereum readme and followed the link to setup vault with install_vault.sh.

I tested the endpoints in question as well and verified the curl created by swagger is the same as the examples in API.md.

Screenshots (if appropriate):

Not a screenshot, but you can see this here: http://petstore.swagger.io/?url=https://raw.githubusercontent.com/zambien/vault-ethereum/got_that_swagger/swagger.json

Types of changes

Checklist: