Block reference / Data

Get log data

Read the log of a workflow that is running, as a list of entries.

In both appsWarpX BrowserWarpX Phone

Get log data reads the log of a run that is still going, usually the current workflow's own, and stores it in a variable or a table cell. Reach for it when you want to send a record of what ran, for example to your own server with HTTP request.

The Get log data block's settings, filled in as in the example below.

Settings

Select workflow

The workflow whose log you want. Pick the workflow this block is in to read the current run.

ExampleDaily order sync
Assign to variablewhen a workflow is selected

Store the log in a variable.

ExampleChecked
Variable namewhen Assign to variable is ticked

The variable that receives the log.

ExamplerunLog
Insert to tablewhen a workflow is selected

Put the whole log into one cell of the table. It starts ticked on a new block.

ExampleUnchecked
Select columnwhen Insert to table is ticked

The column that receives the log. With no column chosen, it goes to the table's default column.

Examplelog

Every block also has the shared block settings — a description, Disable block and what to do on an error. Fields that take text accept data from earlier blocks.

What it hands on

A list with one entry per logged block: timestamp, duration, status (such as SUCCESS or ERROR), name, description, message and data. It goes to the variable or column you chose, and on as {{prevBlockData}}.

Example: Send the run's log to your server at the end

  1. Start
  2. Open URL
  3. Get text
  4. Get log data
  5. HTTP request
Where Get log data sits in the example workflow.
  1. Open the workflow Daily order sync and add Get log data as the last step before sending.
  2. Under Select workflow, choose Daily order sync.
  3. Tick Assign to variable and type runLog. Untick Insert to table.
  4. Add HTTP request after it and use {{variables.runLog}} in the body. A list is written out as JSON.

Good to know

  • Only a run that is still going can be read. Once a workflow finishes, its entry is gone, so choosing another workflow that is not running at that moment gives an empty list and writes nothing.
  • The block's own line is not in the log yet: it is added after the block runs.
  • With Save workflow log turned off in the workflow's settings, the log holds only errors.
  • Selecting no workflow stops the block with No workflow is selected.

See also

  • HTTP request — Sends an HTTP request to a URL and can store the response.
  • Execute workflow — Run another automation from this one and wait for it to finish.
  • Insert data — Set variables and add values to the workflow's table, several at once.