Archive one version of an evidence library document
Archive one version of an evidence library document that no dispute uses, so that Payrails never attaches it to new disputes.
currentVersion becomes its newest version that is not archived.
When you archive the only version that is not archived, Payrails archives the whole
document too. The next version you add still gets a new number.
- Returns 409 when a dispute uses the version, in any workspace, or when the document is archived.
- Archiving a version that is already archived returns the document unchanged.
- Returns 404 when the document or the version does not exist, or when the
evidenceLibraryEnabledfeature flag is off.
Authorizations
You can use an OAuth2 JWT bearer token in the Authorization header of your API requests for supported endpoints: Authorization: Bearer <YOUR_JWT_HERE>.
These tokens are valid for 10 minutes and can be requested via the access token endpoint endpoint.
Headers
Idempotency key to be used. Sending again the same key would return the same result without re-executing the update.
Path Parameters
Identifier of the resource in Payrails.
Number of the version to archive.
x >= 1Response
The document with the archived version.
Kind of library document. terms and policy documents are attached to every dispute; productDescription documents to not-as-described disputes.
terms, policy, productDescription Always allDisputes. Payrails attaches every document to every new dispute.
allDisputes Number of disputes that use any version of the document. For a caller limited to some workspaces, only disputes in those workspaces count.
Absent when the document applies to every workspace.
The latest version that is not archived. New disputes get this version. Absent when every version is archived.
When a dispute last started to use a version of the document. For a caller limited to some workspaces, only disputes in those workspaces count.
All versions of the document, oldest first. Returned by Add document (version 1 only), Get document, Add version, Archive document and Archive version. List documents does not return it.
The 100 disputes that most recently started to use the document, newest first, with the version each one uses. A dispute that uses two versions appears twice. usedInCount is the total number of disputes. Returned by Get document, Add version, Archive document and Archive version.
100