Write File
Writes text, a value as JSON, or a copy of another file to a new file, and outputs a reference to it, so a later step can read it back, attach it, or send it on. Reach for it to produce a report, an export, or a file another system expects as an upload—or to bring a file that only exists behind a URL into storage.
Fields
| Field | Description |
|---|---|
| File Name | The file's name, with extension—report.csv, payload.json. Variables can be mixed in to name the file after the data it holds. |
| Content | What to write. Text is written as typed. An object or list bound from an earlier step is written as JSON. A file bound from an earlier step is copied, streamed from wherever it lives. |
| Content Type | The file's MIME type. Pick one of the common types offered, type any other, or bind one from an earlier step—the type an HTTP response came back with, say, when a loop writes one file per item. Left blank, it is the source file's type for a copy, application/json for an object or list, else guessed from the file name's extension, else text/plain. |
What later steps see
| Output | Description |
|---|---|
| File | The written file, as a file reference—its Storage, Path, Content Type, Metadata, and Public URL, a URL the file can be fetched from where the storage offers one. Shown in the variable picker as a file, and what a step with a file input, such as Read File, binds to. |
| Size (bytes) | How many bytes were written. |
| File Name | The name the file was written under. |
Behaviour
Text is written as UTF-8. The file is stored under the automation's own prefix in the site's storage and is deleted when the run that wrote it is archived, so a file exists for as long as its run's history does and no longer.