Insert link in Notification
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-17-2018 01:40 AM
Hello,
I am trying to create a link in the notification that will redirect to the incident in the Service Portal. i tried the following approach
URL on your story is: sp?id=ticket&table=${sys_class_name}&sys_id=${sys_id} and the actual link created on redirection is https://dev53129.service-now.com/sp?id=ticket&table=Incident&sys_id=9c573169c611228700193229fff72400
With sys_class_name I am getting the first letter of the table name as capital (See in bold) and it shows record not found. When i write it in lowercase it is working fine. But how do we create such a link in the notification.
I also tried with the email scripts but with the scripts I am not able to change the link verbiage. For e.g. 'Click here', 'Link', 'your story' or in some case incident number that will redirect to the service portal. For every notification my URL is same but i have to change the verbiage of the link all the time. How do i achieve this?
Please advice.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-17-2018 02:20 AM
${sys_class_name} prints the value as "Incident", which is causing this issue. Try using mail script to get around this issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-17-2018 02:25 AM
Yeah but with the mail script i wont be able to change the link verbiage all the time right? For e.g. I want the link on the following verbiage
'Click here', 'Link', 'your story' or in some case incident number that will redirect to the service portal.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-17-2018 02:35 AM
Add the entire line in mail script and use it at appropriate place.
template.print("'Click here" + Link + "your story");