tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 1 | # ============LICENSE_START======================================================= |
lukegleeson | 15b93e7 | 2021-07-07 15:25:30 +0100 | [diff] [blame] | 2 | # Copyright (C) 2021 Nordix Foundation |
| 3 | # Modifications Copyright (C) 2021 Pantheon.tech |
Renu Kumari | 139e822 | 2021-10-04 20:59:18 -0400 | [diff] [blame] | 4 | # Modifications Copyright (C) 2021 Bell Canada |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 5 | # ================================================================================ |
| 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 |
lukegleeson | 15b93e7 | 2021-07-07 15:25:30 +0100 | [diff] [blame] | 11 | # |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 12 | # 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========================================================= |
| 20 | |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 21 | nodeByCmHandleAndXpath: |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 22 | get: |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 23 | description: Get a node with an option to retrieve all the children for a given cm Handle |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 24 | deprecated: true |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 25 | tags: |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 26 | - network-cm-proxy |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 27 | summary: Get a node given a cm Handle and xpath |
| 28 | operationId: getNodeByCmHandleAndXpath |
| 29 | parameters: |
| 30 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 31 | - $ref: 'components.yaml#/components/parameters/xpathInQuery' |
| 32 | - $ref: 'components.yaml#/components/parameters/includeDescendantsOptionInQuery' |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 33 | responses: |
| 34 | 200: |
| 35 | $ref: 'components.yaml#/components/responses/Ok' |
| 36 | 400: |
| 37 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 38 | 401: |
| 39 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 40 | 403: |
| 41 | $ref: 'components.yaml#/components/responses/Forbidden' |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 42 | 404: |
| 43 | $ref: 'components.yaml#/components/responses/NotFound' |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 44 | |
| 45 | nodesByCmHandleAndCpsPath: |
| 46 | get: |
| 47 | description: Query nodes for the given cps path and cm Handle |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 48 | deprecated: true |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 49 | tags: |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 50 | - network-cm-proxy |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 51 | summary: Query data nodes |
| 52 | operationId: queryNodesByCmHandleAndCpsPath |
| 53 | parameters: |
| 54 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 55 | - $ref: 'components.yaml#/components/parameters/cpsPathInQuery' |
niamhcore | 32446dc | 2021-03-01 13:25:13 +0000 | [diff] [blame] | 56 | - $ref: 'components.yaml#/components/parameters/includeDescendantsOptionInQuery' |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 57 | responses: |
| 58 | 200: |
| 59 | $ref: 'components.yaml#/components/responses/Ok' |
| 60 | 400: |
| 61 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 62 | 401: |
| 63 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 64 | 403: |
| 65 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 66 | 404: |
| 67 | $ref: 'components.yaml#/components/responses/NotFound' |
| 68 | |
| 69 | nodesByCmHandleAndXpath: |
Ruslan Kashapov | d07ebc8 | 2021-04-20 11:14:30 +0300 | [diff] [blame] | 70 | post: |
| 71 | description: Create a node with descendants for the given CM Handle; top level or under existing node (requires xpath) |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 72 | deprecated: true |
Ruslan Kashapov | d07ebc8 | 2021-04-20 11:14:30 +0300 | [diff] [blame] | 73 | tags: |
| 74 | - network-cm-proxy |
| 75 | summary: Create a node with descendants |
| 76 | operationId: createNode |
| 77 | parameters: |
| 78 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 79 | - $ref: 'components.yaml#/components/parameters/xpathInQuery' |
| 80 | requestBody: |
| 81 | required: true |
| 82 | content: |
| 83 | application/json: |
| 84 | schema: |
| 85 | type: string |
| 86 | responses: |
| 87 | 201: |
| 88 | $ref: 'components.yaml#/components/responses/Created' |
| 89 | 400: |
| 90 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 91 | 401: |
| 92 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 93 | 403: |
| 94 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 95 | 404: |
| 96 | $ref: 'components.yaml#/components/responses/NotFound' |
| 97 | |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 98 | patch: |
| 99 | description: Update node leaves for the given cps path and cm Handle |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 100 | deprecated: true |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 101 | tags: |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 102 | - network-cm-proxy |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 103 | summary: Update node leaves |
| 104 | operationId: updateNodeLeaves |
| 105 | parameters: |
| 106 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 107 | - $ref: 'components.yaml#/components/parameters/xpathInQuery' |
| 108 | requestBody: |
| 109 | required: true |
| 110 | content: |
| 111 | application/json: |
| 112 | schema: |
| 113 | type: string |
| 114 | responses: |
| 115 | 200: |
| 116 | $ref: 'components.yaml#/components/responses/Ok' |
| 117 | 400: |
| 118 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 119 | 401: |
| 120 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 121 | 403: |
| 122 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 123 | 404: |
| 124 | $ref: 'components.yaml#/components/responses/NotFound' |
| 125 | |
| 126 | put: |
| 127 | description: Replace a node with descendants for the given cps path and cm Handle |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 128 | deprecated: true |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 129 | tags: |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 130 | - network-cm-proxy |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 131 | summary: Replace a node with descendants |
| 132 | operationId: replaceNode |
| 133 | parameters: |
| 134 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 135 | - $ref: 'components.yaml#/components/parameters/xpathInQuery' |
| 136 | requestBody: |
| 137 | required: true |
| 138 | content: |
| 139 | application/json: |
| 140 | schema: |
| 141 | type: string |
| 142 | responses: |
| 143 | 200: |
| 144 | $ref: 'components.yaml#/components/responses/Ok' |
| 145 | 400: |
| 146 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 147 | 401: |
| 148 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 149 | 403: |
| 150 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 151 | 404: |
Ruslan Kashapov | 1baf48d | 2021-05-07 10:46:27 +0300 | [diff] [blame] | 152 | $ref: 'components.yaml#/components/responses/NotFound' |
| 153 | |
| 154 | listNodeByCmHandleAndXpath: |
| 155 | post: |
| 156 | description: Add one or more list-node child elements under existing node for the given CM Handle |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 157 | deprecated: true |
Ruslan Kashapov | 1baf48d | 2021-05-07 10:46:27 +0300 | [diff] [blame] | 158 | tags: |
| 159 | - network-cm-proxy |
| 160 | summary: Add list-node child element(s) |
| 161 | operationId: addListNodeElements |
| 162 | parameters: |
| 163 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 164 | - $ref: 'components.yaml#/components/parameters/requiredXpathInQuery' |
| 165 | requestBody: |
| 166 | required: true |
| 167 | content: |
| 168 | application/json: |
| 169 | schema: |
| 170 | type: string |
| 171 | responses: |
| 172 | 201: |
| 173 | $ref: 'components.yaml#/components/responses/Created' |
| 174 | 400: |
| 175 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 176 | 401: |
| 177 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 178 | 403: |
| 179 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 180 | 404: |
lukegleeson | 15b93e7 | 2021-07-07 15:25:30 +0100 | [diff] [blame] | 181 | $ref: 'components.yaml#/components/responses/NotFound' |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 182 | |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 183 | getResourceDataForPassthroughOperational: |
| 184 | get: |
| 185 | tags: |
| 186 | - network-cm-proxy |
| 187 | summary: Get resource data from pass-through operational for cm handle |
| 188 | description: Get resource data from pass-through operational for given cm handle |
| 189 | operationId: getResourceDataOperationalForCmHandle |
| 190 | parameters: |
| 191 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 192 | - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery' |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 193 | - $ref: 'components.yaml#/components/parameters/acceptParamInHeader' |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 194 | - $ref: 'components.yaml#/components/parameters/optionsParamInQuery' |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 195 | responses: |
| 196 | 200: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 197 | description: OK |
| 198 | content: |
| 199 | application/json: |
| 200 | schema: |
| 201 | type: object |
| 202 | examples: |
| 203 | dataSampleResponse: |
| 204 | $ref: 'components.yaml#/components/examples/dataSampleResponse' |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 205 | 400: |
| 206 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 207 | 401: |
| 208 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 209 | 403: |
| 210 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 211 | 404: |
tragait | 888dcd4 | 2021-08-19 15:17:56 +0100 | [diff] [blame] | 212 | $ref: 'components.yaml#/components/responses/NotFound' |
| 213 | |
| 214 | resourceDataForPassthroughRunning: |
| 215 | get: |
| 216 | tags: |
| 217 | - network-cm-proxy |
| 218 | summary: Get resource data from pass-through running for cm handle |
| 219 | description: Get resource data from pass-through running for given cm handle |
| 220 | operationId: getResourceDataRunningForCmHandle |
| 221 | parameters: |
| 222 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 223 | - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery' |
tragait | 888dcd4 | 2021-08-19 15:17:56 +0100 | [diff] [blame] | 224 | - $ref: 'components.yaml#/components/parameters/acceptParamInHeader' |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 225 | - $ref: 'components.yaml#/components/parameters/optionsParamInQuery' |
tragait | 888dcd4 | 2021-08-19 15:17:56 +0100 | [diff] [blame] | 226 | responses: |
| 227 | 200: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 228 | description: OK |
| 229 | content: |
| 230 | application/json: |
| 231 | schema: |
| 232 | type: object |
| 233 | examples: |
| 234 | dataSampleResponse: |
| 235 | $ref: 'components.yaml#/components/examples/dataSampleResponse' |
tragait | 888dcd4 | 2021-08-19 15:17:56 +0100 | [diff] [blame] | 236 | 400: |
| 237 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 238 | 401: |
| 239 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 240 | 403: |
| 241 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 242 | 404: |
tragait | c584bf2 | 2021-08-20 15:45:58 +0100 | [diff] [blame] | 243 | $ref: 'components.yaml#/components/responses/NotFound' |
| 244 | post: |
| 245 | tags: |
| 246 | - network-cm-proxy |
| 247 | summary: create resource data from pass-through running for cm handle |
| 248 | description: create resource data from pass-through running for given cm handle |
| 249 | operationId: createResourceDataRunningForCmHandle |
| 250 | parameters: |
| 251 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 252 | - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery' |
tragait | c584bf2 | 2021-08-20 15:45:58 +0100 | [diff] [blame] | 253 | - $ref: 'components.yaml#/components/parameters/contentParamInHeader' |
| 254 | requestBody: |
| 255 | required: true |
| 256 | content: |
| 257 | application/json: |
| 258 | schema: |
tragait | 868eca1 | 2021-09-14 13:55:05 +0100 | [diff] [blame] | 259 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 260 | examples: |
| 261 | dataSampleRequest: |
| 262 | $ref: 'components.yaml#/components/examples/dataSampleRequest' |
tragait | c584bf2 | 2021-08-20 15:45:58 +0100 | [diff] [blame] | 263 | application/yang-data+json: |
| 264 | schema: |
tragait | 868eca1 | 2021-09-14 13:55:05 +0100 | [diff] [blame] | 265 | type: string |
tragait | c584bf2 | 2021-08-20 15:45:58 +0100 | [diff] [blame] | 266 | responses: |
| 267 | 201: |
| 268 | $ref: 'components.yaml#/components/responses/Created' |
| 269 | 400: |
| 270 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 271 | 401: |
| 272 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 273 | 403: |
| 274 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 275 | 404: |
niamhcore | c309f24 | 2021-09-07 10:27:18 +0100 | [diff] [blame] | 276 | $ref: 'components.yaml#/components/responses/NotFound' |
| 277 | |
niamhcore | 919e906 | 2021-11-02 14:08:16 +0000 | [diff] [blame] | 278 | put: |
| 279 | tags: |
| 280 | - network-cm-proxy |
| 281 | summary: Update resource data from pass-through running for a cm handle |
| 282 | description: Update resource data from pass-through running for the given cm handle |
| 283 | operationId: updateResourceDataRunningForCmHandle |
| 284 | parameters: |
| 285 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 286 | - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery' |
| 287 | - $ref: 'components.yaml#/components/parameters/contentParamInHeader' |
| 288 | requestBody: |
| 289 | required: true |
| 290 | content: |
| 291 | application/json: |
| 292 | schema: |
| 293 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 294 | examples: |
| 295 | dataSampleRequest: |
| 296 | $ref: 'components.yaml#/components/examples/dataSampleRequest' |
niamhcore | 919e906 | 2021-11-02 14:08:16 +0000 | [diff] [blame] | 297 | application/yang-data+json: |
| 298 | schema: |
| 299 | type: string |
| 300 | responses: |
| 301 | 200: |
| 302 | $ref: 'components.yaml#/components/responses/Ok' |
| 303 | 400: |
| 304 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 305 | 401: |
| 306 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 307 | 403: |
| 308 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 309 | 404: |
| 310 | $ref: 'components.yaml#/components/responses/NotFound' |
| 311 | |
niamhcore | 4314e7b | 2021-11-24 10:53:51 +0000 | [diff] [blame] | 312 | patch: |
| 313 | tags: |
| 314 | - network-cm-proxy |
| 315 | summary: Patch resource data from pass-through running |
| 316 | description: Patch resource data from pass-through running for the given cm handle |
| 317 | operationId: patchResourceDataRunningForCmHandle |
| 318 | parameters: |
| 319 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 320 | - $ref: 'components.yaml#/components/parameters/resourceIdentifierInQuery' |
| 321 | - $ref: 'components.yaml#/components/parameters/contentParamInHeader' |
| 322 | requestBody: |
| 323 | required: true |
| 324 | content: |
| 325 | application/json: |
| 326 | schema: |
| 327 | type: object |
| 328 | responses: |
| 329 | 200: |
| 330 | $ref: 'components.yaml#/components/responses/Ok' |
| 331 | 400: |
| 332 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 333 | 401: |
| 334 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 335 | 403: |
| 336 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 337 | 404: |
| 338 | $ref: 'components.yaml#/components/responses/NotFound' |
| 339 | |
niamhcore | c309f24 | 2021-09-07 10:27:18 +0100 | [diff] [blame] | 340 | fetchModuleReferencesByCmHandle: |
| 341 | get: |
| 342 | description: fetch all module references (name and revision) for a given cm handle |
| 343 | tags: |
| 344 | - network-cm-proxy |
| 345 | summary: Fetch all module references (name and revision) for a given cm handle |
| 346 | operationId: getModuleReferencesByCmHandle |
| 347 | parameters: |
| 348 | - $ref: 'components.yaml#/components/parameters/cmHandleInPath' |
| 349 | responses: |
| 350 | 200: |
| 351 | description: OK |
| 352 | content: |
| 353 | application/json: |
| 354 | schema: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 355 | type: object |
| 356 | examples: |
| 357 | moduleReferencesResponse: |
| 358 | summary: Sample response |
| 359 | value: |
| 360 | - moduleName: my-module-name |
| 361 | revision: yyyy-mm-dd |
| 362 | - moduleName: my-module-name-2 |
| 363 | revision: yyyy-mm-dd |
niamhcore | c309f24 | 2021-09-07 10:27:18 +0100 | [diff] [blame] | 364 | 400: |
| 365 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 366 | 401: |
| 367 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 368 | 403: |
| 369 | $ref: 'components.yaml#/components/responses/Forbidden' |
| 370 | 404: |
niamhcore | 66017b4 | 2021-10-19 11:07:02 +0100 | [diff] [blame] | 371 | $ref: 'components.yaml#/components/responses/NotFound' |
| 372 | |
| 373 | executeCmHandleSearch: |
| 374 | post: |
| 375 | description: Execute cm handle searches using 'hasAllModules' condition to get all cm handles for the given module names |
| 376 | tags: |
| 377 | - network-cm-proxy |
| 378 | summary: Execute cm handle search using the available conditions |
| 379 | operationId: executeCmHandleSearch |
| 380 | requestBody: |
| 381 | required: true |
| 382 | content: |
| 383 | application/json: |
| 384 | schema: |
| 385 | $ref: 'components.yaml#/components/schemas/Conditions' |
| 386 | responses: |
| 387 | 200: |
| 388 | description: OK |
| 389 | content: |
| 390 | application/json: |
| 391 | schema: |
| 392 | $ref: 'components.yaml#/components/schemas/CmHandles' |
| 393 | 400: |
| 394 | $ref: 'components.yaml#/components/responses/BadRequest' |
| 395 | 401: |
| 396 | $ref: 'components.yaml#/components/responses/Unauthorized' |
| 397 | 403: |
| 398 | $ref: 'components.yaml#/components/responses/Forbidden' |