Migration to TAPI 2.4 Step1
[transportpce.git] / api / src / main / yang / transportpce-tapinetworkutils@2023-07-28.yang
1 module transportpce-tapinetworkutils {
2   yang-version 1.1;
3   namespace "http://org/opendaylight/transportpce/tapinetworkutils";
4   prefix "org-opendaylight-transportpce-tapinetworkutils";
5
6   import tapi-common {
7     prefix tapi-common;
8     revision-date 2022-11-21;
9   }
10
11   organization
12     "transportPCE";
13   contact
14     "transportPCE committers - ODL";
15   description
16     "YANG definitions of TAPI link creation in TAPI topology (adapted from NetworkUtils yang model)
17      Copyright ©  2021 Nokia, Inc. and others.  All rights reserved.
18
19       Redistribution and use in source and binary forms, with or without modification,
20       are permitted provided that the following conditions are met:
21
22       * Redistributions of source code must retain the above copyright notice, this
23         list of conditions and the following disclaimer.
24       * Redistributions in binary form must reproduce the above copyright notice,
25         this list of conditions and the following disclaimer in the documentation and/or
26         other materials provided with the distribution.
27       * Neither Nokia nor the names of its contributors may be used to endorse or promote
28         products derived from this software without specific prior written permission.
29
30       THIS SOFTWARE IS PROVIDED BY ITS AUTHORS AND NOKIA AND OTHER CONTRIBUTORS ''AS IS''
31       AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
32       WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
33       IN NO EVENT ITS AUTHORS AND NOKIA AND OTHER CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
34       INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
35       NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;  LOSS OF USE, DATA,
36       OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
37       WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
38       ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
39       POSSIBILITY OF SUCH DAMAGE";
40
41   revision "2023-07-28" {
42     description
43       "Second revision of tapi networkutils model for migration towards TAPI 2.4";
44   }
45   revision "2021-04-08" {
46     description
47       "Initial revision of tapi networkutils model. Used as the transportpce-networkutils model to
48       create tapi links between tapi nodes in the tapi topology. The inputs are base on OR naming but later
49       translated into tapi";
50   }
51
52   rpc init-roadm-roadm-tapi-link {
53     description "This rpc initiates a tapi roadm to roadm link";
54     input {
55       leaf rdm-a-node {
56         type string;
57       }
58       leaf deg-a-tp {
59         type string;
60       }
61       leaf rdm-z-node {
62         type string;
63       }
64       leaf deg-z-tp {
65         type string;
66       }
67     }
68     output {
69       leaf result {
70         type string;
71       }
72     }
73   }
74
75   rpc init-xpdr-rdm-tapi-link {
76     description "This rpc initiates a tapi xponder to rdm link. Bidirectional";
77     input {
78       leaf xpdr-node {
79         type string;
80       }
81       leaf network-tp {
82         type string;
83       }
84       leaf rdm-node {
85         type string;
86       }
87       leaf add-drop-tp {
88         type string;
89       }
90     }
91     output {
92       leaf result {
93         type string;
94       }
95     }
96   }
97
98   rpc delete-tapi-link {
99     description "This rpc deletes a given link in openroadm Topology layer";
100     input {
101       leaf uuid {
102         type tapi-common:uuid;
103       }
104     }
105     output {
106       leaf result {
107         type string;
108       }
109     }
110   }
111 }