Files To GCP Storage
AI-generatedSummary
Upload one or more files encoded as base64 strings to a specified Google Cloud Storage bucket, setting each uploaded file's access to public read and returning their storage paths and public URLs.
Inputs
- Project ID (required) — The Google Cloud project ID where the storage bucket resides.
- Bucket Name (required) — The name of the Google Cloud Storage bucket to upload files to.
- Files (JSON Array) (required) — A JSON array of file objects each containing a base64-encoded string under 'b64', a filename under 'filename', and optionally a mimeType. Each file will be uploaded individually.
Output shape
a list of items each containing a JSON object with an 'uris' array. Each element in 'uris' corresponds to a file and includes status ('success' or 'error'), the storage path, public URL, mimeType, or error details.
If the upload is successful for a file, the output includes the destination path in the bucket and a public URL. On error, the upload attempt records the error message. Processing continues for all files even if some fail, unless 'continueOnFail' is disabled, in which case the node errors immediately.
Examples
Example 1: Upload multiple base64 encoded files to GCS
Provide valid Project ID, Bucket Name, and a JSON array of files with base64 data and filenames. The node uploads files under keys prefixed with 'userUpload/<8-char SHA256 hash>-