diff options
author | Kiran Kamineni <kiran.k.kamineni@intel.com> | 2018-05-04 16:50:39 -0700 |
---|---|---|
committer | Girish Havaldar <hg0071052@techmahindra.com> | 2018-05-15 17:21:53 +0000 |
commit | ac134cb099afa6be09fbc5cdad5db0bcf7aee08a (patch) | |
tree | cbcdf280db9285edfe8c6e62e094c6c4c6db302e /docs/api_swagger.html | |
parent | d4b81c05a255a847bbf7f08caebe032492ad2ca5 (diff) |
Adding a docs folder under sms repo
WORK IN PROGRESS
Adding a docs folder under sms
Issue-ID: AAF-185
Change-Id: I5ee3560cfda2100ad5207bb7e98d5cb9472e1325
Signed-off-by: Girish Havaldar <hg0071052@techmahindra.com>
Diffstat (limited to 'docs/api_swagger.html')
-rw-r--r-- | docs/api_swagger.html | 732 |
1 files changed, 732 insertions, 0 deletions
diff --git a/docs/api_swagger.html b/docs/api_swagger.html new file mode 100644 index 0000000..7f987a3 --- /dev/null +++ b/docs/api_swagger.html @@ -0,0 +1,732 @@ +<!doctype html> +<html> + <head> + <title>Secret Management Service</title> + <style type="text/css"> + body { + font-family: Trebuchet MS, sans-serif; + font-size: 15px; + color: #444; + margin-right: 24px; +} + +h1 { + font-size: 25px; +} +h2 { + font-size: 20px; +} +h3 { + font-size: 16px; + font-weight: bold; +} +hr { + height: 1px; + border: 0; + color: #ddd; + background-color: #ddd; +} + +.app-desc { + clear: both; + margin-left: 20px; +} +.param-name { + width: 100%; +} +.license-info { + margin-left: 20px; +} + +.license-url { + margin-left: 20px; +} + +.model { + margin: 0 0 0px 20px; +} + +.method { + margin-left: 20px; +} + +.method-notes { + margin: 10px 0 20px 0; + font-size: 90%; + color: #555; +} + +pre { + padding: 10px; + margin-bottom: 2px; +} + +.http-method { + text-transform: uppercase; +} + +pre.get { + background-color: #0f6ab4; +} + +pre.post { + background-color: #10a54a; +} + +pre.put { + background-color: #c5862b; +} + +pre.delete { + background-color: #a41e22; +} + +.huge { + color: #fff; +} + +pre.example { + background-color: #f3f3f3; + padding: 10px; + border: 1px solid #ddd; +} + +code { + white-space: pre; +} + +.nickname { + font-weight: bold; +} + +.method-path { + font-size: 1.5em; + background-color: #0f6ab4; +} + +.up { + float:right; +} + +.parameter { + width: 500px; +} + +.param { + width: 500px; + padding: 10px 0 0 20px; + font-weight: bold; +} + +.param-desc { + width: 700px; + padding: 0 0 0 20px; + color: #777; +} + +.param-type { + font-style: italic; +} + +.param-enum-header { +width: 700px; +padding: 0 0 0 60px; +color: #777; +font-weight: bold; +} + +.param-enum { +width: 700px; +padding: 0 0 0 80px; +color: #777; +font-style: italic; +} + +.field-label { + padding: 0; + margin: 0; + clear: both; +} + +.field-items { + padding: 0 0 15px 0; + margin-bottom: 15px; +} + +.return-type { + clear: both; + padding-bottom: 10px; +} + +.param-header { + font-weight: bold; +} + +.method-tags { + text-align: right; +} + +.method-tag { + background: none repeat scroll 0% 0% #24A600; + border-radius: 3px; + padding: 2px 10px; + margin: 2px; + color: #FFF; + display: inline-block; + text-decoration: none; +} + + </style> + </head> + <body> + <h1>Secret Management Service</h1> + <div class="app-desc">This is a service that provides secret management facilities</div> + <div class="app-desc">More information: <a href="https://helloreverb.com">https://helloreverb.com</a></div> + <div class="app-desc">Contact Info: <a href="kiran.k.kamineni@intel.com">kiran.k.kamineni@intel.com</a></div> + <div class="app-desc">Version: 1.0.0</div> + <div class="app-desc">BasePath:/v1/sms/</div> + <div class="license-info">Apache 2.0</div> + <div class="license-url">http://www.apache.org/licenses/LICENSE-2.0.html</div> + <h2>Access</h2> + <ol> + <li>APIKey KeyParamName:token KeyInQuery:false KeyInHeader:true</li> + </ol> + + <h2><a name="__Methods">Methods</a></h2> + [ Jump to <a href="#__Models">Models</a> ] + + <h3>Table of Contents </h3> + <div class="method-summary"></div> + <h4><a href="#Domain">Domain</a></h4> + <ul> + <li><a href="#domainDomainNameDelete"><code><span class="http-method">delete</span> /domain/{domainName}</code></a></li> + <li><a href="#domainPost"><code><span class="http-method">post</span> /domain</code></a></li> + </ul> + <h4><a href="#Login">Login</a></h4> + <ul> + <li><a href="#loginPost"><code><span class="http-method">post</span> /login</code></a></li> + </ul> + <h4><a href="#Secret">Secret</a></h4> + <ul> + <li><a href="#domainDomainNameSecretGet"><code><span class="http-method">get</span> /domain/{domainName}/secret</code></a></li> + <li><a href="#domainDomainNameSecretPost"><code><span class="http-method">post</span> /domain/{domainName}/secret</code></a></li> + <li><a href="#domainDomainNameSecretSecretNameDelete"><code><span class="http-method">delete</span> /domain/{domainName}/secret/{secretName}</code></a></li> + <li><a href="#domainDomainNameSecretSecretNameGet"><code><span class="http-method">get</span> /domain/{domainName}/secret/{secretName}</code></a></li> + </ul> + <h4><a href="#System">System</a></h4> + <ul> + <li><a href="#statusGet"><code><span class="http-method">get</span> /status</code></a></li> + <li><a href="#unsealPost"><code><span class="http-method">post</span> /unseal</code></a></li> + </ul> + + <h1><a name="Domain">Domain</a></h1> + <div class="method"><a name="domainDomainNameDelete"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="delete"><code class="huge"><span class="http-method">delete</span> /domain/{domainName}</code></pre></div> + <div class="method-summary">Deletes a domain by name (<span class="nickname">domainDomainNameDelete</span>)</div> + <div class="method-notes">Deletes a domain with provided name</div> + + <h3 class="field-label">Path parameters</h3> + <div class="field-items"> + <div class="param">domainName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Name of the domain </div> + </div> <!-- field-items --> + + + + + + + + <!--Todo: process Response Object and its headers, schema, examples --> + + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">204</h4> + Successful Deletion + <a href="#"></a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + <div class="method"><a name="domainPost"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="post"><code class="huge"><span class="http-method">post</span> /domain</code></pre></div> + <div class="method-summary">Add a new domain (<span class="nickname">domainPost</span>)</div> + <div class="method-notes"></div> + + + <h3 class="field-label">Consumes</h3> + This API call consumes the following media types via the <span class="heaader">Content-Type</span> request header: + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Request body</h3> + <div class="field-items"> + <div class="param">body <a href="#Domain">Domain</a> (required)</div> + + <div class="param-desc"><span class="param-type">Body Parameter</span> — </div> + + </div> <!-- field-items --> + + + + + <h3 class="field-label">Return type</h3> + <div class="return-type"> + <a href="#Domain">Domain</a> + + </div> + + <!--Todo: process Response Object and its headers, schema, examples --> + + <h3 class="field-label">Example data</h3> + <div class="example-data-content-type">Content-Type: application/json</div> + <pre class="example"><code>{ + "name" : "name", + "uuid" : "uuid" +}</code></pre> + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">201</h4> + Successful Creation + <a href="#Domain">Domain</a> + <h4 class="field-label">400</h4> + Invalid input + <a href="#"></a> + <h4 class="field-label">500</h4> + Internal Server Error + <a href="#"></a> + </div> <!-- method --> + <hr/> + <h1><a name="Login">Login</a></h1> + <div class="method"><a name="loginPost"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="post"><code class="huge"><span class="http-method">post</span> /login</code></pre></div> + <div class="method-summary">Login with username and password (<span class="nickname">loginPost</span>)</div> + <div class="method-notes">Operations related to logging in via username and Password</div> + + + <h3 class="field-label">Consumes</h3> + This API call consumes the following media types via the <span class="heaader">Content-Type</span> request header: + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Request body</h3> + <div class="field-items"> + <div class="param">body <a href="#Credential">Credential</a> (required)</div> + + <div class="param-desc"><span class="param-type">Body Parameter</span> — </div> + + </div> <!-- field-items --> + + + + + <h3 class="field-label">Return type</h3> + <div class="return-type"> + <a href="#inline_response_200">inline_response_200</a> + + </div> + + <!--Todo: process Response Object and its headers, schema, examples --> + + <h3 class="field-label">Example data</h3> + <div class="example-data-content-type">Content-Type: application/json</div> + <pre class="example"><code>{ + "ttl" : 0, + "token" : "token" +}</code></pre> + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">200</h4> + Successful Login returns a token + <a href="#inline_response_200">inline_response_200</a> + <h4 class="field-label">404</h4> + Invalid Username or Password + <a href="#"></a> + </div> <!-- method --> + <hr/> + <h1><a name="Secret">Secret</a></h1> + <div class="method"><a name="domainDomainNameSecretGet"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="get"><code class="huge"><span class="http-method">get</span> /domain/{domainName}/secret</code></pre></div> + <div class="method-summary">List secret Names in this domain (<span class="nickname">domainDomainNameSecretGet</span>)</div> + <div class="method-notes">Gets all secret names in this domain</div> + + <h3 class="field-label">Path parameters</h3> + <div class="field-items"> + <div class="param">domainName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Name of the domain in which to look at </div> + </div> <!-- field-items --> + + + + + + + <h3 class="field-label">Return type</h3> + <div class="return-type"> + <a href="#inline_response_200_2">inline_response_200_2</a> + + </div> + + <!--Todo: process Response Object and its headers, schema, examples --> + + <h3 class="field-label">Example data</h3> + <div class="example-data-content-type">Content-Type: application/json</div> + <pre class="example"><code>"{\"secretnames\":[\"secretname1\",\"secretname2\",\"secretname3\"]}"</code></pre> + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">200</h4> + Successful operation + <a href="#inline_response_200_2">inline_response_200_2</a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + <div class="method"><a name="domainDomainNameSecretPost"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="post"><code class="huge"><span class="http-method">post</span> /domain/{domainName}/secret</code></pre></div> + <div class="method-summary">Add a new secret (<span class="nickname">domainDomainNameSecretPost</span>)</div> + <div class="method-notes"></div> + + <h3 class="field-label">Path parameters</h3> + <div class="field-items"> + <div class="param">domainName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Name of the domain </div> + </div> <!-- field-items --> + + <h3 class="field-label">Consumes</h3> + This API call consumes the following media types via the <span class="heaader">Content-Type</span> request header: + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Request body</h3> + <div class="field-items"> + <div class="param">body <a href="#Secret">Secret</a> (required)</div> + + <div class="param-desc"><span class="param-type">Body Parameter</span> — </div> + + </div> <!-- field-items --> + + + + + + <!--Todo: process Response Object and its headers, schema, examples --> + + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">201</h4> + Successful Creation + <a href="#"></a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + <div class="method"><a name="domainDomainNameSecretSecretNameDelete"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="delete"><code class="huge"><span class="http-method">delete</span> /domain/{domainName}/secret/{secretName}</code></pre></div> + <div class="method-summary">Deletes a Secret (<span class="nickname">domainDomainNameSecretSecretNameDelete</span>)</div> + <div class="method-notes"></div> + + <h3 class="field-label">Path parameters</h3> + <div class="field-items"> + <div class="param">secretName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Name of Secret to Delete </div><div class="param">domainName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Path to the SecretDomain which contains the Secret </div> + </div> <!-- field-items --> + + + + + + + + <!--Todo: process Response Object and its headers, schema, examples --> + + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">204</h4> + Successful Deletion + <a href="#"></a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + <div class="method"><a name="domainDomainNameSecretSecretNameGet"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="get"><code class="huge"><span class="http-method">get</span> /domain/{domainName}/secret/{secretName}</code></pre></div> + <div class="method-summary">Find Secret by Name (<span class="nickname">domainDomainNameSecretSecretNameGet</span>)</div> + <div class="method-notes">Returns a single secret</div> + + <h3 class="field-label">Path parameters</h3> + <div class="field-items"> + <div class="param">domainName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Name of the domain in which to look at </div><div class="param">secretName (required)</div> + + <div class="param-desc"><span class="param-type">Path Parameter</span> — Name of the secret which is needed </div> + </div> <!-- field-items --> + + + + + + + <h3 class="field-label">Return type</h3> + <div class="return-type"> + <a href="#Secret">Secret</a> + + </div> + + <!--Todo: process Response Object and its headers, schema, examples --> + + <h3 class="field-label">Example data</h3> + <div class="example-data-content-type">Content-Type: application/json</div> + <pre class="example"><code>{ + "values" : { + "name" : "john", + "Age" : 40, + "admin" : true + }, + "name" : "name" +}</code></pre> + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">200</h4> + successful operation + <a href="#Secret">Secret</a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + <h1><a name="System">System</a></h1> + <div class="method"><a name="statusGet"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="get"><code class="huge"><span class="http-method">get</span> /status</code></pre></div> + <div class="method-summary">Get backend status (<span class="nickname">statusGet</span>)</div> + <div class="method-notes">Gets current backend status. This API is used only by quorum clients</div> + + + + + + + + <h3 class="field-label">Return type</h3> + <div class="return-type"> + <a href="#inline_response_200_1">inline_response_200_1</a> + + </div> + + <!--Todo: process Response Object and its headers, schema, examples --> + + <h3 class="field-label">Example data</h3> + <div class="example-data-content-type">Content-Type: application/json</div> + <pre class="example"><code>{ + "sealstatus" : "sealstatus" +}</code></pre> + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">200</h4> + Successful operation + <a href="#inline_response_200_1">inline_response_200_1</a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + <div class="method"><a name="unsealPost"/> + <div class="method-path"> + <a class="up" href="#__Methods">Up</a> + <pre class="post"><code class="huge"><span class="http-method">post</span> /unseal</code></pre></div> + <div class="method-summary">Unseal backend (<span class="nickname">unsealPost</span>)</div> + <div class="method-notes">Sends unseal shard to unseal if backend is sealed</div> + + + <h3 class="field-label">Consumes</h3> + This API call consumes the following media types via the <span class="heaader">Content-Type</span> request header: + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Request body</h3> + <div class="field-items"> + <div class="param">body <a href="#body">body</a> (required)</div> + + <div class="param-desc"><span class="param-type">Body Parameter</span> — </div> + + </div> <!-- field-items --> + + + + + + <!--Todo: process Response Object and its headers, schema, examples --> + + + <h3 class="field-label">Produces</h3> + This API call produces the following media types according to the <span class="header">Accept</span> request header; + the media type will be conveyed by the <span class="heaader">Content-Type</span> response header. + <ul> + <li><code>application/json</code></li> + </ul> + + <h3 class="field-label">Responses</h3> + <h4 class="field-label">201</h4> + Submitted unseal key + <a href="#"></a> + <h4 class="field-label">404</h4> + Invalid Path or Path not found + <a href="#"></a> + </div> <!-- method --> + <hr/> + + <h2><a name="__Models">Models</a></h2> + [ Jump to <a href="#__Methods">Methods</a> ] + + <h3>Table of Contents</h3> + <ol> + <li><a href="#Credential"><code>Credential</code> - </a></li> + <li><a href="#Domain"><code>Domain</code> - </a></li> + <li><a href="#Secret"><code>Secret</code> - </a></li> + <li><a href="#body"><code>body</code> - </a></li> + <li><a href="#inline_response_200"><code>inline_response_200</code> - </a></li> + <li><a href="#inline_response_200_1"><code>inline_response_200_1</code> - </a></li> + <li><a href="#inline_response_200_2"><code>inline_response_200_2</code> - </a></li> + </ol> + + <div class="model"> + <h3><a name="Credential"><code>Credential</code> - </a> <a class="up" href="#__Models">Up</a></h3> + <div class='model-description'></div> + <div class="field-items"> + <div class="param">username (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> </div> +<div class="param">password (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> </div> + </div> <!-- field-items --> + </div> + <div class="model"> + <h3><a name="Domain"><code>Domain</code> - </a> <a class="up" href="#__Models">Up</a></h3> + <div class='model-description'></div> + <div class="field-items"> + <div class="param">uuid (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> Optional value provided by user. If user does not provide, server will auto generate </div> +<div class="param">name (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> Name of the secret domain under which all secrets will be stored </div> + </div> <!-- field-items --> + </div> + <div class="model"> + <h3><a name="Secret"><code>Secret</code> - </a> <a class="up" href="#__Models">Up</a></h3> + <div class='model-description'></div> + <div class="field-items"> + <div class="param">name (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> Name of the secret </div> +<div class="param">values (optional)</div><div class="param-desc"><span class="param-type"><a href="#object">map[String, Object]</a></span> Map of key value pairs that constitute the secret </div> + </div> <!-- field-items --> + </div> + <div class="model"> + <h3><a name="body"><code>body</code> - </a> <a class="up" href="#__Models">Up</a></h3> + + <div class="field-items"> + <div class="param">unsealshard (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> Unseal shard that will be used along with other shards to unseal backend </div> + </div> <!-- field-items --> + </div> + <div class="model"> + <h3><a name="inline_response_200"><code>inline_response_200</code> - </a> <a class="up" href="#__Models">Up</a></h3> + + <div class="field-items"> + <div class="param">token (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> </div> +<div class="param">ttl (optional)</div><div class="param-desc"><span class="param-type"><a href="#integer">Integer</a></span> ttl of returned token in seconds </div> + </div> <!-- field-items --> + </div> + <div class="model"> + <h3><a name="inline_response_200_1"><code>inline_response_200_1</code> - </a> <a class="up" href="#__Models">Up</a></h3> + + <div class="field-items"> + <div class="param">sealstatus (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">String</a></span> seal status of backend </div> + </div> <!-- field-items --> + </div> + <div class="model"> + <h3><a name="inline_response_200_2"><code>inline_response_200_2</code> - </a> <a class="up" href="#__Models">Up</a></h3> + + <div class="field-items"> + <div class="param">secretnames (optional)</div><div class="param-desc"><span class="param-type"><a href="#string">array[String]</a></span> Array of strings referencing the secret names </div> + </div> <!-- field-items --> + </div> + </body> +</html> |