tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 1 | # ============LICENSE_START======================================================= |
DylanB95EST | 63132ce | 2021-12-14 16:34:38 +0000 | [diff] [blame] | 2 | # Copyright (C) 2021-2022 Nordix Foundation |
Ruslan Kashapov | 1baf48d | 2021-05-07 10:46:27 +0300 | [diff] [blame] | 3 | # Modifications Copyright (C) 2021 Pantheon.tech |
puthuparambil.aditya | d69742c | 2022-03-29 11:03:52 +0100 | [diff] [blame] | 4 | # Modifications Copyright (C) 2022 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 | |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 21 | components: |
| 22 | schemas: |
niamhcore | 66017b4 | 2021-10-19 11:07:02 +0100 | [diff] [blame] | 23 | # Common Schemas |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 24 | ErrorMessage: |
| 25 | type: object |
| 26 | title: Error |
| 27 | properties: |
| 28 | status: |
| 29 | type: string |
| 30 | message: |
| 31 | type: string |
| 32 | details: |
| 33 | type: string |
mpriyank | 93afc1e | 2022-03-28 15:47:47 +0530 | [diff] [blame] | 34 | # DMI Server Exception Schema |
| 35 | DmiErrorMessage: |
| 36 | title: DMI Error Message |
| 37 | type: object |
| 38 | properties: |
| 39 | message: |
| 40 | type: string |
| 41 | example: "Bad Gateway Error Message NCMP" |
| 42 | dmi-response: |
| 43 | type: object |
| 44 | properties: |
| 45 | http-code: |
| 46 | type: integer |
| 47 | example: 400 |
| 48 | body: |
| 49 | type: string |
| 50 | example: Bad Request |
niamhcore | 66017b4 | 2021-10-19 11:07:02 +0100 | [diff] [blame] | 51 | # Request Schemas |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 52 | RestDmiPluginRegistration: |
| 53 | type: object |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 54 | properties: |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 55 | dmiPlugin: |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 56 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 57 | example: my-dmi-plugin |
DylanB95EST | d042fcd | 2022-02-21 12:57:08 +0000 | [diff] [blame] | 58 | default: "" |
JosephKeenan | 20b4f9c | 2021-11-23 12:18:28 +0000 | [diff] [blame] | 59 | dmiDataPlugin: |
| 60 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 61 | example: my-dmi-data-plugin |
DylanB95EST | d042fcd | 2022-02-21 12:57:08 +0000 | [diff] [blame] | 62 | default: "" |
JosephKeenan | 20b4f9c | 2021-11-23 12:18:28 +0000 | [diff] [blame] | 63 | dmiModelPlugin: |
| 64 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 65 | example: my-dmi-model-plugin |
DylanB95EST | d042fcd | 2022-02-21 12:57:08 +0000 | [diff] [blame] | 66 | default: "" |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 67 | createdCmHandles: |
| 68 | type: array |
| 69 | items: |
DylanB95EST | e557338 | 2022-01-27 17:12:52 +0000 | [diff] [blame] | 70 | $ref: '#/components/schemas/RestInputCmHandle' |
DylanB95EST | 31facc8 | 2021-08-18 17:12:25 +0100 | [diff] [blame] | 71 | updatedCmHandles: |
| 72 | type: array |
| 73 | items: |
DylanB95EST | e557338 | 2022-01-27 17:12:52 +0000 | [diff] [blame] | 74 | $ref: '#/components/schemas/RestInputCmHandle' |
Renu Kumari | 2c96317 | 2022-03-10 16:02:55 -0500 | [diff] [blame] | 75 | example: |
| 76 | cmHandle: my-cm-handle |
| 77 | cmHandleProperties: |
| 78 | add-my-property: add-property |
| 79 | update-my-property: updated-property |
| 80 | delete-my-property: '~' |
| 81 | publicCmHandleProperties: |
| 82 | add-my-property: add-property |
| 83 | update-my-property: updated-property |
| 84 | delete-my-property: '~' |
DylanB95EST | e999b02 | 2021-08-24 16:56:40 +0100 | [diff] [blame] | 85 | removedCmHandles: |
| 86 | type: array |
| 87 | items: |
| 88 | type: string |
Renu Kumari | 2c96317 | 2022-03-10 16:02:55 -0500 | [diff] [blame] | 89 | example: [my-cm-handle1, my-cm-handle2, my-cm-handle3] |
Renu Kumari | b14f04b | 2022-03-28 10:22:41 -0400 | [diff] [blame] | 90 | DmiPluginRegistrationErrorResponse: |
| 91 | type: object |
| 92 | properties: |
| 93 | failedCreatedCmHandles: |
| 94 | type: array |
| 95 | items: |
| 96 | $ref: '#/components/schemas/CmHandlerRegistrationErrorResponse' |
Renu Kumari | b14f04b | 2022-03-28 10:22:41 -0400 | [diff] [blame] | 97 | failedUpdatedCmHandles: |
| 98 | type: array |
| 99 | items: |
| 100 | $ref: '#/components/schemas/CmHandlerRegistrationErrorResponse' |
Renu Kumari | b14f04b | 2022-03-28 10:22:41 -0400 | [diff] [blame] | 101 | failedRemovedCmHandles: |
| 102 | type: array |
| 103 | items: |
| 104 | $ref: '#/components/schemas/CmHandlerRegistrationErrorResponse' |
Renu Kumari | b14f04b | 2022-03-28 10:22:41 -0400 | [diff] [blame] | 105 | CmHandlerRegistrationErrorResponse: |
| 106 | type: object |
| 107 | properties: |
| 108 | cmHandle: |
| 109 | type: string |
| 110 | example: my-cm-handle |
| 111 | errorCode: |
| 112 | type: string |
Renu Kumari | 952603c | 2022-04-18 12:39:33 -0400 | [diff] [blame] | 113 | example: '00' |
Renu Kumari | b14f04b | 2022-03-28 10:22:41 -0400 | [diff] [blame] | 114 | errorText: |
| 115 | type: string |
Renu Kumari | 952603c | 2022-04-18 12:39:33 -0400 | [diff] [blame] | 116 | example: 'Unknown error. <error-details>' |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 117 | |
DylanB95EST | e557338 | 2022-01-27 17:12:52 +0000 | [diff] [blame] | 118 | RestInputCmHandle: |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 119 | required: |
| 120 | - cmHandle |
| 121 | type: object |
| 122 | properties: |
| 123 | cmHandle: |
| 124 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 125 | example: my-cm-handle |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 126 | cmHandleProperties: |
DylanB95EST | 63132ce | 2021-12-14 16:34:38 +0000 | [diff] [blame] | 127 | $ref: '#/components/schemas/RestCmHandleProperties' |
| 128 | publicCmHandleProperties: |
| 129 | $ref: '#/components/schemas/RestCmHandleProperties' |
| 130 | RestCmHandleProperties: |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 131 | type: object |
| 132 | additionalProperties: |
| 133 | type: string |
DylanB95EST | 63132ce | 2021-12-14 16:34:38 +0000 | [diff] [blame] | 134 | example: my-property |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 135 | |
niamhcore | 66017b4 | 2021-10-19 11:07:02 +0100 | [diff] [blame] | 136 | #Response Schemas |
lukegleeson | d5bda88 | 2022-03-02 14:32:47 +0000 | [diff] [blame] | 137 | RestModuleReference: |
puthuparambil.aditya | d000733 | 2021-12-08 18:53:39 +0000 | [diff] [blame] | 138 | type: object |
| 139 | title: Module reference details |
| 140 | properties: |
| 141 | moduleName: |
| 142 | type: string |
| 143 | example: my-module-name |
| 144 | revision: |
| 145 | type: string |
| 146 | example: my-module-revision |
| 147 | |
kissand | e9ed581 | 2022-05-12 15:59:18 +0200 | [diff] [blame^] | 148 | CmHandleQueryParameters: |
JosephKeenan | deac477 | 2022-03-28 12:26:07 +0100 | [diff] [blame] | 149 | type: object |
| 150 | title: Cm Handle query parameters for executing cm handle search |
| 151 | properties: |
kissand | e9ed581 | 2022-05-12 15:59:18 +0200 | [diff] [blame^] | 152 | cmHandleQueryParameters: |
| 153 | type: array |
| 154 | items: |
| 155 | type: object |
| 156 | $ref: '#/components/schemas/ConditionProperties' |
| 157 | conditions: |
| 158 | deprecated: true |
| 159 | type: array |
| 160 | items: |
| 161 | type: object |
| 162 | $ref: '#/components/schemas/OldConditionProperties' |
| 163 | description: not necessary, it is just for backward compatibility |
| 164 | example: |
| 165 | cmHandleQueryParameters: |
| 166 | - conditionName: hasAllModules |
| 167 | conditionParameters: |
| 168 | - { "moduleName": "my-module-1" } |
| 169 | - { "moduleName": "my-module-2" } |
| 170 | - { "moduleName": "my-module-3" } |
| 171 | - conditionName: hasAllProperties |
| 172 | conditionParameters: |
| 173 | - { "Color": "yellow" } |
| 174 | - { "Shape": "circle" } |
| 175 | - { "Size": "small" } |
| 176 | ConditionProperties: |
| 177 | properties: |
| 178 | conditionName: |
| 179 | type: string |
| 180 | conditionParameters: |
| 181 | type: array |
| 182 | items: |
| 183 | type: object |
| 184 | additionalProperties: |
| 185 | type: string |
| 186 | OldConditionProperties: |
| 187 | deprecated: true |
| 188 | properties: |
| 189 | name: |
| 190 | type: string |
| 191 | conditionParameters: |
| 192 | type: array |
| 193 | items: |
| 194 | type: object |
| 195 | $ref: '#/components/schemas/ModuleNameAsJsonObject' |
| 196 | ModuleNameAsJsonObject: |
| 197 | properties: |
| 198 | moduleName: |
| 199 | type: string |
| 200 | example: my-module |
JosephKeenan | deac477 | 2022-03-28 12:26:07 +0100 | [diff] [blame] | 201 | |
DylanB95EST | e557338 | 2022-01-27 17:12:52 +0000 | [diff] [blame] | 202 | RestOutputCmHandle: |
| 203 | type: object |
| 204 | title: CM handle Details |
| 205 | properties: |
| 206 | cmHandle: |
| 207 | type: string |
| 208 | example: my-cm-handle1 |
| 209 | publicCmHandleProperties: |
| 210 | $ref: '#/components/schemas/CmHandlePublicProperties' |
mpriyank | 4cf4962 | 2022-05-20 15:25:15 +0100 | [diff] [blame] | 211 | state: |
| 212 | $ref: '#/components/schemas/RestOutputCmHandleState' |
DylanB95EST | e557338 | 2022-01-27 17:12:52 +0000 | [diff] [blame] | 213 | CmHandlePublicProperties: |
| 214 | type: array |
| 215 | items: |
| 216 | type: object |
| 217 | additionalProperties: |
| 218 | type: string |
| 219 | example: Book Type |
mpriyank | 4cf4962 | 2022-05-20 15:25:15 +0100 | [diff] [blame] | 220 | RestOutputCmHandleState: |
| 221 | type: object |
| 222 | properties: |
| 223 | cmHandleState: |
| 224 | type: string |
| 225 | example: ADVISED |
| 226 | lockReason: |
| 227 | $ref: '#/components/schemas/lock-reason' |
| 228 | lastUpdateTime: |
| 229 | type: string |
| 230 | example: 2022-12-31T20:30:40.000+0000 |
| 231 | dataSyncEnabled: |
| 232 | type: boolean |
| 233 | example: false |
| 234 | dataSyncState: |
| 235 | $ref: '#/components/schemas/dataStores' |
| 236 | |
| 237 | lock-reason: |
| 238 | type: object |
| 239 | properties: |
| 240 | reason: |
| 241 | type: string |
| 242 | example: LOCKED_OTHER |
| 243 | details: |
| 244 | type: string |
| 245 | example: locked due to module sync |
| 246 | |
| 247 | dataStores: |
| 248 | type: object |
| 249 | properties: |
| 250 | operational: |
| 251 | $ref: '#/components/schemas/sync-state' |
| 252 | running: |
| 253 | $ref: '#/components/schemas/sync-state' |
| 254 | |
| 255 | sync-state: |
| 256 | type: object |
| 257 | properties: |
| 258 | state: |
| 259 | type: string |
| 260 | example: NONE_REQUESTED |
| 261 | lastSyncTime: |
| 262 | type: string |
| 263 | example: 2022-12-31T20:30:40.000+0000 |
DylanB95EST | e557338 | 2022-01-27 17:12:52 +0000 | [diff] [blame] | 264 | |
lukegleeson | bed18fd | 2022-05-06 12:02:42 +0100 | [diff] [blame] | 265 | RestOutputCmHandlePublicProperties: |
| 266 | type: object |
| 267 | properties: |
| 268 | publicCmHandleProperties: |
| 269 | $ref: '#/components/schemas/CmHandlePublicProperties' |
| 270 | |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 271 | examples: |
| 272 | dataSampleRequest: |
| 273 | summary: Sample request |
| 274 | description: Sample request body |
| 275 | value: |
| 276 | test:bookstore: |
| 277 | bookstore-name: Chapters |
| 278 | categories: |
| 279 | - code: '01' |
| 280 | name: SciFi |
| 281 | books: |
| 282 | - authors: |
| 283 | - Iain M. Banks |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 284 | - Ursula K. Le Guin |
| 285 | - code: '02' |
| 286 | name: kids |
| 287 | books: |
| 288 | - authors: |
| 289 | - Philip Pullman |
| 290 | |
tragait | ecd7f5e | 2022-01-13 13:15:14 +0000 | [diff] [blame] | 291 | dataSamplePatchRequest: |
| 292 | summary: Sample patch request |
| 293 | description: Sample patch request body |
| 294 | value: |
| 295 | ietf-restconf:yang-patch: |
| 296 | patch-id: patch-1 |
| 297 | edit: |
| 298 | - edit-id: edit1 |
| 299 | operation: merge |
| 300 | target: / |
| 301 | value: |
| 302 | test:bookstore: |
| 303 | bookstore-name: Chapters |
| 304 | categories: |
| 305 | - code: '01' |
| 306 | name: Science |
| 307 | books: |
| 308 | - authors: |
| 309 | - Author1 |
| 310 | - Author2 |
| 311 | - code: '02' |
| 312 | name: Arts |
| 313 | books: |
| 314 | - authors: |
| 315 | - Author3 |
| 316 | - edit-id: edit2 |
| 317 | operation: merge |
| 318 | target: / |
| 319 | value: |
| 320 | test:bookstore: |
| 321 | bookstore-name: Novels |
| 322 | categories: |
| 323 | - code: '03' |
| 324 | name: History |
| 325 | books: |
| 326 | - authors: |
| 327 | - Iain M. Banks |
| 328 | - Ursula K. Le Guin |
| 329 | - code: '04' |
| 330 | name: Fiction |
| 331 | books: |
| 332 | - authors: |
| 333 | - Philip Pullman |
| 334 | |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 335 | dataSampleResponse: |
| 336 | summary: Sample response |
| 337 | description: Sample response for selecting 'sample 1'. |
| 338 | value: |
| 339 | bookstore: |
| 340 | categories: |
| 341 | - code: '01' |
| 342 | books: |
puthuparambil.aditya | d000733 | 2021-12-08 18:53:39 +0000 | [diff] [blame] | 343 | - authors: |
| 344 | - Iain M. Banks |
| 345 | - Ursula K. Le Guin |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 346 | name: SciFi |
| 347 | - code: '02' |
| 348 | books: |
puthuparambil.aditya | d000733 | 2021-12-08 18:53:39 +0000 | [diff] [blame] | 349 | - authors: |
| 350 | - Philip Pullman |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 351 | name: kids |
niamhcore | 66017b4 | 2021-10-19 11:07:02 +0100 | [diff] [blame] | 352 | |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 353 | parameters: |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 354 | cmHandleInPath: |
| 355 | name: cm-handle |
| 356 | in: path |
tragait | 34a94b9 | 2021-03-30 12:02:27 +0100 | [diff] [blame] | 357 | description: The identifier for a network function, network element, subnetwork or any other cm object by managed Network CM Proxy |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 358 | required: true |
| 359 | schema: |
| 360 | type: string |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 361 | example: my-cm-handle |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 362 | xpathInQuery: |
| 363 | name: xpath |
| 364 | in: query |
| 365 | description: xpath |
| 366 | required: false |
| 367 | schema: |
| 368 | type: string |
| 369 | default: / |
Ruslan Kashapov | 1baf48d | 2021-05-07 10:46:27 +0300 | [diff] [blame] | 370 | requiredXpathInQuery: |
| 371 | name: xpath |
| 372 | in: query |
| 373 | description: xpath |
| 374 | required: true |
| 375 | schema: |
| 376 | type: string |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 377 | includeDescendantsOptionInQuery: |
| 378 | name: include-descendants |
| 379 | in: query |
| 380 | description: include-descendants |
| 381 | required: false |
| 382 | schema: |
| 383 | type: boolean |
| 384 | default: false |
niamhcore | b5d573b | 2021-02-26 10:13:48 +0000 | [diff] [blame] | 385 | cpsPathInQuery: |
| 386 | name: cps-path |
| 387 | in: query |
| 388 | description: cps-path |
| 389 | required: false |
| 390 | schema: |
| 391 | type: string |
| 392 | default: / |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 393 | resourceIdentifierInQuery: |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 394 | name: resourceIdentifier |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 395 | in: query |
| 396 | description: The format of resource identifier depend on the associated DMI Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but it can really be anything. |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 397 | required: true |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 398 | allowReserved: true |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 399 | schema: |
| 400 | type: string |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 401 | examples: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 402 | sample 1: |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 403 | value: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 404 | resourceIdentifier: \shops\bookstore |
| 405 | sample 2: |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 406 | value: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 407 | resourceIdentifier: \shops\bookstore\categories[@code=1] |
| 408 | sample 3: |
niamhcore | fd2e6dd | 2021-09-29 16:43:35 +0100 | [diff] [blame] | 409 | value: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 410 | resourceIdentifier: parent=shops,child=bookstore |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 411 | optionsParamInQuery: |
| 412 | name: options |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 413 | in: query |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 414 | description: options parameter in query, it is mandatory to wrap key(s)=value(s) in parenthesis'()'. The format of options parameter depend on the associated DMI Plugin implementation. |
tragait | c328551 | 2021-08-16 15:12:36 +0100 | [diff] [blame] | 415 | required: false |
| 416 | schema: |
| 417 | type: string |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 418 | allowReserved: true |
| 419 | examples: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 420 | sample 1: |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 421 | value: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 422 | options: (depth=3) |
| 423 | sample 2: |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 424 | value: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 425 | options: (fields=book) |
| 426 | sample 3: |
tragait | abdff1b | 2021-10-06 11:04:18 +0100 | [diff] [blame] | 427 | value: |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 428 | options: (depth=2,fields=book/authors) |
sourabh_sourabh | 1f2e66e | 2022-02-16 21:53:41 +0530 | [diff] [blame] | 429 | topicParamInQuery: |
| 430 | name: topic |
| 431 | in: query |
| 432 | description: topic parameter in query. |
| 433 | required: false |
| 434 | schema: |
| 435 | type: string |
| 436 | allowReserved: true |
| 437 | examples: |
| 438 | sample 1: |
| 439 | value: |
| 440 | topic: my-topic-name |
tragait | c584bf2 | 2021-08-20 15:45:58 +0100 | [diff] [blame] | 441 | contentParamInHeader: |
| 442 | name: Content-Type |
| 443 | in: header |
| 444 | required: false |
| 445 | description: Content parameter for request, if content parameter is null, default value is application/json. |
| 446 | schema: |
| 447 | type: string |
| 448 | default: application/json |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 449 | example: application/yang-data+json |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 450 | |
| 451 | responses: |
| 452 | NotFound: |
| 453 | description: The specified resource was not found |
| 454 | content: |
| 455 | application/json: |
| 456 | schema: |
| 457 | $ref: '#/components/schemas/ErrorMessage' |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 458 | example: |
| 459 | status: 400 |
| 460 | message: Not found error message |
| 461 | details: Not found error details |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 462 | Unauthorized: |
| 463 | description: Unauthorized |
| 464 | content: |
| 465 | application/json: |
| 466 | schema: |
| 467 | $ref: '#/components/schemas/ErrorMessage' |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 468 | example: |
| 469 | status: 401 |
| 470 | message: Unauthorized error message |
| 471 | details: Unauthorized error details |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 472 | Forbidden: |
| 473 | description: Forbidden |
| 474 | content: |
| 475 | application/json: |
| 476 | schema: |
| 477 | $ref: '#/components/schemas/ErrorMessage' |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 478 | example: |
| 479 | status: 403 |
| 480 | message: Forbidden error message |
| 481 | details: Forbidden error details |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 482 | BadRequest: |
| 483 | description: Bad Request |
| 484 | content: |
| 485 | application/json: |
| 486 | schema: |
| 487 | $ref: '#/components/schemas/ErrorMessage' |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 488 | example: |
| 489 | status: 400 BAD_REQUEST |
| 490 | message: Bad request error message |
| 491 | details: Bad request error details |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 492 | Conflict: |
| 493 | description: Conflict |
| 494 | content: |
| 495 | application/json: |
| 496 | schema: |
| 497 | $ref: '#/components/schemas/ErrorMessage' |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 498 | example: |
| 499 | status: 409 CONFLICT |
| 500 | message: Conflict error message |
| 501 | details: Conflict error details |
Hanif Kukkalli | 83e318f | 2021-02-23 12:26:39 +0100 | [diff] [blame] | 502 | NotImplemented: |
| 503 | description: The given path has not been implemented |
| 504 | content: |
| 505 | application/json: |
| 506 | schema: |
| 507 | $ref: '#/components/schemas/ErrorMessage' |
emaclee | 844cab3 | 2021-12-01 09:42:37 +0000 | [diff] [blame] | 508 | example: |
| 509 | status: 501 |
| 510 | message: Not implemented error message |
| 511 | details: Not implemented error details |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 512 | Ok: |
| 513 | description: OK |
| 514 | content: |
| 515 | application/json: |
| 516 | schema: |
| 517 | type: object |
| 518 | Created: |
| 519 | description: Created |
DylanB95EST | 4f4178c | 2021-07-02 13:30:42 +0100 | [diff] [blame] | 520 | content: {} |
Ruslan Kashapov | 9f52f60 | 2021-01-22 12:53:01 +0200 | [diff] [blame] | 521 | NoContent: |
| 522 | description: No Content |
| 523 | content: {} |
JosephKeenan | e0873dd | 2022-01-28 11:22:22 +0000 | [diff] [blame] | 524 | InternalServerError: |
| 525 | description: Internal Server Error |
| 526 | content: |
| 527 | application/json: |
| 528 | schema: |
| 529 | $ref: "#/components/schemas/ErrorMessage" |
| 530 | example: |
| 531 | status: 500 |
| 532 | message: Internal Server Error |
| 533 | details: Internal Server Error occurred |
mpriyank | 93afc1e | 2022-03-28 15:47:47 +0530 | [diff] [blame] | 534 | BadGateway: |
| 535 | description: Bad Gateway |
| 536 | content: |
| 537 | application/json: |
| 538 | schema: |
| 539 | $ref: "#/components/schemas/DmiErrorMessage" |
| 540 | example: |
| 541 | message: "Bad Gateway Error Message NCMP" |
| 542 | dmi-response: |
| 543 | http-code: 400 |
| 544 | body: "Bad Request" |