Duaer

Organizations and data

Work with files and images in Duaer

Understand and use binary data in Duaer.

Binary data is any file-type data, such as images or documents. A file does not live in json. It sits on binary on the same item, under a name such as invoice.

"binary": {
	"invoice": {
		"data": "<base64>",
		"mimeType": "application/pdf",
		"fileName": "invoice.pdf",
		"fileExtension": "pdf"
	}
}

Working with binary data in your workflow

You can use nodes or code. Key nodes:

  • Convert to File: turn text, JSON, or a spreadsheet into a file on binary.
  • Extract From File: read a file on binary back into rows or text.
  • Read/Write Files from Disk: read and write the machine disk when you self-host. A cloud instance does not have your disk.
  • HTML, XML, Compression, Edit Image, and FTP also take and return binary slots.

Configure binary data mode when self-hosting

On a self-hosted instance, choose where binary data is stored with environment variables such as DUAER_DEFAULT_BINARY_DATA_MODE (default keeps data in memory; filesystem, s3, azure, or database select those stores), DUAER_BINARY_DATA_STORAGE_PATH, and DUAER_AVAILABLE_BINARY_DATA_MODES.

Changing the store does not change the binary name a node uses. You cannot pin output that includes binary. When execution data is redacted, binary is removed from the record.

Questions

Where does a file sit on an item?

In Duaer, not in json. On binary under a name such as invoice, with base64 in data plus mimeType, fileName, and fileExtension.

How do you choose binary storage when self-hosting, and can you pin binary output?

In Duaer, use environment variables such as DUAER_DEFAULT_BINARY_DATA_MODE for memory, filesystem, or external stores. You cannot pin output that includes binary. Redaction removes binary from the execution record.

In this section