0

i am fairly new to sharepoint. I would like to display the output from a web service call in sharepoint online web part or list.

I can successfully connect the rest api in postman doing a POST call to a url with the json in the body below.

ideally the data would be pulled in real time or refreshed every few minutes. Whats my best approach?

 {
    Query :
    {
        Mode : "MatchAll",
        Items : [
            {
                FieldName : "PriorityName",
                Op : "Equals",
                Value : "P1"
            }

                ]
            }

    }
}
0

Stephen, you can write a WebJob and host(schedule) it on Azure. This webjob will have the code to execute the REST API call and insert the results into a SharePoint List. Next, you can add a view of this list on a page on your SharePoint site. So, the users visiting this page will always see the latest results(depending upon the frequency of your webjob). Below links will help you with basics on "How to write webjobs".

https://docs.microsoft.com/en-us/azure/app-service/web-sites-create-web-jobs https://docs.microsoft.com/en-us/azure/app-service/websites-dotnet-deploy-webjobs

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.