Skip to main content

Documents & Media

These node types extract content from documents and images, generate or manipulate PDFs, spreadsheets, and images, and convert between text and audio. Generated files are written to the workspace file store for the run when supported; otherwise content is returned inline as base64.

document

Extracts content from a PDF, image, or HTML source via PDF text extraction, OCR, HTML stripping, or LLM vision analysis.

{
"id": "read_invoice",
"type": "document",
"config": {
"operation": "extract_pdf",
"source_type": "url",
"source": "{{steps.fetch_invoice.output.url}}"
}
}
FieldTypeDefaultDescription
operationstring"extract_pdf"One of extract_pdf, ocr, html_to_text, vision_analyze.
source_typestring"url"One of url, base64, file_path — how source is interpreted.
sourcestring (expression)URL, base64-encoded content, or absolute file path, depending on source_type.
mime_typestring"application/pdf"MIME type to assume for base64/file_path sources.

operation: extract_pdf

Extracts text from a PDF using pdftotext (poppler), with pdfinfo for page count. Requires poppler-utils on the worker.

Output:

FieldTypeDescription
textstringExtracted text (layout-preserving).
pagesnumberPage count.
char_countnumberCharacter count of text.
word_countnumberWord count of text.

operation: ocr

Runs Tesseract OCR over the fetched image/document. Requires tesseract-ocr on the worker.

FieldTypeDefaultDescription
languagestring"eng"Tesseract language code passed to -l.

Output: { "text", "char_count", "word_count", "language" }.

operation: html_to_text

Strips HTML tags/whitespace from source (treated as raw HTML, not fetched).

Output: { "text", "char_count", "word_count" }.

operation: vision_analyze

Sends the fetched image/document to a multimodal LLM with a prompt and returns its response.

FieldTypeDefaultDescription
promptstring (expression)"Describe and extract all content from this document."Instruction sent to the vision model alongside the image.
providerstring"anthropic""anthropic" or "openai". Unrecognized values fall back to anthropic.
modelstring"claude-sonnet-4-6" (anthropic) / "gpt-4o" (openai)Vision-capable model to call.
api_keystring (expression)Required. API key for the chosen provider, e.g. {{secret.ANTHROPIC_API_KEY}}.

Output: { "text": "<model response>", "model": "<model used>", "provider": "anthropic" | "openai" }.

pdf

PDF manipulation utilities — page count, text extraction, merge, split, rotate, and metadata. PDF input/output is base64-encoded inline (not workspace files).

{
"id": "merge_reports",
"type": "pdf",
"config": {
"operation": "merge",
"pdfs": ["{{steps.report_a.output.pdf_base64}}", "{{steps.report_b.output.pdf_base64}}"]
}
}
FieldTypeDefaultDescription
operationstring"count_pages"One of count_pages, extract_text, merge, split, rotate, metadata.
pdfstring (expression, base64)Source PDF, required for count_pages, extract_text, split, rotate, metadata.
pdfsarray of strings (expression, base64)Two or more source PDFs, required for merge.
degreesnumber90Rotation angle for rotate.

Operations & outputs

OperationOutput fields
count_pagespage_count
extract_texttext, char_count, word_count (parsed from raw Tj/TJ PDF operators — best-effort, not OCR)
mergepdf_base64, size (bytes) — concatenation of pdfs in order
splitpages (array of { page, pdf_base64, size }, one per page), count
rotatepdf_base64, degrees, size
metadatapage_count, author, creator, title, subject, keywords, producer

spreadsheet

Parses or generates CSV data. No xlsx or Google Sheets support — for spreadsheet APIs use the relevant connector.

{
"id": "parse_export",
"type": "spreadsheet",
"config": {
"operation": "parse_csv",
"value": "{{steps.download.output.text}}",
"has_header": true
}
}
FieldTypeDefaultDescription
operationstring"parse_csv""parse_csv" or "generate_csv".
delimiterstring","First character used as the field delimiter for both operations.

