Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Table for Servicenow Store Apps

Sakshi1
Tera Contributor

Hi, 

 

After some research, I found that ServiceNow provides a "sys_scope" table where some details about OOB Apps and ServiceNow Store Apps can be found. (Apps installed on the instance). I have below 2 questions and looking for answers:

1. Is there any other table that could provide some more details (like how many users have access to them) for ServiceNow Store Applications installed on the instance?

2. In the sys_scope table how to distinguish between ServiceNow store Application and OOB Apps?

 

 

 

1 ACCEPTED SOLUTION

Sandeep Rajput
Tera Patron
Tera Patron

@Sakshi1 

Not sure about #1 but for #2 You can apply the following filter in sys_scope table.

 

Screenshot 2023-05-17 at 11.28.00 PM.png

View solution in original post

4 REPLIES 4

Bert_c1
Kilo Patron

Hi Sakshi1,

 

Please look at the 'sys_store_app' table in your instance. You will those that are installed. Add the column "Is store app" to the list view of records there.

Sandeep Rajput
Tera Patron
Tera Patron

@Sakshi1 

Not sure about #1 but for #2 You can apply the following filter in sys_scope table.

 

Screenshot 2023-05-17 at 11.28.00 PM.png

Riya Verma
Kilo Sage

Hi @Sakshi1 ,
I trust you are doing fine.

  1. To gather more details about ServiceNow Store Applications installed on your instance, you can refer to the "sys_app" table. This table contains additional information about the applications, including details such as the number of users who have access to them.

  2. In the "sys_scope" table, you can distinguish between ServiceNow Store Applications and Out-of-the-Box (OOB) Apps by looking at the value of the "source" field. For ServiceNow Store Applications, the "source" field will have a value of "store". On the other hand, OOB Apps will typically have a different value in the "source" field, such as "system" or "base system".

 

var storeAppGR = new GlideRecord('sys_app');
storeAppGR.addQuery('source', 'store');
storeAppGR.addQuery('name', 'YourStoreAppName'); // Replace with the actual application name
storeAppGR.query();
if (storeAppGR.next()) {
    var userAccessCount = storeAppGR.getValue('user_count');
    gs.print('User access count for the application: ' + userAccessCount);
}

 

Please mark the appropriate response as correct answer and helpful, This may help other community users to follow correct solution.
Regards,
Riya Verma

Bert_c1
Kilo Patron

A list view of sys_store_app follows, the sys_app table contains those developed internally.

 

Screenshot 2023-05-17 153405.png

 

Un-group if desired, or click on one of the right-arrows next to the listed value for "Is store app".