X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?p=it%2Fotf.git;a=blobdiff_plain;f=oran-ric-test-head%2Fric-test-head.py;fp=oran-ric-test-head%2Fric-test-head.py;h=90576784bcfced210009f434f8065273da122a52;hp=f80d3d3f81f8a9cdbf34387d4e4e83a97876875a;hb=21c549fb35244f9078cf824908c7c312f2e89f06;hpb=7723a03d56c434459a639e7c85b9225892127640 diff --git a/oran-ric-test-head/ric-test-head.py b/oran-ric-test-head/ric-test-head.py index f80d3d3..9057678 100644 --- a/oran-ric-test-head/ric-test-head.py +++ b/oran-ric-test-head/ric-test-head.py @@ -17,6 +17,7 @@ import datetime import json import logging from logging import FileHandler +import os import requests from flask import Flask, request, jsonify @@ -82,7 +83,7 @@ def executeRicRequest(): responseData['vthResponse']['resultData']['statusCode'] = res.status_code responseData['vthResponse']['resultData']['resultOutput'] = res.json() elif action == 'deploy': - payload = {'name': requestData['name']} + payload = json.dumps({'name': requestData['name']}) res = requests.post(baseAddress+config['actions_path'][action], data=payload) responseData['vthResponse']['resultData']['statusCode'] = res.status_code responseData['vthResponse']['resultData']['resultOutput'] = res.json()