operation: parse_csv

FieldTypeDefaultDescription
valuestring (expression)Raw CSV text to parse.
has_headerbooleantrueIf true, the first row is used as column names; otherwise columns are named col1, col2, ...

Output: { "rows": [{ "<header>": "<cell>", ... }], "headers": ["..."], "count": <number of rows> }.

operation: generate_csv

FieldTypeDefaultDescription
headersarray of strings, JSON array string, or comma-separated string (expression)Column headers, written as the first row if non-empty.
rowsarray (expression)Each element is either an array of cell values (positional) or an object keyed by header name.

Output: { "csv": "<csv text>", "rows": <number of rows written, including header> }.

image-gen

Generates images from a text prompt via OpenAI, Stability AI, or fal.ai. Returns image URLs or base64 — not written to the workspace file store.

{
"id": "generate_hero",
"type": "image-gen",
"config": {
"provider": "openai",
"api_key": "{{secret.OPENAI_API_KEY}}",
"prompt": "A futuristic city at sunset, cinematic lighting",
"size": "1024x1024"
}
}
FieldTypeDefaultDescription
providerstring"openai""openai", "stability", or "fal".
api_keystring (expression)Required. Provider API key.
promptstring (expression)Required. Image description.
negative_promptstring (expression)Stability and fal only — content to avoid.
modelstringprovider-specific (below)Model/engine identifier.
sizestring"1024x1024"Image dimensions, "<width>x<height>".
seednumber-1 (random)Stability and fal only.

provider: openai

FieldTypeDefaultDescription
modelstring"dall-e-3""dall-e-3" or "dall-e-2".
sizestring"1024x1024""1024x1024", "1792x1024", or "1024x1792" (dall-e-3).
qualitystring"standard""standard" or "hd" (dall-e-3 only).
stylestring"vivid""vivid" or "natural" (dall-e-3 only).
nnumber1Number of images (1-4). dall-e-3 always generates 1.

Output: { "image_url", "image_urls": [...], "revised_prompt", "model", "provider": "openai" }.

provider: stability

FieldTypeDefaultDescription
modelstring"sd3""sd3", "sd3-turbo" (v2beta API), or an SDXL v1 engine id (e.g. "sdxl-1.0").
stepsnumber25Inference steps (SDXL v1 only).
cfg_scalenumber7Guidance scale (SDXL v1 only).

Output: { "image_url": "", "image_urls": [], "image_base64": "<base64 PNG>", "model", "provider": "stability" } — Stability returns image bytes directly, not a URL.

provider: fal

FieldTypeDefaultDescription
modelstring"fal-ai/flux/schnell"fal.ai model slug, e.g. "fal-ai/flux/dev".
stepsnumber4Inference steps.
nnumber1Number of images.

Output: { "image_url", "image_urls": [...], "seed", "model", "provider": "fal" }.

image-helper

Image manipulation using the Go standard library (PNG/JPEG only). All inputs/outputs are base64-encoded — not workspace files.

{
"id": "thumbnail",
"type": "image-helper",
"config": {
"operation": "resize",
"image": "{{steps.generate_hero.output.image_base64}}",
"width": 256
}
}
FieldTypeDefaultDescription
operationstring"get_metadata"One of get_metadata, to_base64, from_base64, resize, crop, rotate, grayscale.
imagestring (expression, base64 or data URL)Source image, required for get_metadata, resize, crop, rotate, grayscale. A data:...;base64, prefix is stripped automatically.
output_formatstringsource format"jpeg"/"jpg" or "png" (default) for the encoded result.
qualitynumber85JPEG quality (1-100), used when output_format is "jpeg"/"jpg".

Operations & outputs

