How to get data from REST / or SOAP api in Custom (Load by Script) type data source?

sheejajose
Mega Expert

Hi,

 

We need to import data to Knowledge table. Currently the excel file is having all the fields except the article body field which is a very long html code with text, images and URLs so can't be placed in single excel cell. So, we thought of having the html code as a separate html file for each article in a SharePoint.

 

PFA, we are using Data source of type Custom (load from script) How to retrieve the data from the SharePoint in the highlighted portion of the attached script.

 

Thanks,

Sheeja

1 REPLY 1

MAHAMKALI
Tera Contributor

Hi Sheeja,

You can use RESTMessageV2 API in your Data source to fetch data from REST like this

var sm = new sn_ws.RESTMessageV2("<REST_message_record>","Resource_Name");

 

For additional info see this documentation - RESTMessageV2 API