Class Definitions and Cross Scope Privileges
This article describes the essentials steps to configure Designer to access ServiceNow data.
๐ฅBefore you are getting started
The metamodel is not your target but provides the backbone to interconnect your enterprise data. Designer is model agnostic. Just make sure you have the metamodel in place to answer your business questions.
You need to understand and govern the tables & relationships used by your target audience. Otherwise, Designer users will not find the essential data and can't perform their job of creating outstanding Diagrams & models.
Ensure your target metamodel (tables, fields, relationships) is implemented in ServiceNow, and you have a good idea about all interdependencies required. Please check if the following is in place in ServiceNow before you proceed:
- Tables (sys_db_object)
- Relationship Types (cmdb_rel_type)
- Suggested Relationships (cmdb_rel_type_suggest)
Accessing ServiceNow data through Designer
Users can create diagrams in Designer to represent data from ServiceNow tables via the Repository Browser. To do so, you need to have the following in place:
Feature | Description | Table Name |
---|---|---|
Class Definitions | Define the tables and shape styling in the Class Definitions to make the tables available in the Repository Browser. | x_inpgh_des_class_definitions |
Application Cross-Scope Access | ServiceNow feature to provide read and create rights to applications outside of the Global scope. | sys_scope_privilege |
By default, Designer adds up to 100 tables to the Repository Browser; however, ServiceNow admins may wish to make additional tables available or exclude specific tables for users. Adding a table requires creating a new Class Definition .
As Designer is a scoped application and does not have access rights by default to other ServiceNow tables, a read cross-scope privilege needs to be created. To commit future-state elements, a create cross-scope privilege needs to be created for the same table.
There are further optional configuration steps available to maximize the value out of Designer:
Feature | Description | Table Name |
---|---|---|
Class Fields | Can be configured as part of the Class Definitions for a table to show selected fields in the form view in Designer while creating and editing Future State Elements | Related list on the Class Definitions table |
Relationship Definitions | Change the styling for suggested relationship types, so they automatically apply when used in Designer. | x_inpgh_des_relationship_definitions |
Relationship Fields | Define the fields on relationships, which can be edited for Future State Relationships | Related list on the Relationship Definitions table |
Create and edit Class Definitions
There are two ways to create Class Definitions in ServiceNow:
Create Class Definition in list view
Navigate to Dgner > Configuration > Class Definitions or use the following link to access the Class Definition table:
https://YOUR-INSTANCE.service-now.com/x_inpgh_des_class_definitions_list.do
- Click the new button.
- Complete the fields on the Class Definitions form:
Field | Description |
---|---|
Active | Activates/deactivates the Class Definition. Set active to make the table visible in the Designer Repository Browser. |
Category | Optional field to group Class Definitions within the list view. This field has no further logic within Designer! |
Table | Select the table you want to show in the Designer Repository browser to access the data. |
Display Name | The field is shown in the search and the shape, i.e., typically the "name" field. |
Width | The width of the shape. |
Height | The height of the shape. |
Read Table | Activate to automatically create a cross-scope privilege that enables "read" access to the specified table. Requires setting cross scope privileges automatically |
Allow Commit | Activate to automatically create a cross-scope privilege that enables "create" (commit) access to the specified table. Requires setting cross scope privileges automatically |
Style | Style of the shape. Select a shape in Designer and click CTRL+E and copy/paste into this field. |
- Click the "Submit" button to create the new Class Definition.
Reload Designer to apply changes
The Class Definitions are loaded initially when Designer is starting. Please refresh your browser or start Designer new to load the changes applied above.
Create a Class Definition through a Shape
The quickest way to create a Class Definition by leveraging the shape styling is the following:
- Navigate to Designer > Shape > Shape Libraries and select a library.
- Select a shape within the library.
- Click the "Create Class Definition" button.
Error messages
If you are getting "Access to api..." error messages, this is due to missing rights for Designer on the Cross-scope privilege table. You can fix this issue by setting cross scope privileges automatically, or setting the cross scope privileges manually.
Setting Cross Scope Privileges
Designer is a scoped application and requires โCross Scope Privilegesโ to be able to read tables or create entries in tables (commit) if required.
Before you create a new Cross Scope Privilege, ensure that your Application Scope is set to Designer! This will make sure, that the "Source Scope" is set automatically to Designer.
- Navigate to "System Applications > Application Cross-Scope Access"
- Click the "New" button
- Complete the fields on the Cross Scope Privilege form:
Field | Description |
---|---|
Source Scope | Needs to be set to "Designer" through changing the Application Scope in the beginning. |
Target Scope | Is either "Global" for the core ServiceNow tables, or the target application scope e.g. "UPM-X". |
Target Name | The technical table name. |
Target Table | Should be "Table" |
Application | Needs to be set to "Designer" through changing the Application Scope in the beginning. |
Operation | Select "Read" to provide read access for Designer. Select "Create" to provide the rights to create new entries in the selected table through Designers Commit feature. |
Status | Set to "Allowed" to provide the necessary rights to the selected operation. Set to "Denied" to block Designer for the selected operation. |
- Click "Submit" to create the Cross Scope Privilege.
Setting Cross Scope Privileges automatically
To support the automatic creation and management of Cross-Scope Privileges through Class Definitions, please ensure that the Application Access
- Can Read,
- Can Create,
- Can Update,
- Can Delete
is set correctly on the sys_db_object table.
Extending Rights to third-party apps
This change will allow any other third-party app to do changes within the Cross Scope Privilege table!
You can revoke the changes, once the initial configuration is completed.
- Navigate to the following link:
https://YOUR-INSTANCE.service-now.com/now/nav/ui/classic/params/target/sys_db_object.do%3Fsys_id%3Dsys_scope_privilege%26sysparm_refkey%3Dname%26sysparm_domain_restore%3Dfalse%26sysparm_referring_url%3Dsys_scope_privilege_list.do
- Select the "Application Access" tab and set the appropriate settings.
Alternatively, download the following UpdateSet to set the Application Access on your target instance:
Designer-Global-Settings-for-Cross-scope-privilege.xml
Updated about 2 years ago