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

Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X

How do you properly invoke AddVisibilityPermission within Thingworx REST API properly?

pjbiocco
10-Marble

How do you properly invoke AddVisibilityPermission within Thingworx REST API properly?

Hello! Currently, I'm playing around with the Thingworx REST API.

I am trying to connect a ThingShape's visibility to an organizational unit. The highest Unit is "TopOrg" and the one directly below is "Administrator". Below that is "Worker", so TopOrg > Administrator > Worker.

According to documentation I need a "principal" and "principalType"

I've left my principalType to be "OrganizationalUnit", but I can't seem to get a correct "principal". I've tried "Administrator", "TopOrg:Administrator" and "TopOrg/Administrator". In either form, I get an error similar to this.

Unable to Invoke Service AddVisibilityPermission on AdminShape : Invalid Entity Reference: OrganizationalUnit/TopOrg/Administrator

How are principals properly formated?

PB_10110760_0-1641487158767.png

 

ACCEPTED SOLUTION

Accepted Solutions

PrincipalType is Organization
Principlal is "TopOrg" in your case

PrincipalType is OrganizationUnit
Principlal is "Administrator" in your case

 

PrincipalType is OrganizationUnit
Principlal is "Worker" in your case

 

you have to set separately for each org / orgUnit.

View solution in original post

2 REPLIES 2

@pjbiocco 

 

You can check the explanation provided in help center guide .

 

Regards,

Sachin Sharma

PrincipalType is Organization
Principlal is "TopOrg" in your case

PrincipalType is OrganizationUnit
Principlal is "Administrator" in your case

 

PrincipalType is OrganizationUnit
Principlal is "Worker" in your case

 

you have to set separately for each org / orgUnit.

Announcements


Top Tags