To send RITM link in the payload (integration)

chandan2212
Tera Contributor

HI All, 

 

We are using Saviynt integration in that in i need to send RITM link .We are using the workflow to send the payload to Saviynt teams , can you guide me how to write the script to send the current RITM number and RITM link in the workflow.

 

Thanks and Regards,

Chandan patra

1 ACCEPTED SOLUTION

@chandan2212 

use this to form the link and send in the payload wherever you want

I assume your workflow is running on RITM table

var url = '<a href="' + gs.getProperty('glide.servlet.uri') + '/nav_to.do?uri=' + 'sc_req_item' + '.do?sys_id=' + current.sys_id + '">' + current.number + '</a>';

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

5 REPLIES 5

Ankur Bawiskar
Tera Patron
Tera Patron

@chandan2212 

so what did you start with and where are you stuck?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

using workflow.scratchpad.vnumber = current.number;

 

In this script i am getting current RITM  number but i am not create the RITM link to send in the payload or body. 

@chandan2212 

use this to form the link and send in the payload wherever you want

I assume your workflow is running on RITM table

var url = '<a href="' + gs.getProperty('glide.servlet.uri') + '/nav_to.do?uri=' + 'sc_req_item' + '.do?sys_id=' + current.sys_id + '">' + current.number + '</a>';

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar :while putting logs in the workflow:

 

var url = '<a href="'  + 'https://p32uat.service-now.com/nav_to.do?uri=' + 'sc_req_item' + '.do?sys_id=' + current.sys_id + '">' + current.number + '</a>';
 workflow.scratchpad.vumber=url;
 gs.log('test_123'+ workflow.scratchpad.vumber);

 

 

I am Geeting output in the logs : like :

test_123<a href="https://s32uat.service-now.com/nav_to.do?uri=sc_req_item.do?sys_id=37c2541a87466e1013a7cae20cbb35e2">RITM0041256</a>

 

Can you help me to get the correct output

Thanks,

Chandan