1 # ============LICENSE_START=======================================================
2 # Copyright (C) 2021-2022 Nordix Foundation
3 # Modifications Copyright (C) 2021 Pantheon.tech
4 # Modifications Copyright (C) 2022 Bell Canada
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
10 # http://www.apache.org/licenses/LICENSE-2.0
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.
18 # SPDX-License-Identifier: Apache-2.0
19 # ============LICENSE_END=========================================================
34 # DMI Server Exception Schema
36 title: DMI Error Message
41 example: "Bad Gateway Error Message NCMP"
52 RestDmiPluginRegistration:
57 example: my-dmi-plugin
61 example: my-dmi-data-plugin
65 example: my-dmi-model-plugin
70 $ref: '#/components/schemas/RestInputCmHandle'
74 $ref: '#/components/schemas/RestInputCmHandle'
76 cmHandle: my-cm-handle
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: '~'
89 example: [my-cm-handle1, my-cm-handle2, my-cm-handle3]
90 DmiPluginRegistrationErrorResponse:
93 failedCreatedCmHandles:
96 $ref: '#/components/schemas/CmHandlerRegistrationErrorResponse'
97 failedUpdatedCmHandles:
100 $ref: '#/components/schemas/CmHandlerRegistrationErrorResponse'
101 failedRemovedCmHandles:
104 $ref: '#/components/schemas/CmHandlerRegistrationErrorResponse'
105 CmHandlerRegistrationErrorResponse:
110 example: my-cm-handle
116 example: 'Unknown error. <error-details>'
125 example: my-cm-handle
127 $ref: '#/components/schemas/RestCmHandleProperties'
128 publicCmHandleProperties:
129 $ref: '#/components/schemas/RestCmHandleProperties'
130 RestCmHandleProperties:
132 additionalProperties:
140 $ref: '#/components/schemas/ConditionsData'
145 $ref: '#/components/schemas/ConditionProperties'
150 example: hasAllModules
152 $ref: '#/components/schemas/ModuleNamesAsJsonArray'
153 ModuleNamesAsJsonArray:
157 $ref: '#/components/schemas/ModuleNameAsJsonObject'
158 example: [my-module-1, my-module-2, my-module-3]
159 ModuleNameAsJsonObject:
170 $ref: '#/components/schemas/CmHandleProperties'
175 $ref: '#/components/schemas/CmHandleProperty'
180 example: my-cm-handle-id
184 title: Module reference details
188 example: my-module-name
191 example: my-module-revision
193 CmHandleQueryRestParameters:
195 title: Cm Handle query parameters for executing cm handle search
197 publicCmHandleProperties:
199 additionalProperties:
205 title: CM handle Details
209 example: my-cm-handle1
210 publicCmHandleProperties:
211 $ref: '#/components/schemas/CmHandlePublicProperties'
213 $ref: '#/components/schemas/RestOutputCmHandleState'
214 CmHandlePublicProperties:
218 additionalProperties:
221 RestOutputCmHandleState:
228 $ref: '#/components/schemas/lock-reason'
231 example: 2022-12-31T20:30:40.000+0000
236 $ref: '#/components/schemas/dataStores'
243 example: LOCKED_OTHER
246 example: locked due to module sync
252 $ref: '#/components/schemas/sync-state'
254 $ref: '#/components/schemas/sync-state'
261 example: NONE_REQUESTED
264 example: 2022-12-31T20:30:40.000+0000
266 RestOutputCmHandlePublicProperties:
269 publicCmHandleProperties:
270 $ref: '#/components/schemas/CmHandlePublicProperties'
274 summary: Sample request
275 description: Sample request body
278 bookstore-name: Chapters
292 dataSamplePatchRequest:
293 summary: Sample patch request
294 description: Sample patch request body
296 ietf-restconf:yang-patch:
304 bookstore-name: Chapters
322 bookstore-name: Novels
337 summary: Sample response
338 description: Sample response for selecting 'sample 1'.
358 description: The identifier for a network function, network element, subnetwork or any other cm object by managed Network CM Proxy
362 example: my-cm-handle
371 requiredXpathInQuery:
378 includeDescendantsOptionInQuery:
379 name: include-descendants
381 description: include-descendants
389 description: cps-path
394 resourceIdentifierInQuery:
395 name: resourceIdentifier
397 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.
405 resourceIdentifier: \shops\bookstore
408 resourceIdentifier: \shops\bookstore\categories[@code=1]
411 resourceIdentifier: parent=shops,child=bookstore
415 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.
426 options: (fields=book)
429 options: (depth=2,fields=book/authors)
433 description: topic parameter in query.
442 contentParamInHeader:
446 description: Content parameter for request, if content parameter is null, default value is application/json.
449 default: application/json
450 example: application/yang-data+json
454 description: The specified resource was not found
458 $ref: '#/components/schemas/ErrorMessage'
461 message: Not found error message
462 details: Not found error details
464 description: Unauthorized
468 $ref: '#/components/schemas/ErrorMessage'
471 message: Unauthorized error message
472 details: Unauthorized error details
474 description: Forbidden
478 $ref: '#/components/schemas/ErrorMessage'
481 message: Forbidden error message
482 details: Forbidden error details
484 description: Bad Request
488 $ref: '#/components/schemas/ErrorMessage'
490 status: 400 BAD_REQUEST
491 message: Bad request error message
492 details: Bad request error details
494 description: Conflict
498 $ref: '#/components/schemas/ErrorMessage'
501 message: Conflict error message
502 details: Conflict error details
504 description: The given path has not been implemented
508 $ref: '#/components/schemas/ErrorMessage'
511 message: Not implemented error message
512 details: Not implemented error details
523 description: No Content
526 description: Internal Server Error
530 $ref: "#/components/schemas/ErrorMessage"
533 message: Internal Server Error
534 details: Internal Server Error occurred
536 description: Bad Gateway
540 $ref: "#/components/schemas/DmiErrorMessage"
542 message: "Bad Gateway Error Message NCMP"