Web Service Wincc OA

Find and share HowTos to various installations / configurations!
2 posts • Page 1 of 1
jeissonsierrac
Posts:62
Joined: Wed Jun 03, 2015 9:37 pm

Web Service Wincc OA

Post by jeissonsierrac »

it is possible to create a web service in win cc oa

vogler
Posts:122
Joined: Thu Oct 28, 2010 8:32 am

Re: Web Service Wincc OA

Post by vogler »

You can use the build in http server in control - see the documentation of httpServer, httpConnect.
And you can use jsonEncode/jsonDecode to transform ctrl objects from/to json.

httpServer(false, PORT, PORT_SSL)

httpConnect("httpHelloWorld", "/helloWorld"); // http://localhost:8082/helloWorld

string httpHelloWorld()
{
return jsonEncode(makeMapping("hello", "world", "time", getCurrentTime()));
}

2 posts • Page 1 of 1