# Workflows Guide

## What a Workflow Is

A workflow is a saved, named sequence of steps that {{productName}} runs for you on demand. Each step calls one tool, and steps can pass their results to later steps. Use a workflow when you have a recurring process with two or more steps that you would otherwise ask for by hand every time. A single one-off action does not need a workflow.

Examples of good workflows:

- "When a new lead comes in, create a contact, log it, and send me a notification."
- "Every time I book a viewing, add the calendar event and message the client the details."

## Creating a Workflow

Describe the process to {{productName}} naturally:

- "Set up a workflow: when I get a new lead, create the contact and send a Telegram notification."
- "Make a follow-up workflow that adds a calendar reminder and drafts an email."

{{productName}} will confirm the name, the steps, and how data flows between them before saving. If a step needs a tool from a plugin you have not installed yet, the workflow is saved as a draft and activates automatically once that plugin is in place.

## Declared Inputs

Most workflows need a few values that are specific to each run, for example a customer name or a chosen option. A workflow can declare these up front as its inputs. Declaring them means {{productName}} asks you the same questions every time it runs the workflow, so nothing is forgotten and nothing is guessed.

Each declared input has a question to ask you, a type, whether it is required, and an optional default. When a value has a default, {{productName}} offers it and you can accept or change it.

You do not manage inputs by hand. When you describe a workflow that clearly needs a per-run value, {{productName}} proposes the input and confirms it with you. At run time it reads the list and asks you each question before starting.

## Running a Workflow

Ask {{productName}} to run it:

- "Run the new-lead workflow."
- "Start the viewing follow-up for the Cardinal Roofing booking."

Before it starts, {{productName}} gathers every required input by asking you. If you leave a required value out, the workflow does not start and no steps run. {{productName}} tells you which value is missing and asks for it, then runs the workflow with the complete set. This is deliberate: the workflow refuses to run half-finished rather than failing partway through.

## Seeing What Ran

Ask for the history:

- "Show me recent workflow runs."
- "Did the new-lead workflow run today?"

You get each run's status, timing, and how many steps completed, were skipped, or failed. If a step failed, {{productName}} can show you which one and why.

## Managing Workflows

Tell {{productName}} naturally:

- "List my workflows."
- "Show me the follow-up workflow."
- "Pause the new-lead workflow." or "Turn the new-lead workflow back on."
- "Change the follow-up workflow so it also messages me."
- "Delete the old onboarding workflow."

Pausing keeps a workflow but stops it running. Editing replaces the steps or the inputs with the new version you describe. Deleting removes the workflow and its run history, so {{productName}} confirms with you first.

## Scheduling a Workflow

A workflow can run on a schedule instead of on demand. Tell {{productName}} when you want it to run, for example "run the daily summary workflow every morning at eight," and it sets up the schedule. Scheduled runs happen with no one present, so a workflow that needs you to supply inputs is best run on demand rather than scheduled.
