Archive a document

Queue the document for archival. The document — together with its extraction results, review history, and the project configuration that produced them — is copied into a new project with archived status, and is then removed from this project. Archival runs in the background and waits for any active processing on the project to finish first; until it completes, the document remains listed with archive_requested_at set. Only available for projects in per-document mode.

On this page

HTTP request

POST https://api.parsewise.ai/api/v1/projects/{project_id}/documents/{document_id}/archive/

URI Parameters

Name In Required Type Description
document_id path Yes string (uuid)  
project_id path Yes string (uuid)  

Request Header

Name Required Type Description
X-API-Key Yes string API key with the pw_live_ prefix. See Authentication.

Responses

Status Type Description
202 V1DocumentArchiveResponse

Security

  • ApiKeyAuth — apiKey — in X-API-Key header. API key with pw_live_ prefix.

Python example

import os
import requests

API_KEY = os.environ["PARSEWISE_API_KEY"]
BASE_URL = "https://api.parsewise.ai/api/v1"

document_id = "<uuid>"
project_id = "<uuid>"

resp = requests.post(
    f"{BASE_URL}/projects/{project_id}/documents/{document_id}/archive/",
    headers={"X-API-Key": API_KEY},
)
resp.raise_for_status()
print(resp.json() if resp.content else None)

Definitions

V1DocumentArchiveResponse

Name Required Type Description
document_id Yes string (uuid) Identifier of the document queued for archival.
archive_requested_at Yes string (date-time) Timestamp when archival was requested.