EMS Rest API call
Hi,
I'm learning something about EMS http server config from Help center, and by default the http server request port is 8000.
I want to know:
1. does this port(8000 by default) should be the same to one of the the Thingworx server ports that is configured on Tomcat? or they are seperate one?
2. how to request a local rest api call with the port(8000 by default), say from a lua script resource to EMS?
I ask this because after I connected EMS to Thingworx server, I open a rest api call like this:
localhost:8000/Thingworx/Things/MyThing/Properties/myString?method=put&value=fjdk&appKey=xxxxxxxxxxxxx
but it didnt update the property, but it updated the property when I use 8080 instead, and 8080 is what Thingworx is using.
when I access localhost:8000/, it will show the error message as:
� HTTP/1.0 400 Bad request
Date: 2015-10-19T10:05:52Z
Server: ThingWorx HTTP Server (Win32)
Connection: close
Content-Type: text/html
Content-Length: 376
<html><head>
<title>400 Bad request</title>
<style type=text/css>
<!--
body{font-family:Verdana,sans-serif;font-size:9pt}
h3{font-size:13pt}
pre{font-family:Courier New,cour}
-->
</style>
</head><body>
<h3><br>400 Bad request</h3>
<p>Your browser sent a request that this server could not understand.</p>
<p><hr noshade size=1>ThingWorx HTTP Server (Win32)</p>
</body></html>
so I guess I should use the rest api through port 8000 in a wrong way. but I dont know how to rest api call EMS in lua or other process.
below is what I configured in config.json for http server:
"http_server": {
"host": "localhost",
"port": 8000,
"ssl": true,
"content_read_timeout": 20000
}
Many thanks,
Br,
Anna

