Skip to main content
POST

Overview

Asks the server to recompute the SHA-256 hash of the stored file content and compare it against the hash you provide. Use this after an upload to confirm the file was stored without corruption, end to end. The server streams the stored object in 2 MB chunks, so this works for large files without loading them in memory. When verification succeeds and the entry has no stored hash yet, the computed SHA-256 is saved to the entry’s file_hash field for future lookups.
Only the owner of the file can call this endpoint. Other users receive a 403 error.

Path Parameters

integer
required
The numeric file entry ID

Request Body

string
required
Expected SHA-256 hex digest of the file content (exactly 64 characters, case-insensitive)

Response

string
Request status (success)
boolean
true when the stored content matches the provided hash
string
SHA-256 computed by the server from the stored content. Omitted when the file could not be read.
string
Only present on failure to read the file: file_not_found or read_failed
For large files, computing the SHA-256 on the server means reading the whole object from storage. Prefer calling this once after upload rather than on every sync pass; afterwards you can rely on the file_hash field returned by Get File Entry.