| { |
| "openapi": "3.0.2", |
| "info": { |
| "title": "HashiCorp Vault API", |
| "description": "HTTP API that gives you full access to Vault. All API routes are prefixed with `/v1/`.", |
| "version": "<vault_version>", |
| "license": { |
| "name": "Mozilla Public License 2.0", |
| "url": "https://www.mozilla.org/en-US/MPL/2.0" |
| } |
| }, |
| "paths": { |
| "/foo/{id}": { |
| "description": "Synopsis", |
| "x-vault-createSupported": true, |
| "x-vault-sudo": true, |
| "x-vault-displayAttrs": { |
| "navigation": true |
| }, |
| "parameters": [ |
| { |
| "name": "format", |
| "description": "a query param", |
| "in": "query", |
| "schema": { |
| "type": "string" |
| } |
| }, |
| { |
| "name": "id", |
| "description": "id path parameter", |
| "in": "path", |
| "schema": { |
| "type": "string" |
| }, |
| "required": true |
| } |
| ], |
| "get": { |
| "operationId": "kv-read-foo-id", |
| "tags": [ |
| "secrets" |
| ], |
| "summary": "My Summary", |
| "description": "My Description", |
| "responses": { |
| "200": { |
| "description": "OK" |
| } |
| }, |
| "parameters": [ |
| { |
| "name": "list", |
| "description": "Return a list if `true`", |
| "in": "query", |
| "schema": { |
| "type": "string" |
| } |
| } |
| ] |
| }, |
| "post": { |
| "operationId": "kv-write-foo-id", |
| "tags": [ |
| "secrets" |
| ], |
| "summary": "Update Summary", |
| "description": "Update Description", |
| "requestBody": { |
| "required": true, |
| "content": { |
| "application/json": { |
| "schema": { |
| "$ref": "#/components/schemas/KvWriteFooIdRequest" |
| } |
| } |
| } |
| }, |
| "responses": { |
| "200": { |
| "description": "OK" |
| } |
| } |
| } |
| } |
| }, |
| "components": { |
| "schemas": { |
| "KvWriteFooIdRequest": { |
| "type": "object", |
| "required": [ |
| "age" |
| ], |
| "properties": { |
| "flavors": { |
| "type": "array", |
| "description": "the flavors", |
| "items": { |
| "type": "string" |
| } |
| }, |
| "age": { |
| "type": "integer", |
| "description": "the age", |
| "enum": [ |
| 1, |
| 2, |
| 3 |
| ], |
| "x-vault-displayAttrs": { |
| "name": "Age", |
| "sensitive": true, |
| "group": "Some Group", |
| "value": 7 |
| } |
| }, |
| "name": { |
| "type": "string", |
| "description": "the name", |
| "default": "Larry", |
| "pattern": "\\w([\\w-.]*\\w)?" |
| }, |
| "x-abc-token": { |
| "type": "string", |
| "description": "a header value", |
| "enum": [ |
| "a", |
| "b", |
| "c" |
| ] |
| }, |
| "maximum": { |
| "type": "integer", |
| "description": "a maximum value", |
| "format": "int64" |
| } |
| } |
| } |
| } |
| } |
| } |