Very new to SharePoint so I am sure this is a newbie question... I did look at the forums. Here is the command I am using:


But I get this error:

xml:lang="en-US">Cannot find resource for the request versions.

I have also tried this:


Which worked, but this just produces the page as if working on the site interface.. Not something that is easily harvester-able.

How can I get a item history in a format that a script can easily parse?

3 Answers 3


What you're using works for me, but I'm in SharePoint online and you didn't mention a what version of SharePoint you're using. If I do:

    url: _spPageContextInfo.webAbsoluteUrl + 
    async: false,
    headers: {
        'accept': 'application/json;odata=nometadata'
    complete: function(request) {
        console.log("CurrentUser: " + JSON.stringify(request, null, 4));
    error: function(request) {
        console.log(JSON.stringify(request, null, 4));

The response JSON I get back looks like:

    "value": [
            "Title":"Web Developer",
            "Title":"Application Developer",

So no parsing necessary. Are you sure you have version history turned on for the list (List Settings->Version History, or Library Settings if it's a document library)?


Solution for SharePoint 2013 REST API:

  • 1
    For some reason I'm getting empty XML tags. For example <author><name></name></author>
    – Paul Vu
    Commented May 27, 2020 at 18:57
  • What is your item's URL? How many versions this item has? Commented May 29, 2020 at 5:16
  • 1
    The URL is site + "_api/web/GetFileByServerRelativeUrl('/ajm/ajm-25/Mobile-Dev/Lists/Announcements_list/379_.000')/Versions" and there is only two versions.
    – Paul Vu
    Commented May 29, 2020 at 12:09
  • What do you get without the /Versions at the end? Commented May 29, 2020 at 12:39
  • It gives me the data for everything else except for the ones I actually need which are the title, author, the actual comment.
    – Paul Vu
    Commented May 29, 2020 at 15:23

Try using SPServices:

  operation: "GetVersionCollection",
  async: false,
  strlistID: "Projects",
  strlistItemID: 1,
  strFieldName: "Description",
  completefunc: function (xData, Status) {
    $(xData.responseText).find("Version").each(function(i) {
      console.log("Name: " + $(this).attr("Description") + " Modified: " + $(this).attr("Modified"));


  1. SharePoint 2013 - Get SPListItem versions via REST.
  2. Any Rest API available for Version history of List item fileds?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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