blob: 05e4b84853ccd4404075d51cd4a674634fb20234 [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
249executeCmHandleSearch:
250 post:
251 description: Execute cm handle searches using 'hasAllModules' condition to get all cm handles for the given module names
252 tags:
253 - network-cm-proxy
254 summary: Execute cm handle search using the available conditions
255 operationId: executeCmHandleSearch
256 requestBody:
257 required: true
258 content:
259 application/json:
260 schema:
261 $ref: 'components.yaml#/components/schemas/Conditions'
262 responses:
263 200:
264 description: OK
265 content:
266 application/json:
267 schema:
268 $ref: 'components.yaml#/components/schemas/CmHandles'
269 400:
270 $ref: 'components.yaml#/components/responses/BadRequest'
271 401:
272 $ref: 'components.yaml#/components/responses/Unauthorized'
273 403:
ToineSiebelink18a79eb2021-12-23 12:36:40 +0000274 $ref: 'components.yaml#/components/responses/Forbidden'
JosephKeenane0873dd2022-01-28 11:22:22 +0000275 500:
276 $ref: 'components.yaml#/components/responses/InternalServerError'
DylanB95ESTe5573382022-01-27 17:12:52 +0000277
278retrieveCmHandleDetailsById:
279 get:
280 description: Retrieve CM handle details and properties by cm handle id
281 tags:
282 - network-cm-proxy
283 summary: Retrieve CM handle details
284 operationId: retrieveCmHandleDetailsById
285 parameters:
286 - $ref: 'components.yaml#/components/parameters/cmHandleInPath'
287 responses:
288 200:
289 description: OK
290 content:
291 application/json:
292 schema:
293 $ref: 'components.yaml#/components/schemas/RestOutputCmHandle'
JosephKeenandeac4772022-03-28 12:26:07 +0100294 404:
295 $ref: 'components.yaml#/components/responses/NotFound'
296 500:
297 $ref: 'components.yaml#/components/responses/InternalServerError'
298
299queryCmHandles:
300 post:
301 description: Execute cm handle query search
302 tags:
303 - network-cm-proxy
304 summary: Execute cm handle query upon a given set of query parameters
305 operationId: queryCmHandles
306 requestBody:
307 required: true
308 content:
309 application/json:
310 schema:
311 $ref: 'components.yaml#/components/schemas/CmHandleQueryRestParameters'
312 responses:
313 200:
314 description: OK
315 content:
316 application/json:
317 schema:
318 type: array
319 items:
320 type: string
DylanB95ESTe5573382022-01-27 17:12:52 +0000321 400:
322 $ref: 'components.yaml#/components/responses/BadRequest'
323 401:
324 $ref: 'components.yaml#/components/responses/Unauthorized'
325 403:
326 $ref: 'components.yaml#/components/responses/Forbidden'
327 404:
328 $ref: 'components.yaml#/components/responses/NotFound'
329 500:
330 $ref: 'components.yaml#/components/responses/InternalServerError'