Skip to content

Log to File

Type: log-to-file  ·  Package: Core Activities v1.0.0

Appends a log line to a text file of your choosing, formatted as [timestamp] [LEVEL] message. Useful when you need to keep a record in your own file (an audit trail, a log another system watches, a cumulative report) in addition to the execution log the platform captures.

It is different from Log: log writes to the execution log (the one you see in the debug panel and in Zoan Cloud logs); log-to-file writes to a file on disk. Use whichever fits where you want the message to land; you can use both at once.

When execution reaches the activity, it evaluates the message, formats it as a line ([2026-06-16 10:30:00] [INFO] message) and appends it to the file given in path, creating the file (and its folders) if they don’t exist. Each call adds a new line. It doesn’t stop the flow: it records and continues.

ParameterEditorDescription
pathexpressionLog file path (created if it doesn’t exist).
messageexpressionThe text to record. Can be a literal or a = expression.
ParameterEditorDescription
levellistMessage importance. Options: info (default) · warning · error · debug.
timestampyes/noPrefix each line with the date and time (default: yes).

Keep your own log of the invoicing process:

Log to File path = = "C:/logs/invoicing.log" level = info
message = = "Process start — " + str(rowCount(invoices)) + " invoices"
For Each item = invoice in = = invoices
└─ body:
Log to File path = = "C:/logs/invoicing.log" level = error
message = = "Invoice " + str(invoice["Number"]) + " has no email"

Produces a file like:

[2026-06-16 09:00:01] [INFO] Process start — 15 invoices
[2026-06-16 09:00:04] [ERROR] Invoice INV-021 has no email
  • Log — write to the execution log (not to a file).
  • Append to File — append raw text to a file (without log formatting).
  • Try / Catch — log the error caught in the catch to a file.