OperationExtra configOutput fields
get_metadatawidth, height, format, size_bytes, aspect_ratio
to_base64content (string, expression), format (default "png")base64, data_url
from_base64base64 (expression)content (decoded bytes as string), size
resizewidth, height (numbers — if only one is given, the other is computed to preserve aspect ratio)image_base64, width, height, format
cropx, y, width, height (numbers, default full image at 0,0)image_base64, width, height, format
rotatedegrees (number, default 90; multiples of 90 supported, others pass through unrotated)image_base64, width, height, degrees, format
grayscaleimage_base64, width, height, format

tts

Converts text to speech via ElevenLabs or OpenAI. The resulting audio is written to the run's workspace files when a workspace store is configured; otherwise it's returned as base64.

{
"id": "narrate",
"type": "tts",
"config": {
"provider": "elevenlabs",
"api_key": "{{secret.ELEVENLABS_API_KEY}}",
"text": "{{steps.script.output.text}}",
"format": "mp3"
}
}
FieldTypeDefaultDescription
providerstring"elevenlabs""elevenlabs" or "openai".
api_keystring (expression)Required. Provider API key.
textstring (expression)Required. Text to synthesize.
voice_idstring"21m00Tcm4TlvDq8ikWAM" (Rachel, elevenlabs) / "alloy" (openai)ElevenLabs voice ID, or OpenAI voice name (alloy, echo, fable, onyx, nova, shimmer).
modelstring"eleven_multilingual_v2" (elevenlabs) / "tts-1" (openai)tts-1/tts-1-hd for OpenAI.
formatstring"mp3""mp3", "wav", or "opus".
speednumber1.0OpenAI only, 0.25-4.0.
stabilitynumber0.5ElevenLabs only, 0.0-1.0 voice stability.
similaritynumber0.75ElevenLabs only, 0.0-1.0 similarity boost.

Output:

FieldTypeDescription
audio_urlstringWorkspace file path (/api/v1/workspaces/runs/{exec_id}/files/audio.<ext>), present when a workspace store is configured.
audio_base64stringBase64-encoded audio bytes, present only when audio_url is not.
formatstring"mp3", "wav", or "opus".
providerstringProvider used.
voice_idstringVoice used.
modelstringModel used.
char_countnumberNumber of characters synthesized.

stt

Transcribes audio to text via OpenAI Whisper, Groq, NVIDIA NIM, Deepgram, or AssemblyAI.

{
"id": "transcribe_call",
"type": "stt",
"config": {
"provider": "openai",
"api_key": "{{secret.OPENAI_API_KEY}}",
"audio_url": "{{steps.recording.output.audio_url}}"
}
}
FieldTypeDefaultDescription
providerstring"openai"One of openai, groq, nvidia, deepgram, assemblyai.
api_keystring (expression)Required for all providers except nvidia (optional for self-hosted NIM).
audio_urlstring (expression)URL to fetch audio from (preferred). One of audio_url/audio_base64 is required.
audio_base64string (expression)Base64-encoded audio bytes, alternative to audio_url.
languagestringauto-detectBCP-47 language code, e.g. "en", "es", "fr".
modelstringprovider-specific (below)Transcription model.
base_urlstring"https://integrate.api.nvidia.com/v1"NVIDIA only — NIM endpoint (e.g. http://localhost:8000/v1 for self-hosted).
diarizestring ("true"/"false")"false"Deepgram and AssemblyAI only — enable speaker diarization.
punctuatestring ("true"/"false")"true"Deepgram only — add punctuation.

Default models per provider

ProviderDefault model
openaiwhisper-1
groqwhisper-large-v3-turbo
nvidianvidia/parakeet-ctc-1.1b (also supports nvidia/canary-1b)
deepgramnova-2
assemblyaibest

Output:

FieldTypeDescription
textstringFull transcript.
wordsarray{ word, start, end } (and confidence/speaker for Deepgram/AssemblyAI), when available.
confidencenumberOverall confidence 0-1 (Deepgram/AssemblyAI only).
durationnumberAudio duration in seconds, when available.
languagestringDetected/used language code.
providerstringProvider used.
modelstringModel used.

Next