- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-09-2021 03:27 PM
How do I query the rest API for Column Label Names? I can query one incident to get all the columns like this.
https://myDev.service-now.com/api/now/v1/table/incident?sysparm_limit=1
But I need to get all the labels for each of the columns
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2021 09:09 PM
You can use this and it will get all the fields from incident and task.
Incident extends task so it also inherits all the fields from task.
https://{INSTANCENAME}.service-now.com/api/now/table/sys_dictionary?sysparm_query=name%3Dincident%5EORname%3Dtask&sysparm_fields=column_label
https://youtube.com/watch?v=zYi8KhP9SUk
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2021 10:28 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2021 08:13 PM
Hi Tim,
Try this endpoint URL to get all the fields
https://demo1.service-now.com/api/now/table/sys_dictionary?sysparm_query=name%3Dincident%5EORname%3Dtask&sysparm_fields=column_label
Since some the dictionary fields are from task table, above endpoint URL gives you the fields from incidents and task as well.
In the URL - %3D and %5E are URL encodings
URL-encode ASCII Value
%3D =
Refer below link to know about URL encodes
https://www.eso.org/~ndelmott/url_encode.html
Please do mark my reply as correct or helpful, if it helped you resolve the issue 🙂
Regards,
Harika
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2021 08:58 PM
few of the fields might be at task level hence it won't give you those fields when you use incident table in your API for dictionary
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-10-2021 08:55 PM
This is spot on.
https://youtube.com/watch?v=zYi8KhP9SUk
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-09-2021 08:35 PM
Not possible to get using the OOB Table API on incident.
What is the client requirement for this
Approaches
1) Either use table API on the Dictionary table to get the list of columns for incident
OR
2) Use scripted rest api to return the Column Label and it's value by forming custom json response
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader