blob: bb76c41ba05045cee4f3ca1a02a68f8ee63af265 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
|
swagger: "2.0"
info:
description: "API reference for Distributed Key Value store."
version: "1.0.0"
title: "API reference for Distributed Key Value store"
contact:
email: "shashank.kumar.shankar@intel.com"
url: "https://wiki.onap.org/display/DW/Distributed+KV+Store"
license:
name: "Apache 2.0"
url: "http://www.apache.org/licenses/LICENSE-2.0.html"
basePath: "/v1"
schemes:
- "http"
paths:
/loadconfigs:
post:
tags:
- "load configuration"
summary: "Load Key Values by reading configs into Consul"
description: ""
consumes:
- "application/json"
produces:
- "application/json"
parameters:
- in: "body"
name: "body"
description: "Load configuration from file system to be added into Consul"
required: true
schema:
$ref: "#/definitions/LoadRequest"
responses:
200:
description: "successful operation"
schema:
$ref: "#/definitions/LoadResponse"
/getconfigs:
get:
tags:
- "get all keys"
summary: "Get all keys present in Consul."
description: "Returns a list of keys present in Consul."
produces:
- "application/json"
responses:
200:
description: "successful operation"
schema:
$ref: "#/definitions/Gets"
/getconfig/{key}:
get:
tags:
- "get single key"
summary: "Get value for specific key present in Consul."
description: "Returns a key and value present in Consul."
produces:
- "application/json"
parameters:
- name: "key"
in: "path"
description: "Key used to query"
required: true
type: "string"
responses:
200:
description: "successful operation"
schema:
$ref: "#/definitions/Get"
/deleteconfig/{key}:
delete:
tags:
- "delete single key"
summary: "Delete value for specific key present in Consul."
description: "Deletes a specific key."
produces:
- "application/json"
parameters:
- name: "key"
in: "path"
description: "Key used to delete"
required: true
type: "string"
responses:
200:
description: "successful operation"
schema:
$ref: "#/definitions/Delete"
definitions:
LoadRequest:
type: "object"
properties:
type:
$ref: "#/definitions/Type"
Type:
type: "object"
properties:
file_path:
type: "string"
LoadResponse:
type: "object"
properties:
response:
type: "string"
Gets:
type: "object"
properties:
response:
items:
type: "string"
Get:
type: "object"
properties:
response:
type: "string"
Delete:
type: "object"
properties:
response:
type: "string"
|