Fix VLDs netslice network creation
[osm/NBI.git] / osm_nbi / validation.py
index bb966e2..7d03d90 100644 (file)
@@ -178,6 +178,7 @@ ns_instantiate_internal_vld = {
     "properties": {
         "name": name_schema,
         "vim-network-name": name_schema,
+        "vim-network-id": name_schema,
         "ip-profile": ip_profile_update_schema,
         "internal-connection-point": {
             "type": "array",
@@ -212,6 +213,18 @@ ns_instantiate = {
         "nsDescription": {"oneOf": [description_schema, {"type": "null"}]},
         "nsdId": id_schema,
         "vimAccountId": id_schema,
+        "additionalParamsForNs": object_schema,
+        "additionalParamsForVnf": {
+            "type": "array",
+            "items": {
+                "type": "object",
+                "properties": {
+                    "member-vnf-index": name_schema,
+                    "additionalParams": object_schema,
+                },
+                "required": ["member-vnf-index", "additionalParams"]
+            }
+        },
         "ssh_keys": {"type": "array", "items": {"type": "string"}},
         "nsr_id": id_schema,
         "vduImage": name_schema,
@@ -247,6 +260,7 @@ ns_instantiate = {
                 "properties": {
                     "name": string_schema,
                     "vim-network-name": {"OneOf": [string_schema, object_schema]},
+                    "vim-network-id": {"OneOf": [string_schema, object_schema]},
                     "ip-profile": object_schema,
                     "vnfd-connection-point-ref": {
                         "type": "array",
@@ -482,7 +496,7 @@ pdu_interface = {
         # TODO, add user, password, ssh-key
         "mac-address": mac_schema,
         "vim-network-name": nameshort_schema,  # interface is connected to one vim network, or switch port
-        # TODO "vim-network-id": nameshort_schema,
+        "vim-network-id": nameshort_schema,
         # # provide this in case SDN assist must deal with this interface
         # "switch-dpid": dpid_Schema,
         # "switch-port": nameshort_schema,
@@ -624,6 +638,7 @@ nsi_vld_instantiate = {
     "properties": {
         "name": string_schema,
         "vim-network-name": {"OneOf": [string_schema, object_schema]},
+        "vim-network-id": {"OneOf": [string_schema, object_schema]},
         "ip-profile": object_schema,
     },
     "required": ["name"],