Document

Partial update document

Update part of a document object.

patch/api/v1/documents/{documentID}

Path parameters

documentIDinteger required

Document ID

Request body

idinteger

ID of the document

urlstring url

URL of the document

s3_namestring

Storage key of the document file. Internal use only.

parentstring url nullable

URL of the parent document (e.g. the zip file it was extracted from)

emailstring uri nullable

URL of the email object that document was imported by (only for document imported by email).

annotationsstring[]

List of annotations related to the document. Usually there is only one annotation.

mime_typestring

MIME type of the document (e.g. application/pdf)

creatorstring url nullable

User that created the annotation.

created_atstring date-time

Timestamp of document upload or incoming email attachment extraction.

arrived_atstring date-time

See created_at

original_file_namestring

File name of the attachment or upload.

contentstring url

Link to the document's raw content (e.g. PDF file). May be null if there is no file associated.

attachment_status'null' | 'filtered_by_inbox_resolution' | 'filtered_by_inbox_size' | 'filtered_by_inbox_mime_type' | 'filtered_by_inbox_file_name' | 'filtered_by_hook_custom' | 'filtered_by_queue_mime_type' | 'hook_additional_file' | 'hook_converted' | 'filtered_by_insecure_mime_type' | 'extracted_archive' | 'failed_to_extract' | 'processed' | 'password_protected_archive' | 'broken_image' nullable

Reason why the Document got filtered out on Email ingestion.

metadataMetadata

Client data. May be used to store e.g. external system object IDs. See Metadata for more details.

Example request

{
  "id": 314628,
  "url": "https://example.rossum.app/api/v1/documents/314628",
  "s3_name": "272c2f01ae84a4e19a421cb432e490bb",
  "parent": "https://example.rossum.app/api/v1/documents/203517",
  "email": "https://example.rossum.app/api/v1/emails/1234",
  "annotations": [
    "https://example.rossum.app/api/v1/annotations/314528"
  ],
  "mime_type": "application/pdf",
  "creator": "https://example.rossum.app/api/v1/users/1",
  "created_at": "2020-05-21T12:34:56.789Z",
  "arrived_at": "2020-05-21T12:34:56.789Z",
  "original_file_name": "invoice.pdf",
  "content": "https://example.rossum.app/api/v1/documents/314628/content",
  "attachment_status": "processed",
  "metadata": {
    "some_key": "some_value"
  }
}

Response

OK

idinteger

ID of the document

urlstring url

URL of the document

s3_namestring

Storage key of the document file. Internal use only.

parentstring url nullable

URL of the parent document (e.g. the zip file it was extracted from)

emailstring uri nullable

URL of the email object that document was imported by (only for document imported by email).

annotationsstring[]

List of annotations related to the document. Usually there is only one annotation.

mime_typestring

MIME type of the document (e.g. application/pdf)

creatorstring url nullable

User that created the annotation.

created_atstring date-time

Timestamp of document upload or incoming email attachment extraction.

arrived_atstring date-time

See created_at

original_file_namestring

File name of the attachment or upload.

contentstring url

Link to the document's raw content (e.g. PDF file). May be null if there is no file associated.

attachment_status'null' | 'filtered_by_inbox_resolution' | 'filtered_by_inbox_size' | 'filtered_by_inbox_mime_type' | 'filtered_by_inbox_file_name' | 'filtered_by_hook_custom' | 'filtered_by_queue_mime_type' | 'hook_additional_file' | 'hook_converted' | 'filtered_by_insecure_mime_type' | 'extracted_archive' | 'failed_to_extract' | 'processed' | 'password_protected_archive' | 'broken_image' nullable

Reason why the Document got filtered out on Email ingestion.

metadataMetadata

Client data. May be used to store e.g. external system object IDs. See Metadata for more details.

Example response

{
  "id": 314628,
  "url": "https://example.rossum.app/api/v1/documents/314628",
  "s3_name": "272c2f01ae84a4e19a421cb432e490bb",
  "parent": "https://example.rossum.app/api/v1/documents/203517",
  "email": "https://example.rossum.app/api/v1/emails/1234",
  "annotations": [
    "https://example.rossum.app/api/v1/annotations/314528"
  ],
  "mime_type": "application/pdf",
  "creator": "https://example.rossum.app/api/v1/users/1",
  "created_at": "2020-05-21T12:34:56.789Z",
  "arrived_at": "2020-05-21T12:34:56.789Z",
  "original_file_name": "invoice.pdf",
  "content": "https://example.rossum.app/api/v1/documents/314628/content",
  "attachment_status": "processed",
  "metadata": {
    "some_key": "some_value"
  }
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.