Skip to content

Upload Storage File

Type: storage-upload-file  ·  Package: Storage Activities v1.0.5  ·  Output: object

Uploads a file from the robot’s disk to a bucket in Zoan Cloud Storage. Returns the file reference (id, bucket, name, size…), which you can pass to other activities, other processes or an AI Workflow.

  1. Reads the file at path (fails if it doesn’t exist).
  2. Uploads it to the bucket bucket (default by default) with the name name (by default, the file’s name). If the bucket doesn’t exist, it is created.
  3. If there is already a file with the same name in the same bucket, it replaces it and keeps its id. That makes repeating the upload safe: it doesn’t create duplicates.

Zoan Cloud checks every file before storing it:

  • It detects the type from the actual content, not from the extension. It rejects executables, scripts and HTML or SVG files.
  • It scans it for malware; if it finds a threat, it rejects the file and doesn’t store it.
  • It checks that the organization has space in its storage (when replacing a file, only the size difference counts).
  • It accepts files up to 100 MB.
ParameterTypeDefaultDescription
pathstring—Local path of the file to upload. E.g.: C:/reports/sales.xlsx.
ParameterTypeDefaultDescription
namestringfile nameTarget name inside the bucket. It can include folders (2026/sales.xlsx).
bucketstring"default"Bucket name: letters, digits, ., _ and -, up to 120 characters.

Returns an object (dictionary) with the stored file reference:

FieldTypeDescription
idstringFile id. If you replaced an existing file, it’s the same id as before.
bucketstringBucket where it was stored.
namestringName inside the bucket.
sizenumberSize in bytes.
content_typestringDetected content type.
created_atstringFile creation date (the original one, if it was replaced).

Read them with file["id"], file["name"]…

MessageCause and fix
'path' is required.You didn’t set path.
File not found.The path doesn’t exist on the robot’s machine. Check the path or generate the file first.
Storage activities require a Zoan Cloud runtime context. Missing: …The process isn’t running from Zoan Cloud or from the Designer signed in.
… HTTP 400: …Invalid bucket name…The bucket name has characters that aren’t allowed (spaces, /, accents) or more than 120 characters.
… HTTP 400: …Bucket '…' is read-only; uploads are not allowed.The bucket is read-only. Use another one or ask an administrator to change its settings in Storage.
… HTTP 400: … (blocked type or malware)The file content is of a blocked type or contains malware. Nothing is stored.
… HTTP 403: … (STORAGE_QUOTA_EXCEEDED)There’s no space available. Delete files you no longer use (for example with Delete Storage File) or ask for more storage.
… HTTP 404: … (BUCKET_NOT_FOUND)The name matches a bucket reserved by Zoan Cloud. Use another name.

All of them arrive with the prefix “Could not upload the file: ”. Catch them with Try / Catch; a transient network error can be retried with Retry.

Upload Storage File path = "C:/reports/daily-close.pdf"
bucket = "reports" name = "2026/09/daily-close.pdf"
→ output: file
Get Storage File URL id = file["id"] → output: link
Log level = info message = "Report saved with id " + str(file["id"])