function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Mallesh GMallesh G 

REST API is not returning all files in the "ContentVersion" Object

Hi There,
I have been develping an application which consumes REST service of the Salesforce. I am not able to get content(FIles) using the "ContentVersion" Object. I have below SOAP query which returns all files in my account, where as REST service returns onlu one file.

I need the REST equalent query of the below SOAP API query.
<query xmlns="urn:enterprise.soap.sforce.com">
          <queryString>
          SELECT ContentDocumentId, Id, Title, FileType, LastModifiedDate, PathOnClient
          FROM ContentVersion
          WHERE OwnerId = {1} AND IsLatest = true
          ORDER BY LastModifiedDate DESC, ContentDocumentId DESC
          LIMIT {2}
          </queryString>
        </query>

Thanks,
Mallesh.
Ramu_SFDCRamu_SFDC
See if the below documentation provides any information on this

https://www.salesforce.com/us/developer/docs/api/Content/sforce_api_objects_contentversion.htm