如何在SharePoint 2013服务器场解决方案中调用外部REST查询 [英] How to call external REST queries in SharePoint 2013 farm solution
问题描述
有没有一种方法可以在SharePoint wsp中调用外部REST api?我必须将REST API传送到特定站点,从那里我必须携带数据.我知道我们可以使用SP.Proxy(适用于使用应用程序模型的跨域)轻松地调用JavaScript.但是如果我想 使用C#代码在SharePoint 2013服务器场解决方案中使用相同的内容,方法是什么?我是否需要添加任何程序集引用?
Mihir
这是为您提供的解决方案
https://code.msdn.microsoft.com/office/Invoke-SharePoint-REST-API-078a0638
http://www.c-sharpcorner.com/UploadFile/Roji.Joy/working-with-sharepoint-2013-rest-api-in-aC-Sharp-managed-code/
Is there a way to call external REST api in SharePoint wsp? I am having REST api to particular site from where I have to bring the data. I know that we can call in javascript easily by using SP.Proxy (for cross domain using app model). But if I want to use the same thing in SharePoint 2013 farm solution with C# code, what is the way? Do I need to add any assembly references?
Mihir
Here are the solution for you
https://code.msdn.microsoft.com/office/Invoke-SharePoint-REST-API-078a0638
http://www.c-sharpcorner.com/UploadFile/Roji.Joy/working-with-sharepoint-2013-rest-api-in-a-C-Sharp-managed-code/
这篇关于如何在SharePoint 2013服务器场解决方案中调用外部REST查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!