To ensure that the data being shared out of Jira and into ServiceNow (inbound data) is being mapped correctly when arriving at your ServiceNow instance, you will need to add and update some of the scripts in the transform maps under the PSP Common Transform Maps module. ServiceNow transform maps handle the format of data being shared into a ServiceNow instance. Making changes to the transform map scripts will allow data to be properly shared out of Jira and then be mapped correctly to the relevant fields in ServiceNow.
Procedure
To get started with updating your transform map, follow these steps:
Access the transform map
Log into your ServiceNow instance and navigate to Perspectium Common Documents > Perspectium Common Transform Maps or simply type and then select Transform Maps in the Filter Navigator on the upper left-hand side of the screen. Then, search for and then click into the transform map you are integrating.
Table | Transform Map |
---|---|
Incident | PSP Common Incident to Incident |
Change Request | PSP Common Change to Change |
Add transform scripts
Create a new transform script by clicking New under the Transform Scripts tab.
Select onBefore in the When field, then fill the Script field with the following:
(function runTransformScript(source, map, log, target /*undefined onStart*/ ) { if (source.u_action == "correlate") { ignore = true; return; } })(source, map, log, target);
Add a new transform map
Create a new transform map that will handle correlating responses from Jira.
Navigate back to Perspectium Common Documents > Perspectium Common Transform Maps, then click New.
Then, set the Source table to the table map that corresponds to the table you are integrating:
Table | Source Table |
---|---|
Incident | PSP Common Incident |
Change Request | PSP Common Change |
Set the Target table to the table you are integrating to. Then, click Submit when done.
Add new field maps to the transform map
Go back to the transform map you created from the previous step, and create new Field Maps by clicking New.
Set the Source field to correlation_id, and the Target field to Sys ID. Then, check the Coalesce box.
Source field | Target field | Coalesce |
---|---|---|
correlation_id | sys_id | true |
Click Submit when done.
Repeat the same steps for creating field maps to the following:
Source field | Target field | Coalesce |
---|---|---|
sys_id | correlation_id | false |
correlation_display | correlation_display | false |
Add a transform script to the transform map
Go back to the transform map you created and create a new transform script by clicking New under the Transform Scripts tab.
Select onBefore in the When field, then fill the Script field with the following:
(function runTransformScript(source, map, log, target /*undefined onStart*/ ) { if (source.u_action != "correlate") { ignore = true; return; } })(source, map, log, target);