blob: 82f47c088fec486d7647f239329b6ccd0dfa6983 [file] [log] [blame]
niamhcoref7ba3592020-10-19 12:48:06 +01001openapi: 3.0.1
2info:
3 title: CPS API
4 description: Configuration Persistence Service API
5 version: "1.0"
6servers:
7 - url: //localhost:8088/
8tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +00009 - name: cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +010010 description: cps Resource
11paths:
12 /v1/dataspaces/{dataspace-name}/:
13 delete:
14 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +000015 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +010016 summary: Delete the given dataspace
17 operationId: deleteDataspace
18 parameters:
19 - name: dataspace-name
20 in: path
21 description: dataspace-name
22 required: true
23 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +000024 type: string
niamhcoref7ba3592020-10-19 12:48:06 +010025 responses:
26 200:
27 description: OK
28 content:
29 application/json:
30 schema:
31 type: object
32 204:
33 description: No Content
34 content: {}
35 401:
36 description: Unauthorized
37 content: {}
38 403:
39 description: Forbidden
40 content: {}
41 /v1/dataspaces/{dataspace-name}/anchors:
42 get:
43 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +000044 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +010045 summary: Read all anchors, given a dataspace
46 operationId: getAnchors
47 parameters:
48 - name: dataspace-name
49 in: path
50 description: dataspace-name
51 required: true
52 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +000053 type: string
niamhcoref7ba3592020-10-19 12:48:06 +010054 responses:
55 200:
56 description: OK
57 content:
58 application/json:
59 schema:
60 type: object
61 401:
62 description: Unauthorized
63 content: {}
64 403:
65 description: Forbidden
66 content: {}
67 404:
68 description: Not Found
69 content: {}
70 post:
71 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +000072 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +010073 summary: Create a new anchor in the given dataspace
74 operationId: createAnchor
75 parameters:
76 - name: dataspace-name
77 in: path
78 description: dataspace-name
79 required: true
80 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +000081 type: string
niamhcoref7ba3592020-10-19 12:48:06 +010082 requestBody:
83 content:
84 multipart/form-data:
85 schema:
86 required:
87 - file
88 properties:
puthuparambil.aditya47598112020-11-02 11:31:39 +000089 multipartFile:
niamhcoref7ba3592020-10-19 12:48:06 +010090 type: string
puthuparambil.aditya47598112020-11-02 11:31:39 +000091 description: multipartFile
niamhcoref7ba3592020-10-19 12:48:06 +010092 format: binary
93 required: true
94 responses:
95 200:
96 description: OK
97 content:
98 application/json:
99 schema:
100 type: object
101 201:
102 description: Created
103 content: {}
104 401:
105 description: Unauthorized
106 content: {}
107 403:
108 description: Forbidden
109 content: {}
110 404:
111 description: Not Found
112 content: {}
113 /v1/dataspaces/{dataspace-name}/anchors/{anchor-name}:
114 get:
115 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000116 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100117 summary: Read an anchor given a anchor and a dataspace
118 operationId: getAnchor
119 parameters:
120 - name: dataspace-name
121 in: path
122 description: dataspace-name
123 required: true
124 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000125 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100126 - name: anchor-name
127 in: path
128 description: anchor-name
129 required: true
130 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000131 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100132 responses:
133 200:
134 description: OK
135 content:
136 application/json:
137 schema:
138 type: object
139 401:
140 description: Unauthorized
141 content: {}
142 403:
143 description: Forbidden
144 content: {}
145 404:
146 description: Not Found
147 content: {}
148 delete:
149 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000150 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100151 summary: Delete an anchor given a anchor and a dataspace
152 operationId: deleteAnchor
153 parameters:
154 - name: dataspace-name
155 in: path
156 description: dataspace-name
157 required: true
158 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000159 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100160 - name: anchor-name
161 in: path
162 description: anchor-name
163 required: true
164 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000165 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100166 responses:
167 200:
168 description: OK
169 content:
170 application/json:
171 schema:
172 type: object
173 204:
174 description: No Content
175 content: {}
176 401:
177 description: Unauthorized
178 content: {}
179 403:
180 description: Forbidden
181 content: {}
182 /v1/dataspaces/{dataspace-name}/anchors/{anchor-name}/nodes:
183 get:
184 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000185 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100186 summary: Get a node given an anchor for the given dataspace
187 operationId: getNodeByDataspaceAndAnchor
188 parameters:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000189 - name: dataspace-name
niamhcoref7ba3592020-10-19 12:48:06 +0100190 in: path
niamhcoreb4cd52f2020-10-27 15:49:30 +0000191 description: dataspace-name
niamhcoref7ba3592020-10-19 12:48:06 +0100192 required: true
193 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000194 type: string
195 - name: anchor-name
niamhcoref7ba3592020-10-19 12:48:06 +0100196 in: path
niamhcoreb4cd52f2020-10-27 15:49:30 +0000197 description: anchor-name
niamhcoref7ba3592020-10-19 12:48:06 +0100198 required: true
199 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000200 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100201 responses:
202 200:
203 description: OK
204 content:
205 application/json:
206 schema:
207 type: object
208 401:
209 description: Unauthorized
210 content: {}
211 403:
212 description: Forbidden
213 content: {}
214 404:
215 description: Not Found
216 content: {}
217 x-codegen-request-body-name: xpath
218 /v1/dataspaces/{dataspace-name}/modules:
219 get:
220 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000221 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100222 summary: Read all yang modules in the store
223 operationId: getModule
224 parameters:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000225 - name: dataspace-name
niamhcoref7ba3592020-10-19 12:48:06 +0100226 in: path
niamhcoreb4cd52f2020-10-27 15:49:30 +0000227 description: dataspace-name
niamhcoref7ba3592020-10-19 12:48:06 +0100228 required: true
229 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000230 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100231 - name: namespace-name
232 in: query
233 description: namespace-name
234 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000235 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100236 - name: revision
237 in: query
238 description: revision
239 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000240 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100241 responses:
242 200:
243 description: OK
244 content:
245 application/json:
246 schema:
247 type: object
248 401:
249 description: Unauthorized
250 content: {}
251 403:
252 description: Forbidden
253 content: {}
254 404:
255 description: Not Found
256 content: {}
257 post:
258 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000259 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100260 summary: Create modules for the given dataspace
261 operationId: createModules
262 parameters:
263 - name: dataspace-name
264 in: path
265 description: dataspace-name
266 required: true
267 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000268 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100269 requestBody:
270 content:
271 multipart/form-data:
272 schema:
273 required:
274 - file
275 properties:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000276 multipartFile:
niamhcoref7ba3592020-10-19 12:48:06 +0100277 type: string
puthuparambil.aditya47598112020-11-02 11:31:39 +0000278 description: multipartFile
niamhcoref7ba3592020-10-19 12:48:06 +0100279 format: binary
280 required: true
281 responses:
282 200:
283 description: OK
284 content:
285 application/json:
286 schema:
287 type: object
288 201:
289 description: Created
290 content: {}
291 401:
292 description: Unauthorized
293 content: {}
294 403:
295 description: Forbidden
296 content: {}
297 404:
298 description: Not Found
299 content: {}
300 /v1/dataspaces/{dataspace-name}/nodes:
301 get:
302 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000303 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100304 summary: Get all nodes for a given dataspace using an xpath or schema node identifier
305 operationId: getNode
306 parameters:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000307 - name: dataspace-name
niamhcoref7ba3592020-10-19 12:48:06 +0100308 in: path
niamhcoreb4cd52f2020-10-27 15:49:30 +0000309 description: dataspace-name
niamhcoref7ba3592020-10-19 12:48:06 +0100310 required: true
311 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000312 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100313 responses:
314 200:
315 description: OK
316 content:
317 application/json:
318 schema:
319 type: object
320 401:
321 description: Unauthorized
322 content: {}
323 403:
324 description: Forbidden
325 content: {}
326 404:
327 description: Not Found
328 content: {}
329 x-codegen-request-body-name: requestBody
330 post:
331 tags:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000332 - cps-rest
niamhcoref7ba3592020-10-19 12:48:06 +0100333 summary: Create a node for a given anchor for the given dataspace
334 operationId: createNode
335 parameters:
336 - name: dataspace-name
337 in: path
338 description: dataspace-name
339 required: true
340 schema:
niamhcoreb4cd52f2020-10-27 15:49:30 +0000341 type: string
niamhcoref7ba3592020-10-19 12:48:06 +0100342 requestBody:
343 content:
344 multipart/form-data:
345 schema:
346 required:
347 - file
348 properties:
puthuparambil.aditya47598112020-11-02 11:31:39 +0000349 multipartFile:
niamhcoref7ba3592020-10-19 12:48:06 +0100350 type: string
puthuparambil.aditya47598112020-11-02 11:31:39 +0000351 description: multipartFile
niamhcoref7ba3592020-10-19 12:48:06 +0100352 format: binary
353 required: true
354 responses:
355 200:
356 description: OK
357 content:
358 application/json:
359 schema:
360 type: object
361 201:
362 description: Created
363 content: {}
364 401:
365 description: Unauthorized
366 content: {}
367 403:
368 description: Forbidden
369 content: {}
370 404:
371 description: Not Found
372 content: {}
niamhcoreb4cd52f2020-10-27 15:49:30 +0000373components: {}