> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dogebot.net/llms.txt
> Use this file to discover all available pages before exploring further.

# Checks and paths

> Ask a question and go one way or the other.

Sometimes your bot needs to **decide** what to do. That is what **Checks** are for.

A Check block **asks a question**. Then the bot goes one way or the other.

## Checks have two ways out

A Check block has two ways out:

* one for when the answer is **yes**
* one for when the answer is **no** (else)

Join different blocks to each one.

> **Example: buy VIP**
>
> **Compare**: are the person's coins 500 or more?
>
> * **Yes** → Reply: `You bought VIP!`
> * **No** → Reply: `You need 500 coins.`

## What Checks can ask

Open the **Checks** tab in the block list to find them.

| Check | The question it asks | Example |
| - | - | - |
| **Compare** | How do two values compare? | Does the member have 500 coins or more? (using `{DBVAR_coins}`) |
| **Random chance** | Should this happen, by luck? | A 10% chance to win a prize. |
| Permissions check | What server permissions does this person have? | Staff only. |
| Role check | Which roles does this person have? | Only people with the Moderator role. |
| Channel check | Which channel was the command used in? | Only in `#bot-commands`. |
| User check | Who used the command? | Only you. |
| Premium check | Is the bot on Premium? | Show a Premium-only extra. |

See every Check and its settings in [Check blocks](/block-library/check-blocks).

## Worked and failed paths

Checks are not the only blocks that split. Many action blocks can show two extra ways out:

* a **green** path: what to do if it **worked**
* a **red** path: what to do if it **failed**

Each path has its own **+** button. The new block lands on that path.

> **Example: a role that can't be given**
>
> **Give roles** → red path → Reply: `I couldn't give you the role. Please tell a moderator.`
>
> Only that one block is handled. The rest of your command carries on normally.

More about failures in [Saving and fixing problems](/building-with-blocks/saving-and-fixing-problems).

## Buttons and menus make paths too

Every button and every menu option gets its **own path** on the board. See [Messages, buttons and menus](/building-with-blocks/messages-buttons-and-menus).


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