Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X
Hello,
Does anyone has any idea if ThingWorx capable of being a REST endpoint. Can we access the value of HTTP header details from inside ThingWorx composer/services?
Thanks!
Everything on TW it's REST Endpoints.
Thanks Carles for your response.
Could you please tell me a bit about how to read http header details using Thingworx composer/services?
Nidhi,
What information are you trying to obtain in the header?
Meghan
Hello Meghan,
The requirement is to support a webhook from another site, but in order to do that, ThingWorx needs to be able to read the headers from the HTTP request. I want ThingWorx to be the REST server so that when a REST client makes a request, I can see the headers that the client sent to ThingWorx.
Hi Nidhi,
You can't read HTTP headers from REST API Calls, your TW services are executed on a upper level than RAW REST calls.
But if you control who does the requests then this should not be a problem, as TW REST API can accept as many parameters as you want. Here you have the TW RESP API documentation: Digital Media Publisher
Best Regards,
Carles.