Documents Node: Fetching and Saving Documents Within a Workflow

WorkflowsEnd User14 min read
What you’ll learnHow to add a Documents node to a workflow, configure it to fetch a specific file or an entire folder from the document library, or save a file generated earlier in the workflow back into the document library at a chosen location.

What it is

The Documents node bridges your automated workflows with your organization's document library. It can do two things: fetch a document (or an entire folder of documents) from Documents and make it available to subsequent workflow steps, or save a file produced by an earlier step — such as a completed report or a signed PDF — back into Documents at a path you specify.

In fetch mode, you can pick a single named file using a point-and-click browser, or select an entire folder so that all files in it are retrieved together (optionally compressed into a ZIP archive). In save mode, you specify where in Documents the file should land — either a fixed folder path or a path determined at runtime from a workflow variable — and give it a custom filename if needed.

This makes document handling fully automated: contracts are archived the moment they are approved, reports are stored in the right project folder as soon as they are generated, and supporting attachments are retrieved and sent along with approval emails — all without anyone manually moving files.

Why it's useful / Key benefits

  • Documents flow automatically through the process. No one needs to download a file, attach it to an email, and then upload it somewhere else. The Documents node handles the transfer inside the workflow.
  • Retrieve exactly the right file or folder. The built-in file browser shows your entire document library organized by entity, instance, and folder. Pick the file you need with a click — no need to know or type path details.
  • Archive outputs where they belong, automatically. Generated reports, signed contracts, and completed forms can be routed into the correct Documents folder the moment a workflow step finishes — keeping your document library organized without manual work.
  • Combine with other nodes for end-to-end document automation. Fetch a template with the Documents node, pass it to an AI Agent node for data extraction, then save the enriched result back to Documents — all in one workflow.
  • ZIP compression for batch downloads. When fetching a folder, toggle on compression to receive all files in a single ZIP archive — useful for archiving or emailing a complete document set.
  • Use dynamic save paths. When the destination folder is determined at runtime (for example, based on which contract or project the request is for), pass the path as a variable and the Documents node resolves it automatically. Target folders are created if they do not already exist.
  • Works with every kind of file. The Documents node is not limited to PDFs — it handles Word documents, images, Excel files, and any other type stored in your document library.

Before you start

  • You must have documents already stored in Documents that you want to fetch, or an upstream node that produces a file variable you want to save.
  • For save operations, you need to know the target entity ID, instance ID, and field name (folder path) in Documents, or have an upstream variable that provides this path.
  • Required permission: Manage Workflows and at least View access on the Documents folder you are fetching from.
  • The Documents node is available in the Visual Designer for all users.

Where to find it: In the Visual Designer's Elements panel, click the BASIC tab and drag the Documents node onto the canvas.

How to use it — step by step

Step 1 — Place the node

  1. Open a workflow in the Visual Designer.
  2. In the Elements panel on the left, click the BASIC tab.
  3. Drag the Documents node onto the canvas at the point in the flow where the document transfer should occur.
  4. Connect it to the preceding node and (for fetch mode) to whatever node will consume the retrieved file.
  5. Double-click the Documents node to open its configuration dialog — the Documents Node dialog.

Step 2 — Label the node (optional)

  1. In the Node Label field at the top, type a descriptive name that will appear on the canvas — for example, "Fetch Signed Contract," "Archive Final Report," or "Retrieve Supporting Docs."
  2. In the Description field, add an optional note explaining what this node does in context.

Step 3 — Choose the operation

  1. Under Operation, click either:

    • Fetch from Documents — to retrieve a file or folder from the document library.
    • Save to Documents — to write a file produced earlier in the workflow into the document library.

    The lower section of the dialog changes to show the relevant options.


Configuring Fetch from Documents

Fetch Mode — Single File

  1. Under Fetch Mode, click Single File (the default).

  2. Click Browse Documents… (the dashed button). The Browse Documents — Select File dialog opens.

  3. Expand the entity and instance rows by clicking them to reveal the folders beneath.

  4. Within a folder, click on the filename of the document you want to select. The dialog closes automatically and the chosen file's name, type, and size are shown in the main dialog.

  5. If you need to change the selection later, click the Change link beside the file preview.

