- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:25 AM
Hi all,
Objective: Use API to get sys_id using a Change Number
I'm new to scripting and I am using POSTMAN to use ServiceNow API to request for response in order to pass data on to other APIs for other apps.
I know that you can GET a response from a Change record if you have its sys_id but can we do the opposite? Is there a way to search up using the CHG number and have it respond back the sys_id record?
What I'm looking for is when we get a Change number coming through an email. We copy that Change number into the script and it goes and open up that sys_id record. Instead of us having to go through the CHG record > Right click and copy sys_id
Any help would be much appreciated.
Thank you
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:14 PM
In post man you can do a get
https://####.service-now.com/api/now/table/change_request?sysparm_query=number%3DCHG0001090
Gets the sys_id
"follow_up": "",
"sys_id": "76732a25d7223100b96d45a3ce6103e5",
"contact_type": "phone",
Vinod Kumar Kachineni
Community Rising Star 2022
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 01:14 PM
In post man you can do a get
https://####.service-now.com/api/now/table/change_request?sysparm_query=number%3DCHG0001090
Gets the sys_id
"follow_up": "",
"sys_id": "76732a25d7223100b96d45a3ce6103e5",
"contact_type": "phone",
Vinod Kumar Kachineni
Community Rising Star 2022
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-28-2020 05:54 PM
Thank you very much for your answer. That worked better.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2022 07:47 AM