Skip to content

SetDocumentRetention API

Obsolete since infoRouter 8.1.155. This API always returns an error and must not be used in new integrations. Use SetDocumentRandDSchedule to manage document retention.

Sets the retention period of the specified document. This method was used to mark a document as having no retention, permanent retention, or retention until a specified date. As of version 8.1.155, the API is disabled -" every call returns an error regardless of the parameters supplied. All retention management is now handled through the Retention & Disposition schedule system.

Endpoint

/srv.asmx/SetDocumentRetention

Methods

  • GET /srv.asmx/SetDocumentRetention?authenticationTicket=...&path=...&retentionStatus=...&retainUntil=...
  • POST /srv.asmx/SetDocumentRetention (form data)
  • SOAP Action: http://tempuri.org/SetDocumentRetention

Parameters

Parameter Type Required Description
authenticationTicket string Yes Authentication ticket obtained from AuthenticateUser.
path string Yes Full infoRouter path to the document (e.g. /Finance/Reports/Q1-Report.pdf).
retentionStatus short (int16) Yes Retention mode. Valid values: 0 = No Retention, 1 = Forever, 2 = Until Specified Date.
retainUntil DateTime No Required when retentionStatus is 2. The date until which the document must be retained (e.g. 2030-12-31). Ignored for other status values.

Note: These parameters are accepted by the endpoint signature but are not evaluated. The API returns an error for every call.


Response

Error Response (always returned)

<root success="false" error="'SetDocumentRetention' infoRouter Web Service API is obsolete. Please follow the new API documentation." />

This API never returns a success response. Every call returns the error above.


Required Permissions

Not applicable -" the API is disabled and returns an error for all callers regardless of permissions.


Example

GET Request

GET /srv.asmx/SetDocumentRetention
  ?authenticationTicket=3f2504e0-4f89-11d3-9a0c-0305e82c3301
  &path=/Finance/Reports/Q1-2024-Report.pdf
  &retentionStatus=2
  &retainUntil=2030-12-31
HTTP/1.1

POST Request

POST /srv.asmx/SetDocumentRetention HTTP/1.1
Content-Type: application/x-www-form-urlencoded

authenticationTicket=3f2504e0-4f89-11d3-9a0c-0305e82c3301
&path=/Finance/Reports/Q1-2024-Report.pdf
&retentionStatus=2
&retainUntil=2030-12-31

JavaScript

Every call answers XML with HTTP 200, success or not, so success is the thing to branch on and errorCode is the number to report.

async function call(action, params) {
  const response = await fetch(`/srv.asmx/${action}?${new URLSearchParams(params)}`);
  const root = new DOMParser()
    .parseFromString(await response.text(), 'text/xml')
    .documentElement;

  if (root.getAttribute('success') !== 'true') {
    throw new Error(`${root.getAttribute('errorCode')}: ${root.getAttribute('error')}`);
  }
  return root;
}

This operation is obsolete and does nothing. Every call is answered 4000 with a message saying so. It is still routed, so a client written against an older version gets an answer it can read rather than a 404, but there is no version of the call that works.

Use the retention and disposition schedule operations instead - see SetFolderRandDSchedule and the RandDSchedule family.

Notes

  • This API has been disabled since infoRouter 8.1.155. The implementation returns an error immediately without performing any operation.
  • Do not use this API in any new or existing integration. Migrate to SetDocumentRandDSchedule, which applies a named Retention & Disposition schedule to a document.
  • The original retention model (NoRetention / Forever / Until Date) has been superseded by the more flexible R&D schedule system.


Error Codes

The errorCode values this operation returns, checked against a running server:

errorCode When
4000 every call: "'SetDocumentRetention' infoRouter Web Service API is obsolete. Please follow the new API documentation."
Error Description
'SetDocumentRetention' infoRouter Web Service API is obsolete. Please follow the new API documentation. This is the only response this API ever returns. The API is disabled.