diff --git a/src/RESTAPI/RESTAPI_simulation_handler.h b/src/RESTAPI/RESTAPI_simulation_handler.h index f7cba04..7787afb 100644 --- a/src/RESTAPI/RESTAPI_simulation_handler.h +++ b/src/RESTAPI/RESTAPI_simulation_handler.h @@ -19,7 +19,7 @@ namespace OpenWifi { Poco::Net::HTTPRequest::HTTP_DELETE, Poco::Net::HTTPRequest::HTTP_OPTIONS}, Server, TransactionId, Internal) {} - static auto PathName() { return std::list{"/api/v1/simulation"}; } + static auto PathName() { return std::list{"/api/v1/simulation/{id}"}; } void DoGet() final; void DoPost() final; void DoPut() final; diff --git a/test_scripts/curl/cli b/test_scripts/curl/cli index 12e5a1e..0077697 100755 --- a/test_scripts/curl/cli +++ b/test_scripts/curl/cli @@ -136,8 +136,8 @@ createsim() { fi } -listsim() { - curl ${FLAGS} -X GET "https://${OWLS}/api/v1/simulation" \ +listsims() { + curl ${FLAGS} -X GET "https://${OWLS}/api/v1/simulation/*" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer ${token}" > ${result_file} jq < ${result_file} @@ -190,7 +190,7 @@ case "$1" in "login") login; echo "You succesfully logged in..." ; logout ;; "examplesim") examplesim;; "createsim") login; createsim "$2"; logout;; - "listsim") login; listsim; logout;; + "listsims") login; listsims; logout;; "deletesim") login; deletesim "$2"; logout;; "startsim") login; startsim "$2"; logout;; "stopsim") login; stopsim "$2" ; logout;;