Transform Map: Where to build the response object and use it in 'run script'

andy_dufresne
Tera Expert

Hello all Gurus, hope you all are doing great!!!

 

I have built a 'Web Service Import Set', when called it invokes a script include which returns a JSON object.  This works fine as you can see from image below.

However I would like to build a response object [instead of a JSON]  which is not working [details below].  Any clue where to build this response object?

 

 

find_real_file.png

 

 

I have already tried to create a 'Transform Script' and build response object there.  Which does contain the 'sysId' in the response.  but this does not carry over to the 'run script' above.

I created the transform script  as below:

find_real_file.png

 

 

Question:  How/Where should I build my response object so that it is available in the Transform Map Run script?

 

Thanks for reading!!

 

 

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Andy,

What functionality you want to achieve?

Since response object is not available in the transform script.

Mark Correct if this solves your issue and also hit Like and Helpful if you find my response worthy based on the impact.
Thanks
Ankur

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

Hi Ankur,

 

Thanks for the response.

 

I want to update the target table's custom fields [example customSysID].  My script include will return this 'customSysID' which currently using JSON we are updating as shown above.

 

The functionality: We plan to use the target table as a log of the outcome of calling my script include.

 

FYI: using JSON works, but this is is not ideal for us.