Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X
I have a test thing on ThingWorx cloud, named "rrrr", with an Integer property "temp".
I can read and write to the property via the rest API:
Read: GET http://xxxx.cloud.thingworx.com/Thingworx/Things/rrrr/Properties/temp?appKey=[key here]
Write : PUT http://xxxx.cloud.thingworx.com/Thingworx/Things/rrrr/Properties/temp?appKey=[key here] , Body: { "temp" : 123 }
I am also running the MicroServer / EMS on local machine (with all the default parameters except for server and key name).
I can read fine via EMS:
Read: GET http://localhost:8080/Thingworx/Things/rrrr/Properties/temp returns the correct value.
However attempts to write fails and returns 500 when I send the following to EMS:
PUT http://localhost:8080/Thingworx/Things/rrrr/Properties/temp Body: { "temp" : 123 }
The body of the response is { "temp": null } and the application log on ThingWorks indicate that the value isn't sent correctly:
"error executing APIRequest Message: Unable to dispatch [ uri = /Things/rrrr/Properties/temp/]: Property value for temp was not valid, sending ERROR ResponseMessage to caller!"
The content-type, accept header, and the body is exactly same on all REST calls.
Any idea what might be wrong?