> ## Documentation Index
> Fetch the complete documentation index at: https://botpress-charmenta-pr-696.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Triggers

Triggers are a special kind of [Node](/studio/concepts/nodes) that only **execute when a certain event occurs**. You can recognize Triggers by their distinctive purple colour:

<Frame>
  <img src="https://mintcdn.com/botpress-charmenta-pr-696/JVZiEMTS2boPcj9F/studio/concepts/assets/trigger.png?fit=max&auto=format&n=JVZiEMTS2boPcj9F&q=85&s=30d028fa07e10dd141898d218f6772a7" alt="Trigger" width="1300" height="326" data-path="studio/concepts/assets/trigger.png" />
</Frame>

Triggers are useful if you want your bot to:

* [Send a welcome message](#conversation-started)
* [Do something at a specific date/time](#fixed-schedule)
* [Respond to changes on your website](#custom-trigger)

<Warning>
  ### Limitations

  * Triggers won't work in the Studio's emulator, even when the event they're expecting occurs. Instead, you can [test them](#test-a-trigger) before publishing.
  * Triggers won't work while your bot is waiting for user input from a [Capture Information](/studio/concepts/cards/capture-information) Card.
</Warning>

## Triggers vs. Nodes

Triggers are different from regular Nodes in a few ways:

* You **can't transition** from a regular Node to a Trigger. Any Triggers in your Workflow will only execute when the event they listen for occurs.
* Unlike other Nodes, **you can't add or remove [Cards](/studio/concepts/cards)** from a Trigger. Each Trigger is built around a single Card that determines when it executes.

## Add a Trigger

To add a Trigger, just right-click anywhere in a Workflow:

<Frame>
  <img src="https://mintcdn.com/botpress-charmenta-pr-696/yPylWiCoU36xiUSj/studio/concepts/assets/add-trigger.png?fit=max&auto=format&n=yPylWiCoU36xiUSj&q=85&s=2cf31110c4f255f85ae2205e840b6e9e" alt="Add a Trigger" width="1408" height="808" data-path="studio/concepts/assets/add-trigger.png" />
</Frame>

## Test a Trigger

Triggers won't work in the Studio's emulator, even when the event they're expecting occurs. Instead, you can use a previous event to test your Trigger.

For example, to test the [Conversation Started](#conversation-started) Trigger:

<Steps>
  <Step title="Add the Trigger to your Workflow">
    Right-click anywhere in your Workflow. Select **Trigger**, then **Conversation Started**:

    <Frame>
      <img src="https://mintcdn.com/botpress-charmenta-pr-696/yPylWiCoU36xiUSj/studio/concepts/assets/conversation-started.png?fit=max&auto=format&n=yPylWiCoU36xiUSj&q=85&s=4a276324d64c1a4b34a77b26830a2fcb" alt="Conversation Started" width="956" height="686" data-path="studio/concepts/assets/conversation-started.png" />
    </Frame>
  </Step>

  <Step title="Configure a test">
    Select **Test** in the bottom-left corner of the Trigger:

    <Frame>
      <img src="https://mintcdn.com/botpress-charmenta-pr-696/JVZiEMTS2boPcj9F/studio/concepts/assets/test-trigger.png?fit=max&auto=format&n=JVZiEMTS2boPcj9F&q=85&s=67a14944d40c5c6c64d0155ec81be73a" alt="Test Trigger" width="1454" height="716" data-path="studio/concepts/assets/test-trigger.png" />
    </Frame>

    Then, select **Show last received events**. This will display a list of past events that would set off your Trigger:

    <Frame>
      <img src="https://mintcdn.com/botpress-charmenta-pr-696/JVZiEMTS2boPcj9F/studio/concepts/assets/test-events.png?fit=max&auto=format&n=JVZiEMTS2boPcj9F&q=85&s=bdd56ace927d09170592de67f4b1a327" alt="Test events" width="1454" height="564" data-path="studio/concepts/assets/test-events.png" />
    </Frame>

    For the **Conversation Started** Trigger, each of these is a `conversationStarted` event, which fires every time a user starts a new conversation with your bot.

    You can use any one of these events as a dummy event to test your Trigger. Just pick one and select **Add as Test**. Then, select **Save**.

    <Note>
      If there are no events available to choose, make sure your bot is published and that the event your Trigger is listening for has occurred at least once before.
    </Note>
  </Step>

  <Step title="Test the Trigger">
    Now, you should see the name of the event in the Trigger:

    <Frame>
      <img src="https://mintcdn.com/botpress-charmenta-pr-696/yPylWiCoU36xiUSj/studio/concepts/assets/fire-trigger.png?fit=max&auto=format&n=yPylWiCoU36xiUSj&q=85&s=7c581e89c950afae1c0a1bd7fc7b3852" alt="Fire Trigger" width="1454" height="458" data-path="studio/concepts/assets/fire-trigger.png" />
    </Frame>

    Just press the play icon to fire the Trigger. Any logic you have connected to the Trigger will execute in the emulator:

    <Frame>
      <img src="https://mintcdn.com/botpress-charmenta-pr-696/JVZiEMTS2boPcj9F/studio/concepts/assets/trigger-emulator.png?fit=max&auto=format&n=JVZiEMTS2boPcj9F&q=85&s=dece4c556d7b066a295c52e425b13408" alt="Trigger fires in emulator" width="1288" height="252" data-path="studio/concepts/assets/trigger-emulator.png" />
    </Frame>
  </Step>
</Steps>

## Webchat Triggers

Studio comes with some built-in Triggers that let your bot react to certain events in Webchat:

### Conversation Started

<Tip>
  For a step-by-step guide to the **Conversation Started** Trigger, check out the [Webchat documentation](/webchat/interact/start-trigger).
</Tip>

The **Conversation Started** Trigger only executes when a user starts a new conversation in Webchat. You can use it to make your bot do something as soon as a user starts a new conversation.

For example, sending a welcome message:

<Frame>
  <img src="https://mintcdn.com/botpress-charmenta-pr-696/JVZiEMTS2boPcj9F/studio/concepts/assets/welcome-message.png?fit=max&auto=format&n=JVZiEMTS2boPcj9F&q=85&s=1a6dde4b1315e20153b08e318524211f" alt="Welcome message" width="1408" height="422" data-path="studio/concepts/assets/welcome-message.png" />
</Frame>

### Custom Trigger

<Tip>
  For a step-by-step guide to using **Custom Triggers**, check out the [Webchat documentation](/webchat/interact/send-custom-events/to-webchat).
</Tip>

You can use **Custom Triggers** to make Webchat react to custom events from your website. This is useful if you want to make your bot more responsive to the rest of your user experience.

For example, if you want your bot to respond when a user clicks a button:

<Frame>
  <img src="https://mintcdn.com/botpress-charmenta-pr-696/yPylWiCoU36xiUSj/studio/concepts/assets/custom-trigger-buttons.png?fit=max&auto=format&n=yPylWiCoU36xiUSj&q=85&s=9d63719f8741274e508336330097048c" alt="Custom Trigger reacting to buttons" width="1408" height="410" data-path="studio/concepts/assets/custom-trigger-buttons.png" />
</Frame>

## Fixed Schedule

<Tip>
  Check out our step-by-step guide on [using the Fixed Schedule Trigger](/studio/concepts/cards/fixed-schedule).
</Tip>

You can use the **Fixed Schedule** Trigger to execute some part of your Workflow at a specific time. This is useful if you want to send reminders, notifications, or other time-sensitive messages to users.

## Integrations

<Tip>
  Check out the [integrations section](/integrations/) for information about integration-specific Triggers.
</Tip>

Some integrations include their own Triggers. When you install an integration that has Triggers, they'll become available in the Triggers menu.

For example, the [Zendesk integration](/integrations/integration-guides/zendesk) comes with two Triggers—**Article Published** and **Article Unpublished**:

<Frame>
  <img src="https://mintcdn.com/botpress-charmenta-pr-696/JVZiEMTS2boPcj9F/studio/concepts/assets/zendesk-triggers.png?fit=max&auto=format&n=JVZiEMTS2boPcj9F&q=85&s=61b06a470892f8322d4717ab4a9afa18" alt="Zendesk Triggers" width="1444" height="760" data-path="studio/concepts/assets/zendesk-triggers.png" />
</Frame>
