Convert to File
Wraps any value in an in-memory file, ready to be uploaded to storage or sent as a binary HTTP request body.
Properties
| Property | Required | Description |
|---|---|---|
| Data | Yes | The content to write into the file. Supports expressions |
| File name | Yes | The name of the file including extension (e.g. report.json) |
| Content type | Yes | The MIME type of the file (e.g. application/json, text/csv) |
Behaviour
| Input type | File content |
|---|---|
| String | UTF-8 encoded bytes of the string |
| Object or array | JSON-serialised bytes |
| Existing file (BinaryValue) | File name and content type are updated; bytes are unchanged |
The output is a binary file value. Pass it to:
- A File Storage node to persist it to a storage provider
- An HTTP Request node with Body → Binary to upload it directly to an API
Output
The node outputs a binary file. The file is not automatically accessible via expressions as a text field — it is passed as an opaque binary value to the next node. Use it wherever a file input is expected.
Example
Serialise an API response to JSON and upload it to storage:
- Add an HTTP Request node to fetch data from an API.
- Add a Convert to File node:
- Data:
{{ $nodes['HTTP Request'].responseBody }} - File name:
response.json - Content type:
application/json
- Data:
- Connect a File Storage node to upload the result.
Notes
- File name supports expressions, so you can include dynamic values:
report-{{ $now }}.csv. - If Data is already a file (e.g. from a webhook file attachment or a previous File Storage download), the original bytes are kept and only the name and content type are replaced.