Zoho Writer > Writer - REST API Methods > ZW - Get list of shared documents

ZW - Get list of shared documents

Tags:  



Get a list of shared documents that's been shared to a user.

 
Request URL :  

                            XML : http://export.writer.zoho.com/api/private/xml/incomingdocuments?apikey=[API Key]&ticket=[Ticket]

                            JSON : http://export.writer.zoho.com/api/private/json/incomingdocuments?apikey=[API Key]&ticket=[Ticket]


Request parameters

Field
Description
start-from [optional]
[integer] - Sets the initial document number from which the shared documents will be listed. It should always be a positive integer. If there are 10 documents and start-from value is set to 3, then the documents will be listed from the 3rd document.
limit [optional]
[integer] - Sets the number of shared documents to be listed. Allowed values for this parameter is from 1 to 100. If the number of shared document is less than the limit value then all documents are listed.


Response fields

The schema document for the API response is located at: http://export.writer.zoho.com/schema/restapi/incomingdocuments.xsd

Field
Description
documentId
Unique ID associated with each document in the list.
documentName
Name of one of the shared documents that is being listed.
version
Specifies the last saved version of the document
lastModifiedTime
[LongValue] - Displays the last modified time as long integer.
writePermisson
[boolean] - Checks whether the access privileges is read only or read/write for the shared users. If false, then the shared users can only read the document content.
document_name_url
Unique document url to differentiate multiple documents having similar name.
shared_users
Displays the list of email addresses to whom the document has been shared. Shows blank in case sharing access is disabled.
document_locked
Checks whether the document has been locked exclusively for editing in a shared environment. True means the lock is enabled.
document_blogged
Checks whether the document has been posted to any of the blog services. False status indicates that the document is not posted to any of the blog services.
author_name
Displays the Email ID/Zoho ID of the document owner, i.e., the account from which the document is created.
created_date
Displays the created date of the document. E.g. 1180532581984.
category
Displays the category of the document, whether 'OWNED' or 'SHARED'


Sample Response


The following is the sample response for the above method:


<?xml version="1.0" encoding="UTF-8" ?>
<response uri="/api/private/xml/incomingdocuments">
<result>
  <incomingdocuments>
    <document>
      <documentId>8000000006005</documentId>
      <documentName>ITProvision</documentName>
      <version>2.6</version>
      <writePermission>true</writePermission>
      <document_name_url>ITProvision</document_name_url>
      <document_locked>false</document_locked>
      <document_blogged>false</document_blogged>
      <authorName>Mike</authorName>
      <lastModifiedTime>1176118084655</lastModifiedTime>
      <shared_users>[bill@myway.com, cathy@yahoo.com]</shared_Users>
      <created_date>1180532581984</created_date>
      <category>shared</category>
    </document>
    <document>
      <documentId>8000000005287</documentId>
          <documentName>ReportCard</documentName>
      <version>1.9</version>
      <writePermission>true</writePermission>
      <document_name_url>ReportCard</document_name_url>
      <document_locked>false</document_locked>
      <document_blogged>false</document_blogged>
      <authorName>Gregory</authorName>
      <lastModifiedTimeDisplayString>57 seconds ago</lastModifiedTimeDisplayString>
      <lastModifiedTime>1176117665498</lastModifiedTime>
      <shared_users>[bill@myway.com, cathy@yahoo.com]</shared_users>
      <created_date>1180532581984</created_date>
      <category>shared</category>
    </document>
  <incomingdocuments>
</result>
</response>


Equivalent JSON response


{
  "response":
   {
        "uri": "/api/private/json/incomingdocuments",
        "result":
        {
           "incomingdocuments":
            {
                "document":
                [
                    {
                        "documentId
":"8000000006005",
                        "documentName":"ITProvision",
                        "version":"2.6",
                        "lastModifiedTimeDisplayString":"20 seconds ago",
                        "
lastModifiedTime":"1176118084655",
                        "writePermission":"true",
                        "document_name_url":"ITProvision",
                        "shared_users":"[bill@myway.com, cathy@yahoo.com]",
                        "document_locked":"false",
                        "document_blogged":"false",
                        "authorName":"Mike",
                        "created_date":"1180532581984",
                        "category":"shared",
                     },
                     {
                        "documentId
":"8000000005287",
                        "documentName":"ReportCard",
                        "version":"1.9",
                        "
lastModifiedTime":"1176117665498",
                        "writePermission":"true",
                        "document_name_url":"ReportCard",
                        "shared_users":"[bill@myway.com, cathy@yahoo.com]",
                        "document_locked":"false",
                        "document_blogged":"false",
                        "authorName":"Gregory",
                        "created_date":"1180532581984",
                        "category":"shared",
                     }
                ]
            }
         }
    }
}  



Errors


Displaying list of documents method may return general & input errors. Possible HTTP error code - 1416 


 RSS of this page