Skip to content
Hoody.com

Download files from remote URLs into a container’s filesystem, track their progress, cancel them, and review past transfers. A download is started by a GET against a directory and writes a single file at the destination; the request answers once the file has been written. Each download carries a UUID tracked in the active list while it runs and in history afterwards; the successful response returns that UUID after completion. The download manager rejects with 429 when more than 10 downloads and extractions are running at once, so retry then.

Download a file from a remote URL into the named directory. The response is synchronous: the server reads the URL and creates the file before answering. The returned download_id (UUID) identifies the completed job in the history; while it runs, its id is available from the active downloads list. The destination filename is taken from the URL when filename is not given. A download may take up to 12 hours (timeout, default and maximum 43200 seconds). The SDK and CLI wait up to 12 hours and 1 minute for the answer unless you set your own timeout; if the client stops waiting, the download keeps running on the server. Follow it in the active downloads list.

NameInTypeRequiredDescription
directorypathstringYesDestination directory
downloadquerystringYesURL to download from
filenamequerystringNoCustom filename for downloaded file
timeoutqueryintegerNoDownload timeout in seconds. Default and maximum: 43200 (12 hours)

This endpoint takes no request body.

The SDK’s create also accepts an optional owner, the create-time owner of the new file. With owner, create calls POST /api/v1/files/{directory}?download_from instead, which is where owner is read (see File operations).

Terminal window
curl -X GET \
-H "Authorization: Bearer $HOODY_TOKEN" \
"https://{projectId}-{containerId}-files-1.{server}.containers.hoody.com/Downloads?download=https%3A%2F%2Ffiles.example.com%2Fdata.csv&filename=renamed-data.csv&timeout=600"

Get progress for every running download, whether started through the REST surface or the WebDAV-style one. The result is filtered by the caller’s read access on every path the job touches.

This endpoint takes no parameters.

Terminal window
curl -X GET \
-H "Authorization: Bearer $HOODY_TOKEN" \
"https://{projectId}-{containerId}-files-1.{server}.containers.hoody.com/api/v1/downloads"

Get progress for the currently running downloads into a specific directory only.

NameInTypeRequiredDescription
directorypathstringYesDirectory to list active downloads for
downloadsquerystringYesSentinel. Pass an empty string to enable the listing

This endpoint takes no request body.

Terminal window
curl -X GET \
-H "Authorization: Bearer $HOODY_TOKEN" \
"https://{projectId}-{containerId}-files-1.{server}.containers.hoody.com/Downloads?downloads="

Stop a running download, whether it was started through the REST surface or the WebDAV-style one. The request that started the job then answers 409 with error naming the cancellation, and the history record carries status: "cancelled". On a local disk filesystem the partial file the download created is removed; on a mount (FUSE) or a network filesystem the partial file is kept. Requires write permission on the root.

NameInTypeRequiredDescription
idpathstringYesThe id listed by GET /api/v1/downloads

This endpoint takes no request body.

Terminal window
curl -X DELETE \
-H "Authorization: Bearer $HOODY_TOKEN" \
"https://{projectId}-{containerId}-files-1.{server}.containers.hoody.com/api/v1/downloads/a1b2c3d4-e5f6-7890-abcd-ef1234567890"

Get history of past downloads, whether they completed, failed, or were cancelled. The result is filtered by the caller’s read access on every path the job touches.

NameInTypeRequiredDescription
download_historyquerystringYesSentinel. Pass an empty string to enable the listing

This endpoint takes no request body.

Terminal window
curl -X GET \
-H "Authorization: Bearer $HOODY_TOKEN" \
"https://{projectId}-{containerId}-files-1.{server}.containers.hoody.com/?download_history="