> ## Documentation Index
> Fetch the complete documentation index at: https://botmesh.afaya.com.co/llms.txt
> Use this file to discover all available pages before exploring further.

# FlowGuard<S>

> Type alias exported by @botmesh/core.

```ts theme={null}
type FlowGuard<S> = (ctx, c) => unknown | Promise<unknown>;
```

Defined in: [flows/FlowBuilder.ts:90](https://github.com/andresayac/botmesh/blob/main/packages/core/src/flows/FlowBuilder.ts#L90)

`.guard()` predicate: a falsy result stops the flow.

## Type Parameters

| Type Parameter | Default type |
| - | - |
|  `S` *extends* `object` | [`EmptyFlowState`](https://botmesh.afaya.com.co/api/core/type-aliases/EmptyFlowState) |

## Parameters

| Parameter | Type |
| - | - |
| `ctx` | [`RuntimeMessage`](https://botmesh.afaya.com.co/api/core/interfaces/RuntimeMessage) |
| `c` | [`FlowControls`](https://botmesh.afaya.com.co/api/core/type-aliases/FlowControls)\<`S`> |

## Returns

`unknown` | `Promise`\<`unknown`>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.