Create URL of Issue In ServiceNow

Knowledge Heis1
Tera Contributor

Hello

@Ankur Bawiskar 

We are using Jira webhook. Whenever an issue is created or updated, the information flows into ServiceNow through the flow designer. Now we want to create the Issue URL and update that in one of the fields in the ServiceNow Custom table, We have stored the base URL in the system property, Can I create a URL for that Particalur Issue?

 

"corp.atlassian.net/browse/issue key "in flow designer?

1 ACCEPTED SOLUTION

Hemant Kumar Ch
Kilo Sage

Hello Knowledge 

 

Create a Action with input as Payload 

 

Add Script Step 

var allInputs = JSON.parse(inputs.payload);
outputs.key = allInputs.issue.key;

 

Map that output Variable to Key field 

 

Please like if it helped You

Ch Hemant Kumar

 

View solution in original post

21 REPLIES 21

Hi Ankur 

 

I am storing that key in a field called "u_key" I am just not able to access that in-line script,Is any better way to achieve this without creating any field?

 

Please let me know how to access that field value in the inline script and put in the URL as it s subflow

@Knowledge Heis1 

It's very difficult to understand without having the flow screenshot, instance details.

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

KnowledgeHeis1_0-1681817876408.pngKnowledgeHeis1_1-1681817915688.pngKnowledgeHeis1_2-1681817942395.png

Sample Payload 

KnowledgeHeis1_3-1681818078637.png

 

@Knowledge Heis1 

are you sure the input.payload.issue.key is giving correct key?

should you not parse the json body to extract the value?

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

Yes Ankur that is not giving any value ,That reason need you insight how to parse and get key 

 

Could you please update the script what needs to be done can we create that as hyperlink with Issue Number