Structured Exception details for DMI
[cps.git] / docs / api / swagger / ncmp / openapi.yaml
1 openapi: 3.0.1
2 info:
3   title: NCMP to CPS Proxy API
4   description: NCMP to CPS Proxy API
5   version: "1.0"
6 servers:
7 - url: /ncmp
8 paths:
9   /v1/ch/{cm-handle}/data/ds/ncmp-datastore:passthrough-operational:
10     get:
11       tags:
12       - network-cm-proxy
13       summary: Get resource data from pass-through operational for cm handle
14       description: Get resource data from pass-through operational for given cm handle
15       operationId: getResourceDataOperationalForCmHandle
16       parameters:
17       - name: cm-handle
18         in: path
19         description: "The identifier for a network function, network element, subnetwork\
20           \ or any other cm object by managed Network CM Proxy"
21         required: true
22         schema:
23           type: string
24           example: my-cm-handle
25       - name: resourceIdentifier
26         in: query
27         description: The format of resource identifier depend on the associated DMI
28           Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
29           it can really be anything.
30         required: true
31         allowReserved: true
32         schema:
33           type: string
34         examples:
35           sample 1:
36             value:
37               resourceIdentifier: \shops\bookstore
38           sample 2:
39             value:
40               resourceIdentifier: "\\shops\\bookstore\\categories[@code=1]"
41           sample 3:
42             value:
43               resourceIdentifier: "parent=shops,child=bookstore"
44       - name: Accept
45         in: header
46         description: "Accept parameter for response, if accept parameter is null,\
47           \ that means client can accept any format."
48         required: false
49         schema:
50           type: string
51           enum:
52           - application/json
53           - application/yang-data+json
54       - name: options
55         in: query
56         description: "options parameter in query, it is mandatory to wrap key(s)=value(s)\
57           \ in parenthesis'()'. The format of options parameter depend on the associated\
58           \ DMI Plugin implementation."
59         required: false
60         allowReserved: true
61         schema:
62           type: string
63         examples:
64           sample 1:
65             value:
66               options: (depth=3)
67           sample 2:
68             value:
69               options: (fields=book)
70           sample 3:
71             value:
72               options: "(depth=2,fields=book/authors)"
73       - name: topic
74         in: query
75         description: topic parameter in query.
76         required: false
77         allowReserved: true
78         schema:
79           type: string
80         examples:
81           sample 1:
82             value:
83               topic: my-topic-name
84       responses:
85         "200":
86           description: OK
87           content:
88             application/json:
89               schema:
90                 type: object
91               examples:
92                 dataSampleResponse:
93                   $ref: '#/components/examples/dataSampleResponse'
94         "400":
95           description: Bad Request
96           content:
97             application/json:
98               schema:
99                 $ref: '#/components/schemas/ErrorMessage'
100               example:
101                 status: 400 BAD_REQUEST
102                 message: Bad request error message
103                 details: Bad request error details
104         "401":
105           description: Unauthorized
106           content:
107             application/json:
108               schema:
109                 $ref: '#/components/schemas/ErrorMessage'
110               example:
111                 status: 401
112                 message: Unauthorized error message
113                 details: Unauthorized error details
114         "403":
115           description: Forbidden
116           content:
117             application/json:
118               schema:
119                 $ref: '#/components/schemas/ErrorMessage'
120               example:
121                 status: 403
122                 message: Forbidden error message
123                 details: Forbidden error details
124         "500":
125           description: Internal Server Error
126           content:
127             application/json:
128               schema:
129                 $ref: '#/components/schemas/ErrorMessage'
130               example:
131                 status: 500
132                 message: Internal Server Error
133                 details: Internal Server Error occurred
134         "502":
135           description: Bad Gateway
136           content:
137             application/json:
138               schema:
139                 $ref: '#/components/schemas/DmiErrorMessage'
140               example:
141                 message: "Bad Gateway Error Message NCMP"
142                 dmi-response:
143                   http-code: 400
144                   body: Bad Request
145
146   /v1/ch/{cm-handle}/data/ds/ncmp-datastore:passthrough-running:
147     get:
148       tags:
149       - network-cm-proxy
150       summary: Get resource data from pass-through running for cm handle
151       description: Get resource data from pass-through running for given cm handle
152       operationId: getResourceDataRunningForCmHandle
153       parameters:
154       - name: cm-handle
155         in: path
156         description: "The identifier for a network function, network element, subnetwork\
157           \ or any other cm object by managed Network CM Proxy"
158         required: true
159         schema:
160           type: string
161           example: my-cm-handle
162       - name: resourceIdentifier
163         in: query
164         description: The format of resource identifier depend on the associated DMI
165           Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
166           it can really be anything.
167         required: true
168         allowReserved: true
169         schema:
170           type: string
171         examples:
172           sample 1:
173             value:
174               resourceIdentifier: \shops\bookstore
175           sample 2:
176             value:
177               resourceIdentifier: "\\shops\\bookstore\\categories[@code=1]"
178           sample 3:
179             value:
180               resourceIdentifier: "parent=shops,child=bookstore"
181       - name: Accept
182         in: header
183         description: "Accept parameter for response, if accept parameter is null,\
184           \ that means client can accept any format."
185         required: false
186         schema:
187           type: string
188           enum:
189           - application/json
190           - application/yang-data+json
191       - name: options
192         in: query
193         description: "options parameter in query, it is mandatory to wrap key(s)=value(s)\
194           \ in parenthesis'()'. The format of options parameter depend on the associated\
195           \ DMI Plugin implementation."
196         required: false
197         allowReserved: true
198         schema:
199           type: string
200         examples:
201           sample 1:
202             value:
203               options: (depth=3)
204           sample 2:
205             value:
206               options: (fields=book)
207           sample 3:
208             value:
209               options: "(depth=2,fields=book/authors)"
210       - name: topic
211         in: query
212         description: topic parameter in query.
213         required: false
214         allowReserved: true
215         schema:
216           type: string
217         examples:
218           sample 1:
219             value:
220               topic: my-topic-name
221       responses:
222         "200":
223           description: OK
224           content:
225             application/json:
226               schema:
227                 type: object
228               examples:
229                 dataSampleResponse:
230                   $ref: '#/components/examples/dataSampleResponse'
231         "400":
232           description: Bad Request
233           content:
234             application/json:
235               schema:
236                 $ref: '#/components/schemas/ErrorMessage'
237               example:
238                 status: 400 BAD_REQUEST
239                 message: Bad request error message
240                 details: Bad request error details
241         "401":
242           description: Unauthorized
243           content:
244             application/json:
245               schema:
246                 $ref: '#/components/schemas/ErrorMessage'
247               example:
248                 status: 401
249                 message: Unauthorized error message
250                 details: Unauthorized error details
251         "403":
252           description: Forbidden
253           content:
254             application/json:
255               schema:
256                 $ref: '#/components/schemas/ErrorMessage'
257               example:
258                 status: 403
259                 message: Forbidden error message
260                 details: Forbidden error details
261         "500":
262           description: Internal Server Error
263           content:
264             application/json:
265               schema:
266                 $ref: '#/components/schemas/ErrorMessage'
267               example:
268                 status: 500
269                 message: Internal Server Error
270                 details: Internal Server Error occurred
271         "502":
272           description: Bad Gateway
273           content:
274             application/json:
275               schema:
276                 $ref: '#/components/schemas/DmiErrorMessage'
277               example:
278                 message: "Bad Gateway Error Message NCMP"
279                 dmi-response:
280                   http-code: 400
281                   body: Bad Request
282     put:
283       tags:
284       - network-cm-proxy
285       summary: Update resource data from pass-through running for a cm handle
286       description: Update resource data from pass-through running for the given cm
287         handle
288       operationId: updateResourceDataRunningForCmHandle
289       parameters:
290       - name: cm-handle
291         in: path
292         description: "The identifier for a network function, network element, subnetwork\
293           \ or any other cm object by managed Network CM Proxy"
294         required: true
295         schema:
296           type: string
297           example: my-cm-handle
298       - name: resourceIdentifier
299         in: query
300         description: The format of resource identifier depend on the associated DMI
301           Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
302           it can really be anything.
303         required: true
304         allowReserved: true
305         schema:
306           type: string
307         examples:
308           sample 1:
309             value:
310               resourceIdentifier: \shops\bookstore
311           sample 2:
312             value:
313               resourceIdentifier: "\\shops\\bookstore\\categories[@code=1]"
314           sample 3:
315             value:
316               resourceIdentifier: "parent=shops,child=bookstore"
317       - name: Content-Type
318         in: header
319         description: "Content parameter for request, if content parameter is null,\
320           \ default value is application/json."
321         required: false
322         schema:
323           type: string
324           example: application/yang-data+json
325           default: application/json
326       requestBody:
327         content:
328           application/json:
329             schema:
330               type: object
331             examples:
332               dataSampleRequest:
333                 $ref: '#/components/examples/dataSampleRequest'
334           application/yang-data+json:
335             schema:
336               type: object
337             examples:
338               dataSampleRequest:
339                 $ref: '#/components/examples/dataSampleRequest'
340         required: true
341       responses:
342         "200":
343           description: OK
344           content:
345             application/json:
346               schema:
347                 type: object
348         "400":
349           description: Bad Request
350           content:
351             application/json:
352               schema:
353                 $ref: '#/components/schemas/ErrorMessage'
354               example:
355                 status: 400 BAD_REQUEST
356                 message: Bad request error message
357                 details: Bad request error details
358         "401":
359           description: Unauthorized
360           content:
361             application/json:
362               schema:
363                 $ref: '#/components/schemas/ErrorMessage'
364               example:
365                 status: 401
366                 message: Unauthorized error message
367                 details: Unauthorized error details
368         "403":
369           description: Forbidden
370           content:
371             application/json:
372               schema:
373                 $ref: '#/components/schemas/ErrorMessage'
374               example:
375                 status: 403
376                 message: Forbidden error message
377                 details: Forbidden error details
378         "500":
379           description: Internal Server Error
380           content:
381             application/json:
382               schema:
383                 $ref: '#/components/schemas/ErrorMessage'
384               example:
385                 status: 500
386                 message: Internal Server Error
387                 details: Internal Server Error occurred
388         "502":
389           description: Bad Gateway
390           content:
391             application/json:
392               schema:
393                 $ref: '#/components/schemas/DmiErrorMessage'
394               example:
395                 message: "Bad Gateway Error Message NCMP"
396                 dmi-response:
397                   http-code: 400
398                   body: Bad Request
399     post:
400       tags:
401       - network-cm-proxy
402       summary: create resource data from pass-through running for cm handle
403       description: create resource data from pass-through running for given cm handle
404       operationId: createResourceDataRunningForCmHandle
405       parameters:
406       - name: cm-handle
407         in: path
408         description: "The identifier for a network function, network element, subnetwork\
409           \ or any other cm object by managed Network CM Proxy"
410         required: true
411         schema:
412           type: string
413           example: my-cm-handle
414       - name: resourceIdentifier
415         in: query
416         description: The format of resource identifier depend on the associated DMI
417           Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
418           it can really be anything.
419         required: true
420         allowReserved: true
421         schema:
422           type: string
423         examples:
424           sample 1:
425             value:
426               resourceIdentifier: \shops\bookstore
427           sample 2:
428             value:
429               resourceIdentifier: "\\shops\\bookstore\\categories[@code=1]"
430           sample 3:
431             value:
432               resourceIdentifier: "parent=shops,child=bookstore"
433       - name: Content-Type
434         in: header
435         description: "Content parameter for request, if content parameter is null,\
436           \ default value is application/json."
437         required: false
438         schema:
439           type: string
440           example: application/yang-data+json
441           default: application/json
442       requestBody:
443         content:
444           application/json:
445             schema:
446               type: object
447             examples:
448               dataSampleRequest:
449                 $ref: '#/components/examples/dataSampleRequest'
450           application/yang-data+json:
451             schema:
452               type: object
453             examples:
454               dataSampleRequest:
455                 $ref: '#/components/examples/dataSampleRequest'
456         required: true
457       responses:
458         "201":
459           description: Created
460           content: {}
461         "400":
462           description: Bad Request
463           content:
464             application/json:
465               schema:
466                 $ref: '#/components/schemas/ErrorMessage'
467               example:
468                 status: 400 BAD_REQUEST
469                 message: Bad request error message
470                 details: Bad request error details
471         "401":
472           description: Unauthorized
473           content:
474             application/json:
475               schema:
476                 $ref: '#/components/schemas/ErrorMessage'
477               example:
478                 status: 401
479                 message: Unauthorized error message
480                 details: Unauthorized error details
481         "403":
482           description: Forbidden
483           content:
484             application/json:
485               schema:
486                 $ref: '#/components/schemas/ErrorMessage'
487               example:
488                 status: 403
489                 message: Forbidden error message
490                 details: Forbidden error details
491         "500":
492           description: Internal Server Error
493           content:
494             application/json:
495               schema:
496                 $ref: '#/components/schemas/ErrorMessage'
497               example:
498                 status: 500
499                 message: Internal Server Error
500                 details: Internal Server Error occurred
501         "502":
502           description: Bad Gateway
503           content:
504             application/json:
505               schema:
506                 $ref: '#/components/schemas/DmiErrorMessage'
507               example:
508                 message: "Bad Gateway Error Message NCMP"
509                 dmi-response:
510                   http-code: 400
511                   body: Bad Request
512     delete:
513       tags:
514       - network-cm-proxy
515       summary: Delete resource data
516       description: Delete resource data from pass-through running for a given cm handle
517       operationId: deleteResourceDataRunningForCmHandle
518       parameters:
519       - name: cm-handle
520         in: path
521         description: "The identifier for a network function, network element, subnetwork\
522           \ or any other cm object by managed Network CM Proxy"
523         required: true
524         schema:
525           type: string
526           example: my-cm-handle
527       - name: resourceIdentifier
528         in: query
529         description: The format of resource identifier depend on the associated DMI
530           Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
531           it can really be anything.
532         required: true
533         allowReserved: true
534         schema:
535           type: string
536         examples:
537           sample 1:
538             value:
539               resourceIdentifier: \shops\bookstore
540           sample 2:
541             value:
542               resourceIdentifier: "\\shops\\bookstore\\categories[@code=1]"
543           sample 3:
544             value:
545               resourceIdentifier: "parent=shops,child=bookstore"
546       - name: Content-Type
547         in: header
548         description: "Content parameter for request, if content parameter is null,\
549           \ default value is application/json."
550         required: false
551         schema:
552           type: string
553           example: application/yang-data+json
554           default: application/json
555       responses:
556         "204":
557           description: No Content
558           content: {}
559         "400":
560           description: Bad Request
561           content:
562             application/json:
563               schema:
564                 $ref: '#/components/schemas/ErrorMessage'
565               example:
566                 status: 400 BAD_REQUEST
567                 message: Bad request error message
568                 details: Bad request error details
569         "401":
570           description: Unauthorized
571           content:
572             application/json:
573               schema:
574                 $ref: '#/components/schemas/ErrorMessage'
575               example:
576                 status: 401
577                 message: Unauthorized error message
578                 details: Unauthorized error details
579         "403":
580           description: Forbidden
581           content:
582             application/json:
583               schema:
584                 $ref: '#/components/schemas/ErrorMessage'
585               example:
586                 status: 403
587                 message: Forbidden error message
588                 details: Forbidden error details
589         "404":
590           description: The specified resource was not found
591           content:
592             application/json:
593               schema:
594                 $ref: '#/components/schemas/ErrorMessage'
595               example:
596                 status: 400
597                 message: Not found error message
598                 details: Not found error details
599         "500":
600           description: Internal Server Error
601           content:
602             application/json:
603               schema:
604                 $ref: '#/components/schemas/ErrorMessage'
605               example:
606                 status: 500
607                 message: Internal Server Error
608                 details: Internal Server Error occurred
609         "502":
610           description: Bad Gateway
611           content:
612             application/json:
613               schema:
614                 $ref: '#/components/schemas/DmiErrorMessage'
615               example:
616                 message: "Bad Gateway Error Message NCMP"
617                 dmi-response:
618                   http-code: 400
619                   body: Bad Request
620     patch:
621       tags:
622       - network-cm-proxy
623       summary: Patch resource data from pass-through running
624       description: Patch resource data from pass-through running for the given cm
625         handle
626       operationId: patchResourceDataRunningForCmHandle
627       parameters:
628       - name: cm-handle
629         in: path
630         description: "The identifier for a network function, network element, subnetwork\
631           \ or any other cm object by managed Network CM Proxy"
632         required: true
633         schema:
634           type: string
635           example: my-cm-handle
636       - name: resourceIdentifier
637         in: query
638         description: The format of resource identifier depend on the associated DMI
639           Plugin implementation. For ONAP DMI Plugin it will be RESTConf paths but
640           it can really be anything.
641         required: true
642         allowReserved: true
643         schema:
644           type: string
645         examples:
646           sample 1:
647             value:
648               resourceIdentifier: \shops\bookstore
649           sample 2:
650             value:
651               resourceIdentifier: "\\shops\\bookstore\\categories[@code=1]"
652           sample 3:
653             value:
654               resourceIdentifier: "parent=shops,child=bookstore"
655       - name: Content-Type
656         in: header
657         description: "Content parameter for request, if content parameter is null,\
658           \ default value is application/json."
659         required: false
660         schema:
661           type: string
662           example: application/yang-data+json
663           default: application/json
664       requestBody:
665         content:
666           '*/*':
667             schema:
668               type: object
669             examples:
670               dataSampleRequest:
671                 $ref: '#/components/examples/dataSamplePatchRequest'
672         required: true
673       responses:
674         "200":
675           description: OK
676           content:
677             application/json:
678               schema:
679                 type: object
680         "400":
681           description: Bad Request
682           content:
683             application/json:
684               schema:
685                 $ref: '#/components/schemas/ErrorMessage'
686               example:
687                 status: 400 BAD_REQUEST
688                 message: Bad request error message
689                 details: Bad request error details
690         "401":
691           description: Unauthorized
692           content:
693             application/json:
694               schema:
695                 $ref: '#/components/schemas/ErrorMessage'
696               example:
697                 status: 401
698                 message: Unauthorized error message
699                 details: Unauthorized error details
700         "403":
701           description: Forbidden
702           content:
703             application/json:
704               schema:
705                 $ref: '#/components/schemas/ErrorMessage'
706               example:
707                 status: 403
708                 message: Forbidden error message
709                 details: Forbidden error details
710         "500":
711           description: Internal Server Error
712           content:
713             application/json:
714               schema:
715                 $ref: '#/components/schemas/ErrorMessage'
716               example:
717                 status: 500
718                 message: Internal Server Error
719                 details: Internal Server Error occurred
720         "502":
721           description: Bad Gateway
722           content:
723             application/json:
724               schema:
725                 $ref: '#/components/schemas/DmiErrorMessage'
726               example:
727                 message: "Bad Gateway Error Message NCMP"
728                 dmi-response:
729                   http-code: 400
730                   body: Bad Request
731   /v1/ch/{cm-handle}/modules:
732     get:
733       tags:
734       - network-cm-proxy
735       summary: Fetch all module references (name and revision) for a given cm handle
736       description: fetch all module references (name and revision) for a given cm
737         handle
738       operationId: getModuleReferencesByCmHandle
739       parameters:
740       - name: cm-handle
741         in: path
742         description: "The identifier for a network function, network element, subnetwork\
743           \ or any other cm object by managed Network CM Proxy"
744         required: true
745         schema:
746           type: string
747           example: my-cm-handle
748       responses:
749         "200":
750           description: OK
751           content:
752             application/json:
753               schema:
754                 type: array
755                 items:
756                   $ref: '#/components/schemas/RestModuleReference'
757         "400":
758           description: Bad Request
759           content:
760             application/json:
761               schema:
762                 $ref: '#/components/schemas/ErrorMessage'
763               example:
764                 status: 400 BAD_REQUEST
765                 message: Bad request error message
766                 details: Bad request error details
767         "401":
768           description: Unauthorized
769           content:
770             application/json:
771               schema:
772                 $ref: '#/components/schemas/ErrorMessage'
773               example:
774                 status: 401
775                 message: Unauthorized error message
776                 details: Unauthorized error details
777         "403":
778           description: Forbidden
779           content:
780             application/json:
781               schema:
782                 $ref: '#/components/schemas/ErrorMessage'
783               example:
784                 status: 403
785                 message: Forbidden error message
786                 details: Forbidden error details
787         "500":
788           description: Internal Server Error
789           content:
790             application/json:
791               schema:
792                 $ref: '#/components/schemas/ErrorMessage'
793               example:
794                 status: 500
795                 message: Internal Server Error
796                 details: Internal Server Error occurred
797   /v1/ch/searches:
798     post:
799       tags:
800       - network-cm-proxy
801       summary: Execute cm handle search using the available conditions
802       description: Execute cm handle searches using 'hasAllModules' condition to get
803         all cm handles for the given module names
804       operationId: executeCmHandleSearch
805       requestBody:
806         content:
807           application/json:
808             schema:
809               $ref: '#/components/schemas/Conditions'
810         required: true
811       responses:
812         "200":
813           description: OK
814           content:
815             application/json:
816               schema:
817                 $ref: '#/components/schemas/CmHandles'
818         "400":
819           description: Bad Request
820           content:
821             application/json:
822               schema:
823                 $ref: '#/components/schemas/ErrorMessage'
824               example:
825                 status: 400 BAD_REQUEST
826                 message: Bad request error message
827                 details: Bad request error details
828         "401":
829           description: Unauthorized
830           content:
831             application/json:
832               schema:
833                 $ref: '#/components/schemas/ErrorMessage'
834               example:
835                 status: 401
836                 message: Unauthorized error message
837                 details: Unauthorized error details
838         "403":
839           description: Forbidden
840           content:
841             application/json:
842               schema:
843                 $ref: '#/components/schemas/ErrorMessage'
844               example:
845                 status: 403
846                 message: Forbidden error message
847                 details: Forbidden error details
848         "500":
849           description: Internal Server Error
850           content:
851             application/json:
852               schema:
853                 $ref: '#/components/schemas/ErrorMessage'
854               example:
855                 status: 500
856                 message: Internal Server Error
857                 details: Internal Server Error occurred
858   /v1/ch/{cm-handle}:
859     get:
860       tags:
861       - network-cm-proxy
862       summary: Retrieve CM handle details
863       description: Retrieve CM handle details and properties by cm handle id
864       operationId: retrieveCmHandleDetailsById
865       parameters:
866       - name: cm-handle
867         in: path
868         description: "The identifier for a network function, network element, subnetwork\
869           \ or any other cm object by managed Network CM Proxy"
870         required: true
871         schema:
872           type: string
873           example: my-cm-handle
874       responses:
875         "200":
876           description: OK
877           content:
878             application/json:
879               schema:
880                 $ref: '#/components/schemas/RestOutputCmHandle'
881         "400":
882           description: Bad Request
883           content:
884             application/json:
885               schema:
886                 $ref: '#/components/schemas/ErrorMessage'
887               example:
888                 status: 400 BAD_REQUEST
889                 message: Bad request error message
890                 details: Bad request error details
891         "401":
892           description: Unauthorized
893           content:
894             application/json:
895               schema:
896                 $ref: '#/components/schemas/ErrorMessage'
897               example:
898                 status: 401
899                 message: Unauthorized error message
900                 details: Unauthorized error details
901         "403":
902           description: Forbidden
903           content:
904             application/json:
905               schema:
906                 $ref: '#/components/schemas/ErrorMessage'
907               example:
908                 status: 403
909                 message: Forbidden error message
910                 details: Forbidden error details
911         "404":
912           description: The specified resource was not found
913           content:
914             application/json:
915               schema:
916                 $ref: '#/components/schemas/ErrorMessage'
917               example:
918                 status: 400
919                 message: Not found error message
920                 details: Not found error details
921         "500":
922           description: Internal Server Error
923           content:
924             application/json:
925               schema:
926                 $ref: '#/components/schemas/ErrorMessage'
927               example:
928                 status: 500
929                 message: Internal Server Error
930                 details: Internal Server Error occurred
931 components:
932   schemas:
933     ErrorMessage:
934       title: Error
935       type: object
936       properties:
937         status:
938           type: string
939         message:
940           type: string
941         details:
942           type: string
943     # DMI Server Exception Schema
944     DmiErrorMessage:
945       title: DMI Error Message
946       type: object
947       properties:
948         message:
949           type: string
950           example: "Bad Gateway Error Message NCMP"
951         dmi-response:
952           type: object
953           properties:
954             http-code:
955               type: integer
956               example: 400
957             body:
958               type: string
959               example: Bad Request
960     RestModuleReference:
961       title: Module reference details
962       type: object
963       properties:
964         moduleName:
965           type: string
966           example: my-module-name
967         revision:
968           type: string
969           example: my-module-revision
970     Conditions:
971       type: object
972       properties:
973         conditions:
974           $ref: '#/components/schemas/ConditionsData'
975     ConditionsData:
976       type: array
977       items:
978         $ref: '#/components/schemas/ConditionProperties'
979     ConditionProperties:
980       properties:
981         name:
982           type: string
983           example: hasAllModules
984         conditionParameters:
985           $ref: '#/components/schemas/ModuleNamesAsJsonArray'
986     ModuleNamesAsJsonArray:
987       type: array
988       items:
989         $ref: '#/components/schemas/ModuleNameAsJsonObject'
990     ModuleNameAsJsonObject:
991       properties:
992         moduleName:
993           type: string
994           example: my-module
995     CmHandles:
996       type: object
997       properties:
998         cmHandles:
999           $ref: '#/components/schemas/CmHandleProperties'
1000     CmHandleProperties:
1001       type: array
1002       items:
1003         $ref: '#/components/schemas/CmHandleProperty'
1004     CmHandleProperty:
1005       properties:
1006         cmHandleId:
1007           type: string
1008           example: my-cm-handle-id
1009     RestOutputCmHandle:
1010       title: CM handle Details
1011       type: object
1012       properties:
1013         cmHandle:
1014           type: string
1015           example: my-cm-handle1
1016         publicCmHandleProperties:
1017           $ref: '#/components/schemas/CmHandlePublicProperties'
1018     CmHandlePublicProperties:
1019       type: array
1020       items:
1021         type: object
1022         additionalProperties:
1023           type: string
1024           example: Book Type
1025   examples:
1026     dataSampleResponse:
1027       summary: Sample response
1028       description: Sample response for selecting 'sample 1'.
1029       value:
1030         bookstore:
1031           categories:
1032           - code: "01"
1033             books:
1034             - authors:
1035               - Iain M. Banks
1036               - Ursula K. Le Guin
1037             name: SciFi
1038           - code: "02"
1039             books:
1040             - authors:
1041               - Philip Pullman
1042             name: kids
1043     dataSampleRequest:
1044       summary: Sample request
1045       description: Sample request body
1046       value:
1047         test:bookstore:
1048           bookstore-name: Chapters
1049           categories:
1050           - code: "01"
1051             name: SciFi
1052             books:
1053             - authors:
1054               - Iain M. Banks
1055               - Ursula K. Le Guin
1056           - code: "02"
1057             name: kids
1058             books:
1059             - authors:
1060               - Philip Pullman
1061     dataSamplePatchRequest:
1062       summary: Sample patch request
1063       description: Sample patch request body
1064       value:
1065         ietf-restconf:yang-patch:
1066           patch-id: patch-1
1067           edit:
1068           - edit-id: edit1
1069             operation: merge
1070             target: /
1071             value:
1072               test:bookstore:
1073                 bookstore-name: Chapters
1074                 categories:
1075                 - code: "01"
1076                   name: Science
1077                   books:
1078                   - authors:
1079                     - Author1
1080                     - Author2
1081                 - code: "02"
1082                   name: Arts
1083                   books:
1084                   - authors:
1085                     - Author3
1086           - edit-id: edit2
1087             operation: merge
1088             target: /
1089             value:
1090               test:bookstore:
1091                 bookstore-name: Novels
1092                 categories:
1093                 - code: "03"
1094                   name: History
1095                   books:
1096                   - authors:
1097                     - Iain M. Banks
1098                     - Ursula K. Le Guin
1099                 - code: "04"
1100                   name: Fiction
1101                   books:
1102                   - authors:
1103                     - Philip Pullman