apidocs

DeleteDocument API

Moves a document to the recycle bin. The document is not permanently removed -“ it can be restored using RestoreRecycleBinItem or permanently purged using PurgeRecycleBinItem.

Endpoint


/srv.asmx/DeleteDocument

Methods

Parameters

Parameter Type Required Description
authenticationTicket string Yes Authentication ticket obtained from AuthenticateUser.
Path string Yes Full infoRouter path of the document to delete (e.g. /MyLibrary/Reports/OldReport.pdf).

Response

Success Response


<root success="true" />

Error Response


<root success="false" error="Error message" />


Required Permissions

The authenticated user must be the document owner, a domain manager of the containing library, or have Delete permission on the document or its parent folder.


Example

GET Request


GET /srv.asmx/DeleteDocument

  ?authenticationTicket=3f2504e0-4f89-11d3-9a0c-0305e82c3301

  &Path=/MyLibrary/Reports/OldReport.pdf

HTTP/1.1

POST Request


POST /srv.asmx/DeleteDocument HTTP/1.1

Content-Type: application/x-www-form-urlencoded



authenticationTicket=3f2504e0-4f89-11d3-9a0c-0305e82c3301

&Path=/MyLibrary/Reports/OldReport.pdf

SOAP Request


<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"

               xmlns:tns="http://tempuri.org/">

  <soap:Body>

    <tns:DeleteDocument>

      <tns:authenticationTicket>3f2504e0-4f89-11d3-9a0c-0305e82c3301</tns:authenticationTicket>

      <tns:Path>/MyLibrary/Reports/OldReport.pdf</tns:Path>

    </tns:DeleteDocument>

  </soap:Body>

</soap:Envelope>


Notes



Error Codes

Error Description
[900] Authentication failed Invalid or missing authentication ticket.
[901] Session expired or Invalid ticket The ticket has expired or does not exist.
Document not found The Path does not refer to an existing document.