Skip to content
Hoody.com

Use these endpoints to upload, download, and manage files and avatars attached to notebooks. The notebook service supports both direct multipart uploads for avatars and the TUS protocol for resumable file uploads.

All endpoints run on the notes container inside a project. Replace {projectId}, {containerId}, and {server} with your real identifiers, or substitute the house example 67e89abc123def456789abcd-890abcdef12345678901cdef and server node-us.

Avatars are images (JPEG, PNG, or WebP) that identify users within the notebook service. Uploaded avatars are normalized to a 500x500 JPEG before storage.

Uploads a raw image (JPEG, PNG, or WebP) as an avatar. The image is resized to 500x500 and converted to JPEG.

This endpoint takes no parameters.

Send the image bytes as the raw request body (no JSON envelope).

Terminal window
curl -X POST "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/avatars" \
-H "Authorization: Bearer $HOODY_TOKEN" \
-H "Content-Type: image/png" \
--data-binary @./avatar.png

Returns the avatar image as JPEG binary data.

NameInTypeRequiredDescription
avatarIdpathstringYesThe unique identifier of the avatar to download
Terminal window
curl -X GET "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/avatars/8f3b2c1d4e5f6a7b8c9d0e1f2a3b4c5d" \
-H "Authorization: Bearer $HOODY_TOKEN" \
--output avatar.jpg

Files are user-uploaded attachments that live inside a notebook. Each file belongs to exactly one notebook and may be referenced by zero or more documents inside that notebook.

GET /api/v1/notes/notebooks/{notebookId}/files

Section titled “GET /api/v1/notes/notebooks/{notebookId}/files”

Returns a paginated list of files uploaded to a notebook. Supports limit/offset pagination.

NameInTypeRequiredDescription
notebookIdpathstringYesThe unique identifier of the notebook to list files from
limitqueryintegerNoMaximum number of files to return (default: 50)
offsetqueryintegerNoNumber of files to skip before returning results (default: 0)
Terminal window
curl -X GET "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/notebooks/67e89abc123def456789abcd/files?limit=20&offset=0" \
-H "Authorization: Bearer $HOODY_TOKEN"

GET /api/v1/notes/notebooks/{notebookId}/files/{fileId}

Section titled “GET /api/v1/notes/notebooks/{notebookId}/files/{fileId}”

Downloads the content of an uploaded file. Returns the binary data with the original content type.

NameInTypeRequiredDescription
notebookIdpathstringYesThe unique identifier of the notebook that owns the file
fileIdpathstringYesThe unique identifier of the file to download
Terminal window
curl -X GET "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/notebooks/67e89abc123def456789abcd/files/8f3b2c1d4e5f6a7b8c9d0e1f2a3b4c5d" \
-H "Authorization: Bearer $HOODY_TOKEN" \
--output quarterly-report.pdf

Large file uploads use the TUS protocol so that transfers can be paused, resumed, and aborted. Each of the four HTTP verbs below is dispatched to the same TUS endpoint based on the request method.

The lifecycle is:

  1. POST creates the upload session and returns the initial offset (typically 0).
  2. PATCH sends one or more chunks, advancing the offset reported back to the client.
  3. HEAD queries the current offset, allowing the client to resume after a disconnect.
  4. DELETE aborts the upload and discards any partial bytes.

POST /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus

Section titled “POST /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus”

Creates a new resumable upload session for the given file.

NameInTypeRequiredDescription
notebookIdpathstringYesThe unique identifier of the notebook that will own the file
fileIdpathstringYesThe unique identifier of the file slot reserved for this upload
Terminal window
curl -X POST "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/notebooks/67e89abc123def456789abcd/files/8f3b2c1d4e5f6a7b8c9d0e1f2a3b4c5d/tus" \
-H "Authorization: Bearer $HOODY_TOKEN" \
-H "Tus-Resumable: 1.0.0" \
-H "Upload-Length: 184320"

PATCH /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus

Section titled “PATCH /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus”

Uploads a chunk of bytes to an existing TUS session. The Upload-Offset header marks where the chunk begins; the response carries the new offset on success.

NameInTypeRequiredDescription
notebookIdpathstringYesThe unique identifier of the notebook that owns the upload
fileIdpathstringYesThe unique identifier of the file being uploaded
Terminal window
curl -X PATCH "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/notebooks/67e89abc123def456789abcd/files/8f3b2c1d4e5f6a7b8c9d0e1f2a3b4c5d/tus" \
-H "Authorization: Bearer $HOODY_TOKEN" \
-H "Tus-Resumable: 1.0.0" \
-H "Upload-Offset: 0" \
-H "Content-Type: application/offset+octet-stream" \
--data-binary @./chunk-0.bin

HEAD /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus

Section titled “HEAD /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus”

Queries the current offset of an in-progress TUS upload so a client can resume after a disconnect.

NameInTypeRequiredDescription
notebookIdpathstringYesnotebookId path parameter
fileIdpathstringYesfileId path parameter
Terminal window
curl -X HEAD "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/notebooks/67e89abc123def456789abcd/files/8f3b2c1d4e5f6a7b8c9d0e1f2a3b4c5d/tus" \
-H "Authorization: Bearer $HOODY_TOKEN" \
-H "Tus-Resumable: 1.0.0"

DELETE /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus

Section titled “DELETE /api/v1/notes/notebooks/{notebookId}/files/{fileId}/tus”

Aborts an in-progress TUS upload and discards any bytes received so far.

NameInTypeRequiredDescription
notebookIdpathstringYesThe unique identifier of the notebook that owns the upload
fileIdpathstringYesThe unique identifier of the file being uploaded
Terminal window
curl -X DELETE "https://{projectId}-{containerId}-notes-1.{server}.containers.hoody.com/api/v1/notes/notebooks/67e89abc123def456789abcd/files/8f3b2c1d4e5f6a7b8c9d0e1f2a3b4c5d/tus" \
-H "Authorization: Bearer $HOODY_TOKEN" \
-H "Tus-Resumable: 1.0.0"