# Creating a Workflow

## Prerequisites

To begin creating workflows, you must first enable the [GitHub](/reference/integrations/github.md) integration.

## How to create a workflow

To create a new workflow, first navigate to the *Workflows* panel and click the *Create Workflow* button.

<figure><img src="/files/PcwAG37w33kqv56og61A" alt="On the Workflows panel, the Create Workflow button is found on the top right corner."><figcaption></figcaption></figure>

After clicking *Create Workflow*, you will be prompted to input some information about your workflow. This information includes a name, a description, and optionally an email address and a slack channel. These optional inputs are for notifications. [Learn more about our Slack integration](/reference/integrations/slack.md).

After clicking *Save*, you will be prompted with the Workflow editor. If you change your mind about the inputs you configured before, you can always click *Configure* at the top to redefine those values.

<figure><img src="/files/R1j0Kqtj3MYWJrHFpTt0" alt="After naming your workflow, you will be brought to the visual workflow editor."><figcaption></figcaption></figure>

In the space above, you will find a graph representation of your workflow wherein each node (the rounded rectangle) represents a step in the workflow's execution. The workflow execution moves from left to right until completion. For more information about the anatomy of a workflow, consult the [Workflow Components](/reference/workflow-components.md) reference.

### Configuring steps

Clicking any of the steps will cause its configurations to appear below. *Details* shows the most basic facts about a step, the most impactful of which being the *type*. The type of step indicates what sort of processing will done during the execution of that step. For a complete breakdown of what each type of step does, consult the [Steps](/reference/workflow-components/steps.md) reference.

<figure><img src="/files/a8B11HJOWaYx6FRkCkHa" alt="Use the dropdown to select a task type for the step."><figcaption></figcaption></figure>

Upon selecting a type, you will see another configuration box for that particular task type. See the image below depicting configurations for a *deploy* step.

<figure><img src="/files/6C3rq7d6fPzI0Mf3a6jz" alt="Configurations for a Deploy step includes fleet selection, release selection, as well as which type and machines to deploy to."><figcaption></figcaption></figure>

In addition to *type*, you can also set a *name* and *timeout* for each step. The timeout represents a maximum duration for the step's execution. On every step except the first step, you can also set the *depends on* property which specifies where lines (edges) should be drawn in the graph. A line between steps *A* and *B* indicate that step *B* will follow step *A*.

### Creating new Steps

There are three ways to create new steps in a workflow. Firstly, you can create a step off an existing step. Clicking the **+** sign on a step *A* will create a new step that depends on *A*.

<figure><img src="/files/JDT6HYP1FAJiJ9rjZeFi" alt="Hovering over a step will show a plus button to the right of the box."><figcaption></figcaption></figure>

You can also create steps between existing steps. Hovering your cursor over a line in the graph will cause two buttons to appear which both add steps but in different ways.

<figure><img src="/files/KiS4sYgECjl0JeoP7whl" alt="Hovering over the line connecting steps show the fork button, and the plus button."><figcaption></figcaption></figure>

The button on the left sometimes called *fork* will create a new step *C* that depends on step *A* and leave step *B* unchanged as shown below.

<figure><img src="/files/cAyrDl1DH83JY9HpOjLK" alt="Clicking on the fork creates a new path branch."><figcaption></figcaption></figure>

The button on the right (the **+** sign) will create a new step *C* that depends on *A, and update B* to depend upon *C* as shown below.

<figure><img src="/files/3MySFEnBZJhOZG9R7JXf" alt="Clicking on the plus button inserts a step in between the two original steps."><figcaption></figcaption></figure>

### Finalizing configurations

When you're satisfied with your workflow, you can click the *Create Workflow* button to save your workflow. You'll be taken to the details page. You'll learn more about this page in the next chapter.

<figure><img src="/files/zzjgty7rUivDN7CkaGno" alt="The Details page shows an overview of the workflow."><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.chassy.io/user-guides/workflow-user-guide/creating-a-workflow.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
