Service portal $sp.getStream do not retrieve existing comments entries

layla
Giga Expert

Hello experts,

I have an issue in the "ticket conversation" widget.

Actually in the server script we have a call to $sp.getStream(tablename, sys_id) to build the stream json object.

In that object we are not getting any journal entries (the array stream.entries is empty) even we have many comments added for the current ticket.

do you have an idea from where these entries are retrieved and any valuable information avout this API.

Thanks a lot for your help!

layla 

2 REPLIES 2

harishdasari
Tera Guru

Hi Layla,

Below thread have answer for your question.

https://community.servicenow.com/community?id=community_question&sys_id=a882df61db101fc01dcaf3231f96195e

The reason is If a table extending the task table is specified, the only it will display the  display_value, sys_id, short_description,number, entries, user_sys_id, user_full_name, user_login, label, table, and journal_fields properties; 

So make sure you are using the $sp.getStream API is task table extended. Otherwise it will not return the activity stream.

 

Thank you.

 

 

Yang Xia
Tera Expert

Hi Layla,

 

Did you got anwsers? I'm facing the same situation and looking for solution for it.

 

Best regards,

Mike