Skip to main content
Version: 1.5.0

Tower deposit with fileKey

Overview​

Tower no longer creates a document only after the file is stored under a guessed path. It sends the resolved object key as fileKey on create, uploads the key neo returns, then confirms the draft.

How it works​

  1. Protect stamps the file hash and resolves storagePath → fileKey.
  2. POST /documents with agent iptower and fileKey creates an invisible draft and a remotefile (tower: true). Neo may suffix the key (-2, -3) and returns storageKey.
  3. Tower uploads bytes to that storageKey with its own credentials.
  4. POST /documents/:id/confirm reveals the document so lists, extract, download and proof can see it.

Key files​

  • src/domains/document/document.service.ts — draft create, confirm, remotefile tower: true
  • src/domains/document/deposit-key.ts — key suffixes
  • src/domains/document/older-document.ts — background olderDocumentId link

Technical decisions​

Box classic deposits still require fileId. Drafts are hidden from lists and extract until confirm. Hash dedup only when noDuplicate is set.