Differences between SP2010 and SP2013 REST API?

Hi Folks,

Does anyone know the differences between the SharePoint 2010 and 2013 REST APIs. 

I am making a call on SP2013 using the below format to get documents out of a document library.

"{0}/_api/web/lists/getByTitle('{1}')/items?$select=FileLeafRef"

When I try and use the above to call SP2010 it fails, so I am wondering what the correct call ought to be?

(Note: Once I have a handle to a file in the doc library I then need to copy it as a SPFile object).

Regards

Andy

February 1st, 2015 8:39pm

Hi,

Try using the following API on SharePoint 2010

http://<site url>/web/_vti_bin/listdata.svc/ListTitle

for further reference on API in SharePoint 2010, refer the link below

https://msdn.microsoft.com/en-us/library/office/hh313619(v=office.14).aspx

Free Windows Admin Tool Kit Click here and download it now
February 2nd, 2015 1:15am

Hi,

You will need to use _vti_bin/listdata.svc service in case of 2010 version.In case you want to have uniform REST based solution to access both SharePoint 2010 and SharePoint 2013 sites  it wont be possible.  check the following link for differences http://www.nothingbutsharepoint.com/2013/10/09/using-the-updated-sharepoint-2013-rest-api-versus-the-sharepoint-2010-model-aspx/

February 2nd, 2015 1:23am

try this link:

http://www.nothingbutsharepoint.com/2013/10/09/using-the-updated-sharepoint-2013-rest-api-versus-the-sharepoint-2010-model-aspx/

you need to use https://servername/web/_api/lists for 2013 and _vti_bin/listdata.svc for 2010.

--------------------------------------------------------------------------------------------------------------------------------------

Please mark answer as correct if it is correct else vote for it if you find it useful Happy SharePointing

Free Windows Admin Tool Kit Click here and download it now
February 2nd, 2015 2:49am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics