Archive
The Archive node bundles one or more files from workflow storage into a single ZIP archive. It is the standard way to package multiple outputs — reports, documents, attachments — into one file for delivery, upload, or storage. Files are streamed from storage, compressed, and the resulting archive is written back to workflow storage for downstream nodes to use.
Overview
The Archive node is essential when you need to:
- Package multiple files for delivery - Combine documents into one ZIP to email, upload, or hand off
- Bundle batch outputs - Collect the files produced by a loop into a single archive
- Simplify transfers - Send one file to an FTP/SFTP server or partner instead of many
- Organize archive contents - Lay files out under custom names or folders inside the ZIP
- Reduce size - Apply compression to large or numerous text-based outputs
Configuration
The node requires no credential — it operates entirely on files already in workflow storage.
Resource
The resource to consume. Only Archive is available.
Action
The operation to perform.
- Create Archive (
createArchive, default) - Bundle one or more files into a ZIP archive.
Input Mode
How the list of files to include is supplied:
| Mode | Value | Use when |
|---|---|---|
| File List (default) | static | You want to add files one at a time, optionally renaming each inside the archive |
| Expression | expression | The file list comes from an upstream node as an array (e.g. the output of a loop) |
Files (File List mode)
Add one entry per file to include. Each entry has:
- File (required) - A file reference from a previous node (a storage path). Supports expressions.
- Name in Archive (optional) - Override the filename used inside the ZIP. Supports subpaths like
invoices/2024.pdfto place the file in a folder within the archive. Defaults to the original filename.
Files Expression (Expression mode)
An expression that resolves to an array of file references to include. Use this when the set of files is dynamic — for example, the collected output of a loop:
{{ $json.generatedFiles }}
Each item may be a plain file reference, or an object with fileSource and optional nameInZip to override its name inside the archive.
Output Filename (required)
The name of the generated ZIP file. Defaults to archive.zip. Supports expressions for dynamic naming:
shipment-{{ $json.shipmentId }}.zip
Output
The node returns the storage path of the generated ZIP archive as a string, relative to the current execution (the same convention other file-producing nodes use). Downstream nodes reference it to send, upload, or store the file:
taskName/archive.zip
File References
File references are resolved relative to the current workflow execution, with one exception:
- A reference that begins with
triggeris treated as already-qualified (e.g. a file staged by a trigger node) and used as-is. - Any other reference is resolved within the current execution's storage.
This matches how other Splice nodes pass files between steps, so the File / Files Expression values are typically just the paths emitted by upstream nodes.
Example Usage & Common Use Cases
Bundle Reports for Email Delivery
[Spreadsheet: build report] → [PDF Converter: cover sheet] → [Archive] → [Send Email: attach output]
Archive:
Input Mode: File List
Files:
- File: {{ steps.report.output }}
- File: {{ steps.cover.output }} Name in Archive: cover.pdf
Output Filename: daily-reports-{{ $json.date }}.zip
Package Loop Output
[Loop: rows] → [Generate file per row] → (collect paths) → [Archive] → [FTP: upload]
Archive:
Input Mode: Expression
Files Expression: {{ $json.generatedFiles }}
Output Filename: batch-{{ $json.batchId }}.zip
Organize Files into Folders Inside the ZIP
Archive:
Input Mode: File List
Files:
- File: {{ steps.inv.output }} Name in Archive: invoices/invoice.pdf
- File: {{ steps.bol.output }} Name in Archive: bols/bol.pdf
Output Filename: shipment-docs.zip
How It Works
- Receive the request - The node is invoked with the file list (or expression) and output filename.
- Resolve the file list - File List entries (or the resolved expression array) are validated; the list must be non-empty and every entry must have a file reference.
- Resolve keys - Each reference is qualified against the current execution unless it starts with
trigger; the in-archive name defaults to the source's base filename unless Name in Archive overrides it. - Stream and compress - Each source file is streamed from storage and appended to the ZIP in order, compressed, and the archive is uploaded back to storage as it is produced (constant memory, regardless of file sizes).
- Return - The archive's storage path (
task/<output filename>) is returned for downstream nodes.
Best Practices
- Build the file list from upstream output - Use Expression mode with the array emitted by a loop or prior node rather than hardcoding paths.
- End the filename in
.zip- Keep the output filename's extension consistent so downstream tools and partners recognize the format. - Use unique output filenames - Incorporate an ID or date (e.g.
{{ $json.shipmentId }}) so repeated runs don't overwrite a previous archive in the same task. - Avoid in-archive name collisions - Files default to their base filename, so two sources with the same filename collide. Use Name in Archive to disambiguate (e.g. place them in different folders).
- Reference trigger files directly - Files staged by a trigger (paths starting with
trigger) can be archived as-is.
Integration Patterns
With File Generation
Generate Files → Archive → Send Email / FTP Upload
With Loops
Loop → Produce File (each) → Collect Paths → Archive → Deliver
With File Transfer
Archive → FTP Upload → Confirm Delivery
Troubleshooting
Common Issues
- "files must be a non-empty array" - File List mode received no entries. Add at least one file.
- "filesExpression must resolve to a non-empty string or array" - Expression mode's expression resolved to nothing. Confirm the upstream array is populated.
- "fileSource is required" - A File List entry is missing its file reference. Set the File value on each entry.
- File not found during archiving - A referenced file doesn't exist in storage. Confirm the upstream node produced it and the path is correct (and that non-trigger paths belong to the current execution).
- Overwritten archive - A fixed Output Filename reused across runs overwrites the prior file. Add a unique token to the name.
- Duplicate entries in the ZIP - Two sources share a base filename. Set Name in Archive to keep them distinct.
Debugging Tips
- Check the resolved file list - Inspect the node input to confirm the expected references, especially in Expression mode.
- Verify the returned path - The node returns the archive's storage path; confirm downstream nodes reference that value.
Related
- Spreadsheet - Generate CSV/Excel files to bundle
- PDF Converter - Produce PDFs to include in an archive
- FTP - Upload the generated archive to a remote server
- Send Email - Attach the archive to an outbound message