# Flows

The fixed sales-ops recipes PYLO can run for you, how to try them in shadow before going live, and how to set their notifications.

A flow is a fixed recipe that runs when something happens, such as a form coming in, a call being booked or an outcome being filed. You choose whether each flow is off, running in shadow, or live, and you set what it writes to Close and which notifications it sends.

## Who can open it

Owners and admins. A live flow writes to Close and sends notifications, so nobody else can change flows.

## The flows

| Flow | Runs on |
| --- | --- |
| Lead intake | A submission to this workspace's website form URL |
| Booking | A new Calendly booking |
| Reschedule | A Calendly booking moved to another time |
| Cancellation | A Calendly booking cancelled |
| Outcome | A post-call form or a DM close form |
| Payment | A payment succeeding or failing at the processor |
| Hand-off | An outcome of closed won |

## Off, shadow and live

Every flow starts off. Choosing a mode saves it straight away.

- **Off** does nothing. Everything works exactly as it does today.
- **Shadow** records on each lead's page what the flow would have done, and writes nothing anywhere.
- **Live** writes to Close and sends the notifications itself. PYLO's own step for the same thing stands down.

Try a flow in shadow first, and set it live when the shadow runs look right.

## Close settings

Lead intake, Booking, Cancellation and Outcome have a `CRM step`. Set it to `Close` to show the fields for that flow, such as `Pipeline`, `Lead status`, `Opportunity status`, `Won status`, `Lost status`, the setter and closer fields, and the fields UTM values are written to. Type each name exactly as Close spells it, because the names are matched each time the flow runs.

## Notifications

Each flow except Hand-off has a notification. Payment has two: one for when a payment succeeds and one for when it fails.

1. Choose `Discord` or `Slack`, or `No notification`.
2. Under `Sent where this event goes`, choose the event whose channel it should post to, such as booked calls or closed.
3. Choose who to `Mention`: nobody, everyone or here.
4. Under `Carries`, tick what the message includes: name, email, phone, Close link, PYLO link, source and country eligibility.
5. Choose `Save settings`.

Channels come from your Slack and Discord set-up on [Integrations](/docs/settings/integrations).

## Hand-off

Hand-off posts to your own webhook address, for example in n8n, Make or Zapier, when a deal is closed won. Enter an https address, then create the signing secret. Each post is signed in the `X-Pylo-Signature` header. The secret is shown once, and creating another replaces it.

## What changes elsewhere

In shadow, you can see each flow's planned steps on the lead's page. In live, the flow updates Close and posts to your channels in place of PYLO's own step.
