Getting display values for reference field in ServiceNow REST calls

ServiceNow provides access to instances through a set if RESTful APIs.

Here is one tip on how to use a GET request to obtain display values for reference fields in ServiceNow.


Use case:

Given the sys_id of a user in ServiceNow, you want to know the name of the department the user belongs to. You plan to find out using a REST GET request.

Example of how it looks like in ServiceNow Instance:

If you were to use the following URL for your REST GET endpoint

You will get the sys_id of the department instead of the name in the JSON response of the request as it is a reference field

To get the display name of the department, you need to add ?sysparm_display_value=true to your REST GET endpoint

You will have the name in the JSON response!

Alternatively you can use

to get all parameters


Posted in Blogs, ServiceNow and tagged , , .