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

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Subscription script failing on REST API update

bmaxted
1-Newbie

Subscription script failing on REST API update

I've got a Thing Template called 'NetworkSection' with three properties: 'StartPoint' a reference to another Thing, 'StartCity' a string, and 'Locations', an infotable with one column of Locations.

I've also written a subscription for NetworkSection on its own 'StartPoint' property, which updates the 'StartCity' and first row of the 'Locations' infotable', based on the properties of the new StartPoint.

me.Locations.getRow(0).Loc = Things[me.StartPoint].Loc

me.StartCity = Things[me.StartPoint].City

When I change the StartPoint of a NetworkSection from within composer, both the StartCity and Locations properties update as expected. However, if I do the same through the REST API, I'm finding that the StartCity updates, but record in the Locations infotable does not. Any ideas why that might be?

1 REPLY 1
supandey
19-Tanzanite
(To:bmaxted)

Hi @bmaxted would it be possible to share the REST call you are making to update the properties? Additionally, it will also be helpful to see if the applicationLog.log is showing any error related to the REST call. 

 

May be you can try and debug it with Postman application.

Top Tags