Difference between Postman and ServiceNow when sys_id is used. Why?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-13-2022 08:11 AM - edited 04-04-2024 01:29 AM
On the incident form, to populate the 'Assignment group' field, if I use the Name of the group in postman/rest API explorer, it works fine and udpate will happen.
but the same operation will not work if I make use of Business rule like (current.assignment_group= "Test Group");
In business rule, only if I pass the sys_id then it gets updated.
Note -
if I write like this (current.assigned_to = "john viva"); ---- this work.... why not for assignment group?
How does it actually work? Why it differs from Business rule vs Postman/REST API explorer?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-13-2022 08:29 AM
Best Practice -
To use sys_id of reference.
Reason - reference should be sys_id.
It is not working for business rule I guess there can be multiple group with same name.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-13-2022 08:33 AM
There is only 1 group with that name. Infact this scenario is happening for ALL the reference fields with 'Assigned to' as an exception. wondering why/how...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-13-2022 09:41 AM
Hi Suggy,
On close inspection of the REST API documentation, you'll notice you can use a flag to control whether to set field values using the display value or the actual value. The flag is: sysparm_input_display_value
This is however set to false by default. I would say this behavior will depend on which API you're using eg: Table API vs other vs your own scripted REST API. There's a lot of merit in using display values (where unique) as external systems will not always have access to ServiceNow sys_id's (not to mention the overhead of maintaining them).
When using API and integrations I'd also suggest leveraging transform maps and make use of staging tables so you can have full control of the data being passed and manipulate it if required. The staging table can also be used for 'temporary' auditing.
Business rules by contrast being internal and native to ServiceNow will only let you set a reference field by using the appropriate sys_id.
To help others in the community with the same or similar question, please can you mark my reply as correct and/or helpful.
Thanks,
Robbie
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-13-2022 10:36 AM
Hi @Robbie
In REST API explorer, this is what I did (tried updating an Incident) with below 4 combinations
Finally, in each of the above case, the incidnet got udpated with actual values for both the fields..... I dont see any difference in setting the field "sysparm_input_display_value" TRUE/FALSE.