# Function Flow

A function flow is a fantastic way of preventing you to create repetitive flows over and over again. Think of when you need ask for emails or phone numbers.

With a function flow you will be able to send the user to that one flow, then once completed the user can continue exactly from the point they left off in the previous flow.

### Create Function Flow <a href="#create-function-flow" id="create-function-flow"></a>

To create a function flow go to **Flows** from your left-hand menu, then press the button **+ New Sub Flow**.

<figure><img src="https://2144409983-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHbDmB8MlZRo4hzrDiO0X%2Fuploads%2FAfZq5eYfUpvBfmyQSdo0%2FCapture.png?alt=media&#x26;token=67ef5d1b-3cf2-4a18-8854-0f00811754e4" alt=""><figcaption></figcaption></figure>

Select the **Function flow** type and name your flow. Once done press the button **Create** and you will be taken to the flow builder.

### Function Flow Example <a href="#function-flow-example" id="function-flow-example"></a>

Once inside the flow builder and wanting to insert a new block you will see that you have all the blocks at your disposal just like in a regular flow, and one extra called **Output**.

<figure><img src="https://2144409983-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHbDmB8MlZRo4hzrDiO0X%2Fuploads%2FFFY4LSMjjesi1f0aZPkR%2Fworkflow6.6f06e699.png?alt=media&#x26;token=bca58919-3148-411b-8d69-0af57a04f4c3" alt=""><figcaption></figcaption></figure>

This output is what makes this function flow so unique as it gives you the ability to send the user back to the previous flow (if you like) exactly where he or she left off.

Let’s create an example where we ask the user for an email and add an output module to it;

<figure><img src="https://2144409983-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHbDmB8MlZRo4hzrDiO0X%2Fuploads%2FCO7qyHewtMhvSGoQLWtt%2Fworkflow7.4ab17013.png?alt=media&#x26;token=7e615840-2b75-408f-9ca1-7a02ae1ac499" alt=""><figcaption></figcaption></figure>

As you can see a simple flow but with the benefit this is the only function of the flow, asking for an email.

### Call Function Flow <a href="#call-function-flow" id="call-function-flow"></a>

After this flow is finished you can return the user to the previous flow to continue the conversation there if you like.

Let us show you how that could look like;

<figure><img src="https://2144409983-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHbDmB8MlZRo4hzrDiO0X%2Fuploads%2F2T6zi2vuOywciu6vptz7%2Fworkflow8.e04c5761.png?alt=media&#x26;token=d5c431b2-5dc4-495e-adc3-8508d568a972" alt=""><figcaption></figcaption></figure>

There are many use cases for function flows so you can get as creative as you like.

### Multiple Outputs <a href="#multiple-outputs" id="multiple-outputs"></a>

Multiple **Output Steps** are supported in your Function Flow.

When you call a Function Flow with multiple outputs, the titles of those outputs will show in the Goto Step and you can handle it accordingly.

<figure><img src="https://2144409983-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FHbDmB8MlZRo4hzrDiO0X%2Fuploads%2FWkwPxjcUfwIbUD7hbrcj%2Fimage.png?alt=media&#x26;token=4e6b36c0-3031-411b-abeb-8b3a4454ba5d" alt=""><figcaption></figcaption></figure>
