Adapt A1 controller to new interface
[nonrtric.git] / sdnc-a1-controller / northbound / nonrt-ric-api / model / src / main / yang / NONRT-RIC-API.yang
index 986e201..d8704e3 100644 (file)
@@ -27,238 +27,87 @@ module A1-ADAPTER-API {
 \r
     import ietf-yang-types { prefix yang; }\r
 \r
-    revision "2019-10-02" {\r
+    revision "2020-01-22" {\r
         description\r
         "A1 adapter";\r
     }\r
 \r
-    //Flattend interface using RPC\r
-\r
-    //Get an array of near-rt-ric IDs,\r
-    //Each item in the returned array will be regarded as one near-rt-ric-id.\r
-    rpc getNearRT-RICs {\r
-        output {\r
-            leaf-list near-rt-ric-id-list {\r
-                type string;\r
-            }\r
-            leaf code {\r
-                type string;\r
-            }\r
-        }\r
-    }\r
-\r
-    //Get health status for a Near-RT-RIC. true - health ok, false - health is not ok.\r
-    rpc getHealthCheck {\r
-         input {\r
-            leaf near-rt-ric-id {\r
-                type string;\r
-            }\r
-        }\r
-\r
-        output {\r
-            leaf health-status {\r
-                type boolean;\r
-            }\r
-            leaf code {\r
-                type string;\r
-            }\r
-        }\r
-    }\r
-\r
     //Get an array of integer policy type ids\r
     //Each item in the returned array will be regarded as one policy-type-id.\r
-    rpc getPolicyTypes {\r
+    rpc getPolicyTypeIdentities {\r
         input {\r
-            leaf near-rt-ric-id {\r
+            leaf near-rt-ric-url {\r
                 type string;\r
             }\r
         }\r
 \r
         output {\r
             leaf-list policy-type-id-list {\r
-                type uint32;\r
-            }\r
-            leaf code {\r
-                type string;\r
-            }\r
-        }\r
-    }\r
-\r
-    //Create a policy type\r
-    rpc createPolicyType {\r
-        input {\r
-            leaf near-rt-ric-id {\r
-                type string;\r
-            }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-            leaf description {\r
-                type string;\r
-            }\r
-            leaf name {\r
-                type string;\r
-            }\r
-            leaf policy-type {\r
-                type string;\r
-            }\r
-        }\r
-       output {\r
-            leaf code {\r
-                type string;\r
-            }\r
-        }\r
-    }\r
-\r
-    //Get a policy type\r
-    rpc getPolicyType {\r
-        input {\r
-            leaf near-rt-ric-id {\r
-                type string;\r
-            }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-        }\r
-        output {\r
-            leaf description {\r
-                type string;\r
-            }\r
-            leaf name {\r
-                type string;\r
-            }\r
-            leaf policy-type {\r
-                type string;\r
-            }\r
-            leaf code {\r
                 type string;\r
             }\r
         }\r
     }\r
 \r
-    //Delete a policy type\r
-    rpc deletePolicyType {\r
+    //Get an array of integer policy ids\r
+    //Each item in the returned array will be regarded as one policy-id.\r
+    rpc getPolicyIdentities {\r
         input {\r
-            leaf near-rt-ric-id {\r
+            leaf near-rt-ric-url {\r
                 type string;\r
             }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-        }\r
-        output {\r
-            leaf code {\r
-                type string;\r
-            }\r
-        }\r
-    }\r
-\r
-    //Get an array of string policy instance ids\r
-    //Each item in the returned array will be regarded as one policy-instance-id.\r
-    rpc getPolicyInstances {\r
-        input {\r
-            leaf near-rt-ric-id {\r
-                type string;\r
-            }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
         }\r
 \r
         output {\r
-            leaf-list policy-instance-id-list {\r
-                type string;\r
-            }\r
-            leaf code {\r
+            leaf-list policy-id-list {\r
                 type string;\r
             }\r
         }\r
     }\r
 \r
-    //Create a policy instance\r
-    rpc createPolicyInstance {\r
+    //Get a policy type\r
+    rpc getPolicyType {\r
         input {\r
-            leaf near-rt-ric-id {\r
+            leaf near-rt-ric-url {\r
                 type string;\r
             }\r
             leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-            leaf policy-instance-id {\r
-                type string;\r
-            }\r
-            leaf policy-instance {\r
                 type string;\r
             }\r
         }\r
         output {\r
-            leaf code {\r
+            leaf policy-type {\r
                 type string;\r
             }\r
         }\r
     }\r
 \r
-    ///Get a policy instance\r
-    rpc getPolicyInstance {\r
+    //Create a policy\r
+    rpc putPolicy {\r
         input {\r
-            leaf near-rt-ric-id {\r
+            leaf near-rt-ric-url {\r
                 type string;\r
             }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-            leaf policy-instance-id {\r
-                type string;\r
-            }\r
-        }\r
-        output {\r
-            leaf policy-instance {\r
-                type string;\r
-            }\r
-            leaf code {\r
-                type string;\r
-            }\r
-        }\r
-    }\r
-\r
-    //Delete a policy instance\r
-    rpc deletePolicyInstance {\r
-        input {\r
-            leaf near-rt-ric-id {\r
+            leaf policy-id {\r
                 type string;\r
             }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-            leaf policy-instance-id {\r
+            leaf policy {\r
                 type string;\r
             }\r
         }\r
         output {\r
-            leaf code {\r
+            leaf returned-policy {\r
                 type string;\r
             }\r
         }\r
     }\r
 \r
-    //Get the status for a policy instance\r
-    rpc getStatus {\r
+    //Delete a policy\r
+    rpc deletePolicy {\r
         input {\r
-            leaf near-rt-ric-id {\r
-                type string;\r
-            }\r
-            leaf policy-type-id {\r
-                type uint32;\r
-            }\r
-            leaf policy-instance-id {\r
-                type string;\r
-            }\r
-        }\r
-        output {\r
-            leaf status {\r
+            leaf near-rt-ric-url {\r
                 type string;\r
             }\r
-            leaf code {\r
+            leaf policy-id {\r
                 type string;\r
             }\r
         }\r