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 called away in the middle of writing a post? Don't worry you can find your unfinished post later in the Drafts section of your profile page. X

Run service in reduced user role

ashishtamhane
10-Marble

Run service in reduced user role

If I am an Administrator is it possible to run a service temporarily on a Thing in a user role that is less privileged?

 

I am working upon a use case wherein the user is not an Administrator. For this I need to keep removing myself from the Administrator's group, check if the mashup/services work, and if they don't request other team member to add myself back to the Administrators group and keep working. I would like to avoid this.

 

Scenario is:

 

1. User Jack is an Administrator

2. When service GetData on a Thing runs it has to do it in a user role which is less privileged than an Administrator

3. Jack's user roles should not be affected in any way if this service runs.

 

Thanks,

Ashish Tamhane 

ACCEPTED SOLUTION

Accepted Solutions

Hi @ashishtamhane 

 

You can create a dummy user in Thingworx manually and assign the required role. Create an appkey for the user and test the mashup using a dummy user appkey.

 

To check service permission/privilege, please make a REST API call to Thingworx using a dummy user appKey -Use REST API to Access ThingWorx Part 1 - PTC Community

 

Refer to the below article:

 

To access Mashup using AppKey - Article - CS227935 - Accessing Mashups using Application Key (appKey) Authentication in ThingWorx (ptc.com)

 

To enable AppKey Authentication with SSO - Article - CS279189 - How to Configure SSO Authentication and REST API Application Key Authentication Simultaneously in ThingWorx Platform (ptc.com)

 

/VR

View solution in original post

3 REPLIES 3

No, there's no impersonation available directly, except the case when you use a Timer/Scheduler, if you want to rely 100% of the platform features.

Looking at your use-case though, this is typically done by having a Test User with the relevant rights running in a private browser window.

Can you ask your team member/s to create such an user for this purpose?

Hi VladimirRosu,

 

Thanks for your response. I  forgot to mention that we are using SSO so would this be possible?

 

Thanks,

Ashish

Hi @ashishtamhane 

 

You can create a dummy user in Thingworx manually and assign the required role. Create an appkey for the user and test the mashup using a dummy user appkey.

 

To check service permission/privilege, please make a REST API call to Thingworx using a dummy user appKey -Use REST API to Access ThingWorx Part 1 - PTC Community

 

Refer to the below article:

 

To access Mashup using AppKey - Article - CS227935 - Accessing Mashups using Application Key (appKey) Authentication in ThingWorx (ptc.com)

 

To enable AppKey Authentication with SSO - Article - CS279189 - How to Configure SSO Authentication and REST API Application Key Authentication Simultaneously in ThingWorx Platform (ptc.com)

 

/VR

Announcements


Top Tags