cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

ThingWorx REST api questions

SOLVED
Highlighted
Newbie

ThingWorx REST api questions

Hi all,

I've a couple of questions regarding Thx REST API. We're using it for displaying an inventory view in an external webserver.

- Is it possible to select the attributes returned when getting the things implementing a custom pattern? (i.e.: GET Thingworx/ThingTemplates/MyTemplate/ImplementingThings/)

- Is there any option to receive the result paginated or to set any pagination options?

Thanks!

Tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: ThingWorx REST api questions

I would recommend a wrapper service to provide what you need.

Instead of calling Thingworx/ThingTemplates/MyTemplate/ImplementedThings, you would call Thingworx/Things/MyServiceWrapper/Services/GetMyTemplateImplementedThings

There, your service script would accept arguments for the attributes and patterns you want. You can also implement pagination in your service, as Thingworx doesn't seem to provide pagination itself.

View solution in original post

2 REPLIES 2
Highlighted

Re: ThingWorx REST api questions

I would recommend a wrapper service to provide what you need.

Instead of calling Thingworx/ThingTemplates/MyTemplate/ImplementedThings, you would call Thingworx/Things/MyServiceWrapper/Services/GetMyTemplateImplementedThings

There, your service script would accept arguments for the attributes and patterns you want. You can also implement pagination in your service, as Thingworx doesn't seem to provide pagination itself.

View solution in original post

Highlighted

Re: ThingWorx REST api questions

Thanks Hatcher, we'll proceed that way

Announcements

Thingworx Navigate content has a new home! Click here to access the new Thingworx Navigate forum!