Skip to content

Routine Settings

It's possible to set custom settings on each routine from the routine > settings menu.

routine settings

The routine settings have three sections.

1. General

It contains the following settings:

  • On routine error: Select what to do when an error occurs on the routine.
  • Routine execution: Whether to run the routine in the popup dashboard or in the background.
  • Routine notification: Toggle whether to show a notification when the routine execution end.
  • Debug mode: Execute the routine using the Chrome DevTools Protocol
  • Autocomplete: Enable autocomplete in the input of a block
  • Reuse the last routine state: Use the state data (table, variables, and global data) from the last execution.
  • Save routine log: Save the logs of the routine.
  • Show executed block on the web page: Show the block that routine currently executes on the webpage. This setting only shows blocks in the "Web interaction" category, like the Click Element and the Forms block.
  • Routine public Id: The public id of the routine, you can use this public id when executing routine using Javascript CustomEvent.

Routine Execution

Some features that will not available and advantages when selecting "popup" or "background" when running the routine:

Name/FeaturesPopupBackground
Max running timeNo limit~5 Minutes
Required popup window
JS Background Execution
JavaScript Expression
Clipboard Block

2. Table

It contains the following settings:

  • Insert into the default column: Insert data to the default column if there's no column selected in the block or when the column doesn't exist.
  • Default column name: The name of the default column

3. Blocks

It contains the following settings:

  • Block delay: Add delay before executing each of the blocks
  • Tab load timeout: Maximum time to load tab in milliseconds

4. Routine Events

Routine events allow you to perform actions when an event occurs within the routine.

Available Events

  • Finish (success): Fires when the routine finishes executing with success status.
  • Finish (failed): Fires when the routine finishes executing with failed.

Available Actions

  • HTTP Request: Send an HTTP request
  • Execute JS Code: Execute JavaScript code

Available Data

You can access data like the routine logs, status, error message, etc. using the workflow keyword inside an expression or bwswiftRefData function within the action.

Data Type

ts
interface Workflow {
  status: "success" | "error";
  logs:
    | {
        type: "error" | "success";
        description: string;
        name: string;
        blockId: string;
        timestamp: number;
        activeTabUrl: string;
        duration: number;
        id: number;
      }[]
    | null;
  errorMessage: string | null;
}
interface Workflow {
  status: "success" | "error";
  logs:
    | {
        type: "error" | "success";
        description: string;
        name: string;
        blockId: string;
        timestamp: number;
        activeTabUrl: string;
        duration: number;
        id: number;
      }[]
    | null;
  errorMessage: string | null;
}

Examples

js
// Expression
{{ routine.logs }}

// bwswiftRefData
console.log(bwswiftRefData('routine', 'logs'))
console.log(bwswiftRefData('routine', 'status'))
// Expression
{{ routine.logs }}

// bwswiftRefData
console.log(bwswiftRefData('routine', 'logs'))
console.log(bwswiftRefData('routine', 'status'))

Routine data