fix son-emu-cli network/monitor CLI
diff --git a/src/emuvim/cli/rest/monitor.py b/src/emuvim/cli/rest/monitor.py
index 8be1e7f..3f95884 100755
--- a/src/emuvim/cli/rest/monitor.py
+++ b/src/emuvim/cli/rest/monitor.py
@@ -53,7 +53,7 @@
metric = args.get("metric"))
url = "{0}/restapi/monitor/interface".format(args.get("endpoint"))
- response = put(url, params=params)
+ response = put(url, json=params)
pp.pprint(response.text)
def stop_metric(self, args):
@@ -63,7 +63,7 @@
metric=args.get("metric"))
url = "{0}/restapi/monitor/interface".format(args.get("endpoint"))
- response = put(url, params=params)
+ response = put(url, json=params)
pp.pprint(response.text)
def setup_flow(self, args):
@@ -74,7 +74,7 @@
cookie=args.get("cookie"))
url = "{0}/restapi/monitor/flow".format(args.get("endpoint"))
- response = put(url, params=params)
+ response = put(url, json=params)
pp.pprint(response.text)
def stop_flow(self, args):
@@ -85,7 +85,7 @@
cookie=args.get("cookie"))
url = "{0}/restapi/monitor/flow".format(args.get("endpoint"))
- response = put(url, params=params)
+ response = put(url, json=params)
pp.pprint(response.text)
def prometheus(self, args):
diff --git a/src/emuvim/cli/rest/network.py b/src/emuvim/cli/rest/network.py
index 44cba60..ac9f5fd 100755
--- a/src/emuvim/cli/rest/network.py
+++ b/src/emuvim/cli/rest/network.py
@@ -56,7 +56,7 @@
priority=args.get("priority"))
response = put("{0}/restapi/network".format(args.get("endpoint")),
- params=params)
+ json=params)
pp.pprint(response.text)
def remove(self, args):
@@ -72,7 +72,7 @@
priority=args.get("priority"))
response = delete("{0}/restapi/network".format(args.get("endpoint")),
- params=params)
+ json=params)
pp.pprint(response.text)
def _parse_vnf_name(self, vnf_name_str):