Skip to content

Commit b0457bc

Browse files
committed
improve docs
1 parent 4669ec9 commit b0457bc

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

apps/docs/content/docs/en/execution/files.mdx

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,40 @@ When blocks output files (like Gmail attachments, generated images, or parsed do
2323

2424
You can access any of these properties when referencing files from previous blocks.
2525

26+
## The File Block
27+
28+
The **File block** is the universal entry point for files in your workflows. It accepts files from any source and outputs standardized file objects that work with all integrations.
29+
30+
**Inputs:**
31+
- **Uploaded files** - Drag and drop or select files directly
32+
- **External URLs** - Any publicly accessible file URL
33+
- **Files from other blocks** - Pass files from Gmail attachments, Slack downloads, etc.
34+
35+
**Outputs:**
36+
- A list of `UserFile` objects with consistent structure (`name`, `url`, `base64`, `type`, `size`)
37+
- `combinedContent` - Extracted text content from all files (for documents)
38+
39+
**Example usage:**
40+
41+
```
42+
// Get all files from the File block
43+
<file.files>
44+
45+
// Get the first file
46+
<file.files[0]>
47+
48+
// Get combined text content from parsed documents
49+
<file.combinedContent>
50+
```
51+
52+
The File block automatically:
53+
- Detects file types from URLs and extensions
54+
- Extracts text from PDFs, CSVs, and documents
55+
- Generates base64 encoding for binary files
56+
- Creates presigned URLs for secure access
57+
58+
Use the File block when you need to normalize files from different sources before passing them to other blocks like Vision, STT, or email integrations.
59+
2660
## Passing Files Between Blocks
2761

2862
Reference files from previous blocks using the tag dropdown. Click in any file input field and type `<` to see available outputs.

0 commit comments

Comments
 (0)