Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Getting activity log of specific incident through the REST API

mahadevanswamy
Kilo Explorer

I would like to know how to get the activity log of a specific incident through the REST API. I have looked at a similar post in this forums and it didn't help me out. I am using Service NOW Helsinki. Please let me know the table name by which I can get the activity logs of a specific incident.

Thanks in advance,

Swamy

19 REPLIES 19

Chuck Tomasi
Tera Patron

The table is sys_history_line.


Is that table accessible under Helsinki?


Sure. Just be sure to get your sysparm_query right so you have the 'set' field pulling from the right record or you could get a LOT of information for all records. Take a look at the table and field structure to understand it and ensure you get the information you want.


I am able to access the table but I cannot understand the information returned from the API. I apologize but I am quite new the Service Now. How do I access the activity log by the incident number? Like you mentioned, how can I access the table and the field structure?



I looked at the DEV instance of the Service Now and I am not able to see the table sys_history_line