blob: aaf0d6a1abb3d31d4665a09a6c9db01047093403 [file] [log] [blame]
tragait34a94b92021-03-30 12:02:27 +01001# ============LICENSE_START=======================================================
mpriyankfd500182022-01-18 01:07:00 +05302# Copyright (C) 2021-2022 Nordix Foundation
lukegleeson15b93e72021-07-07 15:25:30 +01003# Modifications Copyright (C) 2021 Pantheon.tech
puthuparambil.adityad69742c2022-03-29 11:03:52 +01004# Modifications Copyright (C) 2021-2022 Bell Canada
tragait34a94b92021-03-30 12:02:27 +01005# ================================================================================
6# Licensed under the Apache License, Version 2.0 (the "License");
7# you may not use this file except in compliance with the License.
8# You may obtain a copy of the License at
9#
10# http://www.apache.org/licenses/LICENSE-2.0
lukegleeson15b93e72021-07-07 15:25:30 +010011#
tragait34a94b92021-03-30 12:02:27 +010012# Unless required by applicable law or agreed to in writing, software
13# distributed under the License is distributed on an "AS IS" BASIS,
14# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15# See the License for the specific language governing permissions and
16# limitations under the License.
17#
18# SPDX-License-Identifier: Apache-2.0
19# ============LICENSE_END=========================================================
tragaitc3285512021-08-16 15:12:36 +010020getResourceDataForPassthroughOperational:
21 get:
22 tags:
23 - network-cm-proxy
24 summary: Get resource data from pass-through operational for cm handle
25 description: Get resource data from pass-through operational for given cm handle
26 operationId: getResourceDataOperationalForCmHandle
27 parameters:
28 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
niamhcorefd2e6dd2021-09-29 16:43:35 +010029 - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery'
tragaitabdff1b2021-10-06 11:04:18 +010030 - $ref: 'components.yaml#/components/parameters/optionsParamInQuery'
sourabh_sourabh1f2e66e2022-02-16 21:53:41 +053031 - $ref: 'components.yaml#/components/parameters/topicParamInQuery'
tragaitc3285512021-08-16 15:12:36 +010032 responses:
33 200:
emaclee844cab32021-12-01 09:42:37 +000034 description: OK
35 content:
36 application/json:
37 schema:
38 type: object
39 examples:
40 dataSampleResponse:
41 $ref: 'components.yaml#/components/examples/dataSampleResponse'
tragaitc3285512021-08-16 15:12:36 +010042 400:
43 $ref: 'components.yaml#/components/responses/BadRequest'
44 401:
45 $ref: 'components.yaml#/components/responses/Unauthorized'
46 403:
47 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +000048 500:
49 $ref: 'components.yaml#/components/responses/InternalServerError'
mpriyank93afc1e2022-03-28 15:47:47 +053050 502:
51 $ref: 'components.yaml#/components/responses/BadGateway'
tragait888dcd42021-08-19 15:17:56 +010052
53resourceDataForPassthroughRunning:
54 get:
55 tags:
56 - network-cm-proxy
57 summary: Get resource data from pass-through running for cm handle
58 description: Get resource data from pass-through running for given cm handle
59 operationId: getResourceDataRunningForCmHandle
60 parameters:
61 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
niamhcorefd2e6dd2021-09-29 16:43:35 +010062 - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery'
tragaitabdff1b2021-10-06 11:04:18 +010063 - $ref: 'components.yaml#/components/parameters/optionsParamInQuery'
sourabh_sourabh1f2e66e2022-02-16 21:53:41 +053064 - $ref: 'components.yaml#/components/parameters/topicParamInQuery'
tragait888dcd42021-08-19 15:17:56 +010065 responses:
66 200:
emaclee844cab32021-12-01 09:42:37 +000067 description: OK
68 content:
69 application/json:
70 schema:
71 type: object
72 examples:
73 dataSampleResponse:
74 $ref: 'components.yaml#/components/examples/dataSampleResponse'
tragait888dcd42021-08-19 15:17:56 +010075 400:
76 $ref: 'components.yaml#/components/responses/BadRequest'
77 401:
78 $ref: 'components.yaml#/components/responses/Unauthorized'
79 403:
80 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +000081 500:
82 $ref: 'components.yaml#/components/responses/InternalServerError'
mpriyank93afc1e2022-03-28 15:47:47 +053083 502:
84 $ref: 'components.yaml#/components/responses/BadGateway'
tragaitc584bf22021-08-20 15:45:58 +010085 post:
86 tags:
87 - network-cm-proxy
88 summary: create resource data from pass-through running for cm handle
89 description: create resource data from pass-through running for given cm handle
90 operationId: createResourceDataRunningForCmHandle
91 parameters:
92 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
niamhcorefd2e6dd2021-09-29 16:43:35 +010093 - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery'
tragaitc584bf22021-08-20 15:45:58 +010094 - $ref: 'components.yaml#/components/parameters/contentParamInHeader'
95 requestBody:
96 required: true
97 content:
98 application/json:
99 schema:
puthuparambil.adityad0007332021-12-08 18:53:39 +0000100 type: object
emaclee844cab32021-12-01 09:42:37 +0000101 examples:
102 dataSampleRequest:
103 $ref: 'components.yaml#/components/examples/dataSampleRequest'
tragaitc584bf22021-08-20 15:45:58 +0100104 application/yang-data+json:
105 schema:
puthuparambil.adityad0007332021-12-08 18:53:39 +0000106 type: object
107 examples:
108 dataSampleRequest:
109 $ref: 'components.yaml#/components/examples/dataSampleRequest'
tragaitc584bf22021-08-20 15:45:58 +0100110 responses:
111 201:
112 $ref: 'components.yaml#/components/responses/Created'
113 400:
114 $ref: 'components.yaml#/components/responses/BadRequest'
115 401:
116 $ref: 'components.yaml#/components/responses/Unauthorized'
117 403:
118 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +0000119 500:
120 $ref: 'components.yaml#/components/responses/InternalServerError'
mpriyank93afc1e2022-03-28 15:47:47 +0530121 502:
122 $ref: 'components.yaml#/components/responses/BadGateway'
niamhcorec309f242021-09-07 10:27:18 +0100123
niamhcore919e9062021-11-02 14:08:16 +0000124 put:
125 tags:
126 - network-cm-proxy
127 summary: Update resource data from pass-through running for a cm handle
128 description: Update resource data from pass-through running for the given cm handle
129 operationId: updateResourceDataRunningForCmHandle
130 parameters:
131 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
132 - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery'
133 - $ref: 'components.yaml#/components/parameters/contentParamInHeader'
134 requestBody:
135 required: true
136 content:
137 application/json:
138 schema:
puthuparambil.adityad0007332021-12-08 18:53:39 +0000139 type: object
emaclee844cab32021-12-01 09:42:37 +0000140 examples:
141 dataSampleRequest:
142 $ref: 'components.yaml#/components/examples/dataSampleRequest'
niamhcore919e9062021-11-02 14:08:16 +0000143 application/yang-data+json:
144 schema:
puthuparambil.adityad0007332021-12-08 18:53:39 +0000145 type: object
146 examples:
147 dataSampleRequest:
148 $ref: 'components.yaml#/components/examples/dataSampleRequest'
niamhcore919e9062021-11-02 14:08:16 +0000149 responses:
150 200:
151 $ref: 'components.yaml#/components/responses/Ok'
152 400:
153 $ref: 'components.yaml#/components/responses/BadRequest'
154 401:
155 $ref: 'components.yaml#/components/responses/Unauthorized'
156 403:
157 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +0000158 500:
159 $ref: 'components.yaml#/components/responses/InternalServerError'
mpriyank93afc1e2022-03-28 15:47:47 +0530160 502:
161 $ref: 'components.yaml#/components/responses/BadGateway'
niamhcore919e9062021-11-02 14:08:16 +0000162
niamhcore4314e7b2021-11-24 10:53:51 +0000163 patch:
164 tags:
165 - network-cm-proxy
166 summary: Patch resource data from pass-through running
167 description: Patch resource data from pass-through running for the given cm handle
168 operationId: patchResourceDataRunningForCmHandle
169 parameters:
170 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
171 - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery'
172 - $ref: 'components.yaml#/components/parameters/contentParamInHeader'
173 requestBody:
174 required: true
175 content:
tragaitecd7f5e2022-01-13 13:15:14 +0000176 '*/*':
niamhcore4314e7b2021-11-24 10:53:51 +0000177 schema:
178 type: object
puthuparambil.adityad0007332021-12-08 18:53:39 +0000179 examples:
180 dataSampleRequest:
tragaitecd7f5e2022-01-13 13:15:14 +0000181 $ref: 'components.yaml#/components/examples/dataSamplePatchRequest'
niamhcore4314e7b2021-11-24 10:53:51 +0000182 responses:
183 200:
184 $ref: 'components.yaml#/components/responses/Ok'
185 400:
186 $ref: 'components.yaml#/components/responses/BadRequest'
187 401:
188 $ref: 'components.yaml#/components/responses/Unauthorized'
189 403:
190 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +0000191 500:
192 $ref: 'components.yaml#/components/responses/InternalServerError'
mpriyank93afc1e2022-03-28 15:47:47 +0530193 502:
194 $ref: 'components.yaml#/components/responses/BadGateway'
niamhcore4314e7b2021-11-24 10:53:51 +0000195
DylanB95ESTeeef2ae2021-11-30 15:07:35 +0000196 delete:
197 tags:
198 - network-cm-proxy
199 summary: Delete resource data
200 description: Delete resource data from pass-through running for a given cm handle
201 operationId: deleteResourceDataRunningForCmHandle
202 parameters:
203 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
204 - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery'
205 - $ref: 'components.yaml#/components/parameters/contentParamInHeader'
DylanB95ESTeeef2ae2021-11-30 15:07:35 +0000206 responses:
207 204:
208 $ref: 'components.yaml#/components/responses/NoContent'
209 400:
210 $ref: 'components.yaml#/components/responses/BadRequest'
211 401:
212 $ref: 'components.yaml#/components/responses/Unauthorized'
213 403:
214 $ref: 'components.yaml#/components/responses/Forbidden'
215 404:
216 $ref: 'components.yaml#/components/responses/NotFound'
JosephKeenane0873dd2022-01-28 11:22:22 +0000217 500:
218 $ref: 'components.yaml#/components/responses/InternalServerError'
mpriyank93afc1e2022-03-28 15:47:47 +0530219 502:
220 $ref: 'components.yaml#/components/responses/BadGateway'
DylanB95ESTeeef2ae2021-11-30 15:07:35 +0000221
niamhcorec309f242021-09-07 10:27:18 +0100222fetchModuleReferencesByCmHandle:
223 get:
224 description: fetch all module references (name and revision) for a given cm handle
225 tags:
226 - network-cm-proxy
227 summary: Fetch all module references (name and revision) for a given cm handle
228 operationId: getModuleReferencesByCmHandle
229 parameters:
230 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
231 responses:
232 200:
233 description: OK
234 content:
235 application/json:
236 schema:
puthuparambil.adityad0007332021-12-08 18:53:39 +0000237 type: array
238 items:
lukegleesond5bda882022-03-02 14:32:47 +0000239 $ref: 'components.yaml#/components/schemas/RestModuleReference'
niamhcorec309f242021-09-07 10:27:18 +0100240 400:
241 $ref: 'components.yaml#/components/responses/BadRequest'
242 401:
243 $ref: 'components.yaml#/components/responses/Unauthorized'
244 403:
245 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +0000246 500:
247 $ref: 'components.yaml#/components/responses/InternalServerError'
niamhcore66017b42021-10-19 11:07:02 +0100248
emacleee1f73e22022-06-17 17:42:56 +0100249fetchModuleDefinitionsByCmHandle:
250 get:
251 description: Fetch all module definitions (name, revision, yang resource) for a given cm handle
252 tags:
253 - network-cm-proxy
254 summary: Fetch all module definitions (name, revision, yang resource) for a given cm handle
255 operationId: getModuleDefinitionsByCmHandleId
256 parameters:
257 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
258 responses:
259 200:
260 description: OK
261 content:
262 application/json:
263 schema:
264 type: array
265 items:
266 $ref: 'components.yaml#/components/schemas/RestModuleDefinition'
267 401:
268 $ref: 'components.yaml#/components/responses/Unauthorized'
269 403:
270 $ref: 'components.yaml#/components/responses/Forbidden'
271 500:
272 $ref: 'components.yaml#/components/responses/InternalServerError'
273
kissande9ed5812022-05-12 15:59:18 +0200274searchCmHandles:
niamhcore66017b42021-10-19 11:07:02 +0100275 post:
kissand2beebc62022-06-02 16:26:23 +0200276 description: Execute cm handle query search, to be included in the result a cm-handle must fulfill ALL the conditions listed here, if one of the given module names does not exists, return with an empty collection.
niamhcore66017b42021-10-19 11:07:02 +0100277 tags:
278 - network-cm-proxy
279 summary: Execute cm handle search using the available conditions
kissande9ed5812022-05-12 15:59:18 +0200280 operationId: searchCmHandles
niamhcore66017b42021-10-19 11:07:02 +0100281 requestBody:
282 required: true
283 content:
284 application/json:
285 schema:
kissande9ed5812022-05-12 15:59:18 +0200286 $ref: 'components.yaml#/components/schemas/CmHandleQueryParameters'
niamhcore66017b42021-10-19 11:07:02 +0100287 responses:
288 200:
289 description: OK
290 content:
291 application/json:
292 schema:
kissande9ed5812022-05-12 15:59:18 +0200293 type: array
294 items:
295 $ref: 'components.yaml#/components/schemas/RestOutputCmHandle'
niamhcore66017b42021-10-19 11:07:02 +0100296 400:
297 $ref: 'components.yaml#/components/responses/BadRequest'
298 401:
299 $ref: 'components.yaml#/components/responses/Unauthorized'
300 403:
ToineSiebelink18a79eb2021-12-23 12:36:40 +0000301 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +0000302 500:
303 $ref: 'components.yaml#/components/responses/InternalServerError'
DylanB95ESTe5573382022-01-27 17:12:52 +0000304
305retrieveCmHandleDetailsById:
306 get:
307 description: Retrieve CM handle details and properties by cm handle id
308 tags:
309 - network-cm-proxy
310 summary: Retrieve CM handle details
311 operationId: retrieveCmHandleDetailsById
312 parameters:
313 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
314 responses:
315 200:
316 description: OK
317 content:
318 application/json:
319 schema:
320 $ref: 'components.yaml#/components/schemas/RestOutputCmHandle'
lukegleeson78062a12022-06-02 10:56:43 +0100321 400:
322 $ref: 'components.yaml#/components/responses/BadRequest'
323 401:
324 $ref: 'components.yaml#/components/responses/Unauthorized'
JosephKeenandeac4772022-03-28 12:26:07 +0100325 404:
326 $ref: 'components.yaml#/components/responses/NotFound'
327 500:
328 $ref: 'components.yaml#/components/responses/InternalServerError'
329
lukegleesonbed18fd2022-05-06 12:02:42 +0100330getCmHandlePropertiesById:
331 get:
332 description: Get CM handle properties by cm handle id
333 tags:
334 - network-cm-proxy
335 summary: Get CM handle properties
336 operationId: getCmHandlePublicPropertiesByCmHandleId
337 parameters:
338 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
339 responses:
340 200:
341 description: OK
342 content:
343 application/json:
344 schema:
345 $ref: 'components.yaml#/components/schemas/RestOutputCmHandlePublicProperties'
lukegleeson78062a12022-06-02 10:56:43 +0100346 400:
347 $ref: 'components.yaml#/components/responses/BadRequest'
348 401:
349 $ref: 'components.yaml#/components/responses/Unauthorized'
350 404:
351 $ref: 'components.yaml#/components/responses/NotFound'
352 500:
353 $ref: 'components.yaml#/components/responses/InternalServerError'
354
355getCmHandleStateById:
356 get:
357 description: Get CM handle state by cm handle id
358 tags:
359 - network-cm-proxy
360 summary: Get CM handle state
361 operationId: getCmHandleStateByCmHandleId
362 parameters:
363 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
364 responses:
365 200:
366 description: OK
367 content:
368 application/json:
369 schema:
370 $ref: 'components.yaml#/components/schemas/RestOutputCmHandleCompositeState'
371 400:
372 $ref: 'components.yaml#/components/responses/BadRequest'
373 401:
374 $ref: 'components.yaml#/components/responses/Unauthorized'
lukegleesonbed18fd2022-05-06 12:02:42 +0100375 404:
376 $ref: 'components.yaml#/components/responses/NotFound'
377 500:
378 $ref: 'components.yaml#/components/responses/InternalServerError'
379
kissande9ed5812022-05-12 15:59:18 +0200380searchCmHandleIds:
JosephKeenandeac4772022-03-28 12:26:07 +0100381 post:
kissand2beebc62022-06-02 16:26:23 +0200382 description: Execute cm handle query search, to be included in the result a cm-handle must fulfill ALL the conditions listed here, if one of the given module names does not exists, return with an empty collection.
JosephKeenandeac4772022-03-28 12:26:07 +0100383 tags:
384 - network-cm-proxy
385 summary: Execute cm handle query upon a given set of query parameters
kissande9ed5812022-05-12 15:59:18 +0200386 operationId: searchCmHandleIds
JosephKeenandeac4772022-03-28 12:26:07 +0100387 requestBody:
388 required: true
389 content:
390 application/json:
391 schema:
kissande9ed5812022-05-12 15:59:18 +0200392 $ref: 'components.yaml#/components/schemas/CmHandleQueryParameters'
JosephKeenandeac4772022-03-28 12:26:07 +0100393 responses:
394 200:
395 description: OK
396 content:
397 application/json:
398 schema:
399 type: array
400 items:
401 type: string
DylanB95ESTe5573382022-01-27 17:12:52 +0000402 400:
403 $ref: 'components.yaml#/components/responses/BadRequest'
404 401:
405 $ref: 'components.yaml#/components/responses/Unauthorized'
406 403:
407 $ref: 'components.yaml#/components/responses/Forbidden'
408 404:
409 $ref: 'components.yaml#/components/responses/NotFound'
410 500:
411 $ref: 'components.yaml#/components/responses/InternalServerError'