Leapwork Documentation
Compress File
The Compress File block is used to generate a ZIP archive from one or more input files during the execution of an automation flow. This is particularly useful when multiple files need to be passed to downstream blocks like Send Email or Web File Upload as a single attachment.
When fully expanded, the following is an example of the Compress File block:
The Compress File block header
The left blue input connector in the header is used to inject runtime triggers into the block. This can be linked to any upstream block that should activate the compression logic.
The right blue output connector in the header is triggered when the ZIP file is successfully created, and it allows the flow to continue using the compressed file output.
The block title Compress File can be changed by double-clicking on it and entering a custom title.
Files input
The Files Input field is where one or more files are provided for compression. These files can be injected dynamically from other blocks using the blue input connector.
Once added, the files will be packaged into a ZIP archive when the block executes.
ZIP file output
The resulting ZIP file can be used immediately within the flow by linking it via the blue output connector to other blocks. This makes integration into larger workflows seamless and efficient.
Failed
The Failed output is triggered when compression fails. Common causes include:
-
No input files provided.
-
Input files exceed the 500MB size limit.
-
Internal errors during compression.
Use the Failed connector to branch the flow for error handling, alerts, or retries.
Created 22.05.25