Optexity can download files from websites and upload files to forms.
Download Methods
| Method | Trigger |
|---|
| Click download link | click_element with expect_download=true |
| Select export option | select_option with expect_download=true |
| Save page as PDF | download_url_as_pdf |
Click to Download
| Property | Type | Default | Description |
|---|
expect_download | bool | False | Action triggers download |
download_filename | str | None | Auto-generated UUID | Filename for download |
Select to Download
Save Page as PDF
Capture current page or specific URL as PDF:
Multiple Downloads
Use for_loop_node to download multiple files:
Use variable substitution in download_filename to create unique filenames.
Upload Files
The file source must be exactly one of file_path or file_url. Setting both, or neither, is rejected by the schema.
Upload from a local path:
Upload from a public URL (downloaded to a temp file just before upload, then cleaned up):
| Property | Description |
|---|
command / xpath | Locator for file input |
file_path | Absolute or relative local path (supports variables) |
file_url | Public http:// or https:// URL (supports variables). 120s download timeout. The automation fails if the download errors or returns a non-2xx status. The file extension is derived from the URL path, Content-Disposition, or Content-Type (in that order) so file inputs that check extensions still validate. |
Download Storage
Downloaded files are stored in the task’s downloads directory:
Waiting for Downloads
Optexity automatically waits for downloads when expect_download=true. For large files, increase timing:
Best Practices
| Practice | Recommendation |
|---|
Set expect_download | Always when download is expected |
| Use descriptive filenames | Include IDs or dates |
| Handle large files | Increase end_sleep_time |
| Validate upload paths | Ensure absolute paths are accessible |