Fetch Mode — Folder

  1. Under Fetch Mode, click Folder.
  2. You have three ways to select the folder:
    • Browse: Click Browse… to open the folder browser. Expand the tree to the folder level and click Select next to the desired folder.
    • Paste path: Paste a Documents folder URL (e.g., https://yourplatform/documents/direct/entity/instance/field) into the paste field. The system auto-parses the entity ID, instance ID, and field name.
    • Type manually: Fill in the three fields — Entity ID, Instance ID, and Field Name — directly.
  3. When all three identifiers are set, a confirmation line appears: ✓ entity / instance / fieldname and a Open in Documents link lets you verify the folder in a new tab.
  4. Compress to ZIP toggle: Turn on to package all files in the folder into a single ZIP archive before passing them to downstream nodes. Leave off to receive an array of individual files.
  5. Current versions only toggle: On (default) — retrieves only the current version of each file. Turn off to include all historical versions (rarely needed).

Convert to PDF toggle: Turn on to convert each fetched file into a PDF before it is passed to downstream nodes — useful when a later step (such as an email attachment or a signature request) expects PDFs.


Configuring Save to Documents

Save source

  1. Under Source File Variable, open the dropdown to see all file-path variables from upstream nodes (nodes that produce files, such as a Python Script node or a previous Documents Fetch node). These variables end in _path and are automatically detected.
  2. Select the variable that holds the file you want to save. The dropdown shows the variable name and the node it comes from.
    • If no variables appear, the note "No file variables found. Add a Python Script or Documents Fetch node before this one." is shown — adjust your workflow structure.

Save target

By default, the node saves automatically into this workflow's own Documents folder — the Save automatically to this workflow's folder toggle is on out of the box, and when it is on you do not need to set an Entity ID, Instance ID, or Field Name at all. This is the simplest option and keeps every file a workflow produces together in one place.

To send the file somewhere else, turn that toggle off and specify the destination in one of two ways:

Option A — From a variable (runtime path): 21. In the From variable section, select a string variable from the dropdown. At runtime, this variable must resolve to a path in the format /documents/direct/entity/instance/field. This is useful when the destination depends on the workflow instance — for example, saving each approved contract into the folder for that specific contract. - When a variable is selected, the Fixed path section below is greyed out.

Option B — Fixed path: 22. If the destination is always the same folder, fill in the Entity ID, Instance ID, and Field Name fields directly, or paste a Documents folder URL into the paste field to auto-fill them. 23. A confirmation line and Open in Documents link appear once all three fields are set so you can verify the target folder.

Custom file name

  1. In the Custom File Name field, optionally type a filename (including extension) to rename the file as it is saved. If left blank, the file keeps its original name from the source variable.

  2. Convert to PDF before saving toggle: Turn on to convert the source file to PDF before it lands in Documents. Use this when you want everything archived as PDF regardless of the original format.

  3. Click Save in the dialog footer to confirm the configuration. The dialog closes.

  4. Save the full workflow (Ctrl+S or the Save toolbar button).

Options & settings explained

Common to both operations

Field Description
Node Label Display name shown on the canvas node. Not required; defaults to "Documents."
Description Optional note visible in version history and when hovering the node.
Operation toggle Switches between Fetch from Documents and Save to Documents. All settings reset when you switch.

Fetch mode fields

Field Description
Single File / Folder buttons Switches between single-file and folder-level fetch.
Browse Documents… button Opens the file browser to pick a specific file from the document library. Appears when Single File is selected.
Selected File preview Shows the filename, MIME type, and file size of the chosen file. A Change link allows re-selection.
Browse… link Opens the folder browser to pick a folder. Appears when Folder is selected.
Paste path field Accepts a Documents URL or path string to auto-populate Entity ID, Instance ID, and Field Name.
Entity ID The top-level identifier of the document entity in Documents (e.g., "procurement", "hr").
Instance ID The instance within the entity (e.g., a specific contract or employee record ID).
Field Name The folder within the instance (e.g., "signed_documents", "attachments").
Open in Documents link Opens the identified folder in Documents in a new tab for verification. Appears once all three IDs are filled.
Compress to ZIP toggle Compresses all files in the folder into a single ZIP archive before making them available downstream.
Current versions only toggle When on (default), fetches only the current version of each file. When off, includes historical versions.
Convert to PDF When on, each fetched file is converted to PDF before being passed to downstream nodes.

Save mode fields

Field Description
Source File Variable Dropdown of all _path-typed variables from upstream nodes. Select the variable holding the file to save.
Save automatically to this workflow's folder toggle On by default. When on, the file is saved into the workflow's own Documents folder and no target path is needed. Turn off to choose a specific destination below.
From variable section Dropdown of all string variables. Select a variable that resolves to a /documents/direct/entity/instance/field path at runtime. Takes precedence over the Fixed path section when set.
Fixed path — Paste field Accepts a Documents URL to auto-fill the three target fields.
Fixed path — Entity ID, Instance ID, Field Name Manual entry of the three-part destination path.
Custom File Name Optional rename for the saved file. Leave blank to keep the original name. If a file with that name exists in the folder, a new version is created.
Convert to PDF before saving toggle When on, the source file is converted to PDF before it is stored in Documents.

File browser controls (Browse Documents dialogs)

Control Description
Search field Filters the tree by filename, entity ID, instance ID, or field name.
Entity rows Top-level expandable rows showing the number of instances. Click to expand.
Instance rows Second-level expandable rows showing the number of folders. Click to expand.
Field/folder rows Third-level rows showing the folder name and file count. In folder mode, click Select to choose this folder.
File rows Leaf-level rows showing filename and size. In file mode, click a row to select that file.
Cancel button Closes the browser without selecting anything.

Tips & best practices

  • Use the Browser rather than typing paths manually. Typos in entity IDs or field names are the most common source of configuration errors. The browser eliminates this by letting you select visually.
  • Paste a Documents URL for fast path entry in Save mode. Open the target folder in Documents, copy the URL from the address bar, and paste it into the paste field. The path is parsed automatically.
  • Design fetch nodes before the nodes that consume their output. The file variable produced by a Documents Fetch node is only available to nodes that come after it in the workflow graph.
  • Use the Compress to ZIP option for email attachments. If an Email node downstream needs to include the full folder as a single attachment, turning on ZIP compression produces a single file that attaches cleanly.
  • For save operations, confirm the target folder exists by clicking Open in Documents. If it does not exist, the node will create it automatically — but previewing helps confirm you have the right path.
  • Custom file names should include the extension. For example, use final_report.pdf rather than final_report. The platform does not add an extension automatically.
  • Combine Fetch and Save to implement document transformation workflows. Fetch a template, pass it to an AI or script node for enrichment, then Save the result back — a complete document-processing pipeline without any manual steps.
  • Current versions only is on by default and is the right choice for almost all workflows. Turn it off only if you specifically need to retrieve the entire version history of a file.

Frequently asked questions

Q: What file types does the Documents node support? Any file type stored in Documents. The node is agnostic to format — it works with PDFs, Word documents, Excel files, images, ZIP archives, and anything else in the document library.

Q: In Folder mode, does the node retrieve files from subfolders too? The node retrieves all files in the specified field-level folder. Documents's folder structure is Entity → Instance → Field → Files; there is no additional subfolder nesting, so all files at the field level are returned.

Q: What happens if the target folder does not exist when I run a Save operation? The platform creates the folder automatically along the path you specified. If any part of the path (entity, instance, or field) does not exist, it is created at the time the node runs.

Q: Can I save a file without renaming it? Yes. Leave the Custom File Name field blank and the file is saved with its original filename from the source variable.

Q: Can I use a workflow variable to build the save path dynamically? Yes. Use the From variable option in the Target Location section. At runtime, the variable must contain a string in the format /documents/direct/entity/instance/field. This is powerful for workflows where the destination depends on the specific record being processed — for example, saving each signed contract into the folder for that contract's instance.

Q: What is the difference between Single File and Folder fetch mode? Single File retrieves one specific document you identify by clicking it in the browser. The result is a single file available as a variable. Folder retrieves every file in a specified folder. The result is an array of files (or a ZIP archive if compression is enabled).

Q: What happens if the file I am trying to fetch has been deleted from Documents? The workflow step will fail with an error. Monitor All Instances and the Workflow Detail View for error states, and ensure source documents are not deleted while workflows are running.

Q: Can I have two Documents nodes in the same workflow? Yes. Each node operates independently. For example, you might fetch a template at step 3 and then save the completed result at step 8. Name each node clearly on the canvas to keep the flow readable.

Q: My Source File Variable dropdown is empty. What should I do? The dropdown only shows _path-typed variables from upstream nodes. Add a node that produces a file before the Documents Save node — for example, a Python Script node that generates a file, or a Documents Fetch node earlier in the workflow. The path variable from that upstream node will then appear in the dropdown.

Still stuck? See Get Help with Support or reach your workspace administrator.