Skip to main content
Question

Mapping of Principal ID with /services/permissions/reporting/1.0.0/roles

  • July 2, 2026
  • 3 replies
  • 20 views

Forum|alt.badge.img

Hi all,

According to the documentation on Topdesk API Docs;  there is call to retrieve an overview of all the permissions given. “/services/permissions/reporting/1.0.0/roles”.

This returns all the permissions that a “principal” has. I am looking to map the ID of that principal to retrieve the name ; but I cannot find where this ID is coming from. I tried the oData-endpoints of persons, operators, operatorgroups, tried the old SQL dump as well, but I don’t find the exact ID on our database.

 

Anyone has experience with this API and knows where to find the link?

Thanks ! 

3 replies

Forum|alt.badge.img+1

Hi JVDA,

 

Du kannst mit der principalId den Endpunkt operators mit einer query ansprechen. So etwas, wie:

/tas/api/operators?query=principalId==3446fsda-0b24-4478-ae81-8bfr82f9b7e8&fields=dynamicName,loginName.linkedPerson

und eben optional via “fields” das response-json einschränken.

 

HTH

Thomas


Joost Oostindie
Forum|alt.badge.img+9

Hi ​@JVDA,

Really interesting question, never used this specific API call before.
It took me some time, but I think I found your answer!

The principals you get back are for the Operators, specifically their principalId.
If you want to perform a get, to get all of the operator details, it looks something like this:
/tas/api/operators?query=principalId=={id}

Where you fill in one of the principals in place of {id} that you get back from the get on “/services/permissions/reporting/1.0.0/roles”.

Good to know: No matter if you assign operators, operator groups or both to the permission group, the result you get from this endpoint is always the principal ID of all the operators that are linked to the permission group, either directly or through an operator group.

Of course, if you want to map this for all of the roles and corresponding principals, it will get a bit more complex, but I hope this helps you continue!

I'm really interested in seeing what you're going to create from this, because I think this opens up some amazing possibilities to automate an overview of permission groups with their corresponding operators. If you are able to create something with this and would be willing to share (some) of your effort with us, I would be really excited to have a look at it!


Joost Oostindie
Forum|alt.badge.img+9

Hi JVDA,

 

Du kannst mit der principalId den Endpunkt operators mit einer query ansprechen. So etwas, wie:

/tas/api/operators?query=principalId==3446fsda-0b24-4478-ae81-8bfr82f9b7e8&fields=dynamicName,loginName.linkedPerson

und eben optional via “fields” das response-json einschränken.

 

HTH

Thomas

I had this open for quite some time before answering, so had not noticed this yet, but I see you already found the corresponding card as well. Great work!