The CreatorCon Call for Content is officially open! Get started here.

Any API is available to get ACL/Role assigned to AI Agents

nishadm
Giga Contributor

nishadm_0-1758115577188.png

In the recent zurich release ServiceNow introduced new feature with which we can directly assign roles to Agents (Define who can access the AI Agent) through ServiceNow UI
To get those assigned roles/ACL do we have any API available ??
And is it possible to update those roles ?

3 REPLIES 3

M Iftikhar
Giga Sage

Hi @nishadm

 

While the Zurich release introduces a new user interface for managing AI Agent access, there is no specific, high-level API documented exclusively for this feature. However, you can programmatically manage these role assignments by using ServiceNow's standard REST APIs. You can use the Table API to interact with the appropriate tables that store user and role information, such as adding or removing records from the sys_user_has_role table to grant or revoke roles like sn_aia_admin or sn_aia_viewer. This allows you to get and update the roles assigned to users who can access and configure the AI Agent capabilities.

 

Hope this helps!

 

Thanks & Regards,
Muhammad Iftikhar
If my response helped, please mark it as the accepted solution and helpful so others can benefit as well.

Thanks & Regards,
Muhammad Iftikhar

If my response helped, please mark it as the accepted solution so others can benefit as well.

nishadm
Giga Contributor

My quetion is how to get roles assigned to agent while creating Agent

Once you save roles while creating Agent, an access control will be automatically generated but how to get that specific ACL which is assigned to Agent from API ?

Afrith Shariff
Tera Guru

Hi @nishadm ,

 

Please check this table 

https://yourInstance.service-now.com/sn_aia_agent_list.do

 

This has all the meta data of the AI agent stored. 

You can also configure the related list to bring the related data from the other reference tables. 

 

This should solve your issue

 

If this helps clarify, please mark it as helpful so others in the community can benefit too 😊

 

Thanks,

Afrith