Skip to main content

Build your first workflow

A workflow starts as a few sentences of plain English that say what should happen and which systems to use. Unstract Flow turns those sentences into a fixed workflow when you prepare it, and then you run it.

Describe the workflow​

  1. Open Projects and select New project.

  2. Enter the project's Name.

  3. Enter a Workflow name. Leave Start with a workflow ticked and Start from on Blank.

  4. Select Create project. Flow opens the new workflow in the editor, on Flow Chat.

  5. In Flow Chat, describe the process and name each system with an @mention of its connector. For example:

    Read new mail in @email_gmail that has an invoice attached. Extract the vendor, invoice number and total from each invoice with @unstract. If a total is over $10,000, send the invoice to @hitl for Priya to approve.

  6. Answer the questions Flow Chat asks first, if any: up to three, one at a time.

  7. On the proposal card, select Replace main.md.

The spec goes into main.md, which opens beside the chat. The project's name stands before the workflow's name; select it to open the project. Projects explains what a project holds, and Draft with Flow Chat covers the conversation.

To add a workflow to a project you already have, select New workflow instead and pick the project under Project.

The editor: Flow Chat on the left, and Tools and configuration open on its Tools tab

The picture shows a workflow that checks certificates of insurance, with every connector set up and Tools and configuration open on its Tools tab. Flow Chat in the editor says what each icon on the rail at the right edge opens.

When you edit the spec in main.md, write each mention with the connector's exact name, such as @email_gmail. A near match such as @gmail shows a chip that asks whether you meant @email_gmail, and Flow adds the connector once you use the exact name. In a workflow that opens read only for you, Flow adds no connector; Members and roles says who can change a workflow.

Connect each connector​

Every connector you mention appears in the Tools tab of Tools and configuration, one row per instance. A row shows Setup until the instance is connected, and Ready once a credential is saved on it (for a sign-in credential, once the sign-in has finished); Ready doesn't mean the connection works. A connector that needs no credential, such as @hitl, shows Ready as soon as it's added. While a row shows Setup, a number on the Tools and configuration icon counts those rows, and the first time you select the icon it opens this tab.

  1. Select Configure on a row that shows Setup.
  2. Choose a credential, or add one.
  3. Fill in the connector's settings.
  4. Select Test Connection where the dialog offers it, then Save Settings. A connector with a credential and no settings shows Save Configuration instead.

Prepare the workflow​

Select Prepare. Flow saves your changes and works through these stages:

  1. Sanity check. Flow reads the spec for problems. When it finds some, the Workflow Review dialog lists them. Select Go back and fix to edit the spec, or Proceed anyway.
  2. Architect. A new workflow's Architect setting, in the Settings tab of Tools and configuration, is Auto · defaults, no dialog. Flow shows "Architect: clarifying the workflow before compiling…", writes what the spec left out into it as a new version, and says "Architect applied 2 clarification(s)", or "Architect: nothing to clarify" when the spec already states it all, as a spec Flow Chat wrote usually does. To answer questions yourself first, choose Ask · questions first and select Save; Architect modes describes the dialog.
  3. Generating workflow, Validating workflow, Building workflow and Finalising. The Prepare tab shows each stage as it runs.

Once Flow starts generating the workflow, Cancel in the Prepare tab stops it. Run is unavailable while a prepare runs. If you prepared the workflow before, Run uses that version again once the prepare stops or fails.

When preparing finishes, the Prepare tab confirms it, and the workflow's status on its project's Workflows tab becomes Ready.

Run it​

Select Run. The run uses the version you prepared. Run refuses to start while any row in the Tools tab shows Setup, while a review step's queue is paused, or while the queue chosen in a review step's settings no longer exists.

When you edit the spec after preparing, Run keeps running the last prepared version until you prepare again. Its tooltip says "Runs the last compiled version. The spec has changed since it was prepared." Changes Flow saves on its own keep the workflow Ready on its project's Workflows tab. After you reload the editor, the tooltip shows only once you edit the spec again.

A deployment runs the workflow on a schedule or from a webhook. It needs a tagged version: select Tag next to the workflow's name to tag the one you prepared. The deployment keeps that version's steps. Its runs use the connector instances in the Tools tab as you last saved them, and while the deployment is active, the Tools tab says so.