---
id: document_item.triggers-masterslave-tab
page_type: documentation_article
title: "“Triggers Master/Slave” Tab"
description: "How Moonbot Master strategies assign trigger keys and Slave strategies respond to them, including trigger events for detection, Buy execution, profit and loss."
section: documentation
category: "Strategies / General Parameters for All Strategies"
url: https://moonbot.pro/documentation/general-parameters-for-all-strategies/triggers-masterslave-tab?format=md
locale: en
alternate_ru: https://moonbot.pro/ru/documentation/general-parameters-for-all-strategies/triggers-masterslave-tab?format=md
alternate_zh: https://moonbot.pro/zh/documentation/general-parameters-for-all-strategies/triggers-masterslave-tab?format=md
parent: https://moonbot.pro/documentation/general-parameters-for-all-strategies?format=md
previous: https://moonbot.pro/documentation/general-parameters-for-all-strategies/dynamic-whiteblack-list-tab?format=md
next: https://moonbot.pro/documentation/general-parameters-for-all-strategies/session-tab?format=md
status: published
updated_at: 2026-11-17T20:26:13+03:00
---

# “Triggers Master/Slave” Tab

⚠️ **Attention**! Triggers work only when the [Autotrading](https://moonbot.pro/en/moonbot-pro/modules/autotrading?format=md) Extension Pack is activated or when the global **Emulator mode** is enabled via **Menu → Emulation mode**.

### Parameters for Master strategies

- **TriggerKey**: a field for specifying key number **N** (1–200), which is assigned when the strategy's detect-trigger activates (even without AutoBuy). If set to 0, it does not apply. \
  This trigger assigns a key that can subsequently activate Slave strategies. The trigger fires and assigns the key either on the specific market where the detect occurred, or on all markets, depending on **TriggerAllMarkets**.\
  Example: \
  A Master strategy has TriggerKey = 5. When this strategy activates (activation conditions for each strategy type are described later in "Trigger operation specifics"), timestamp is written into key 5. After that, all Slave strategies where TriggerByKey = 5 become active and will run during the number of seconds specified in their **TriggerSeconds** parameter, or for the time specified inside **TriggerByKey** in the format **N=Time**, where N is key number, and **Time** is duration in seconds (see **TriggerByKey** description and examples below).
- **TriggerKeyBuy**: a field for specifying key number **N** (1–200) that is assigned when a Buy order execution trigger activates. If set to 0, it does not apply. In the MoonShot strategy, **TriggerKey** is removed — only **TriggerKeyBuy** is available;
- **TriggerKeyProfit**: a field for specifying key number **N** (1–200) to assign when a trigger activates after closing a trade in profit. If 0, it does not apply;
- **TriggerKeyLoss**: a field for specifying key number **N** (1–200) to assign when a trigger activates after closing a trade in loss. If 0, it does not apply;
- **ActiveTrigger**: **YES/NO** checkbox. \
  If **YES**, the trigger signal is kept active (on **TriggerKeyBuy** for MoonShot, or on **TriggerKey** for other strategies) as long as a Buy order remains placed on the coin;
- **ClearTriggersBelow**: a field for specifying key number **N** (1–200). When trigger N activates, all trigger keys with numbers lower than N are cleared;
- **ClearTriggersAbove**: a field for specifying key number **N** (1–200). When trigger N activates, all trigger keys with numbers higher than N are cleared;
- **ClearTriggerKeys**: a field for listing trigger keys (separated by spaces) that will be cleared when the strategy receives any trigger signal from parameters **TriggerKey**, **TriggerKeyBuy**, **TriggerKeyProfit**, **TriggerKeyLoss** of this same strategy;
- **TriggerAllMarkets**: **YES/NO** checkbox. \
  If **YES**, the trigger acts on all markets simultaneously. If **NO**, it acts only on the market where the trigger fired.

### Parameters for Slave strategies

- **TriggerByKey**: a field for specifying key **N** (1–200) or a list of keys (N1 N2 N3 …) separated by spaces, received from a Master strategy, which will activate the current Slave strategy. \
  If the field is empty, it does not apply. You can also specify keys with individual activation times using the format N=Time.\
  Example: \
  if the **TriggerByKey** field contains: 1 2 3 4=100 5 6 7=300 this means the Slave strategy can activate from keys 1 2 3 4 5 6 7, but each will provide different activation times:
  - For keys 1 2 3 5 6, activation time is taken from the **TriggerSeconds** parameter of the Slave strategy
  - For key 4=100, the Slave strategy will run for 100 seconds
  - For key 7=300, the Slave strategy will run for 300 seconds.
- **TriggerByAllKeys**: **YES/NO** checkbox. \
  If **YES**, the Slave strategy activates only if all keys listed in **TriggerByKey** are currently active.
- **TriggerSeconds**: a field for specifying the number of seconds the Slave strategy will run after activation by keys listed in **TriggerByKey** without the equals sign. A positive integer between 0 and 864000 (864k). If 0, it does not apply.\
  Example:\
  If a Master strategy is triggered and activates key 1 - for example, via its TriggerKey=1 parameter - then any Slave strategy that contains key 1 in its TriggerByKey=1 parameter will run for the duration specified in the Slave strategy’s TriggerSeconds parameter. For example, if TriggerSeconds=60, the Slave strategy will run for 60 seconds, after which it will deactivate and remain inactive, awaiting the next trigger for key 1.
- **TriggerKeysBL**: a field for specifying key N (1–200) or a list of keys (N1 N2 N3 …) received from a Master strategy, which will stop the current Slave strategy by adding the coin to the blacklist (BL) for a specified time. If the field is empty, it does not apply. You can also specify keys with individual BL durations via N=Time.\
  Example: \
  if the **TriggerKeyBL** field contains a line such as: 1 2 3 4=100 5 6 7=300, this means that the strategy may be stopped by different keys — 1 2 3 4 5 6 7 — but the duration of the stop will be assigned differently:
  - For keys 1 2 3 5 6, the duration will be determined by the value set in the **TriggerSeconds** parameter
  - For the key 4=100, its own custom duration specified after the equals sign will be applied — that is, after receiving key 4, the Slave strategy will operate for 100 seconds
  - For the key 7=300, its own custom duration specified after the equals sign will be applied — that is, after receiving key 7, the Slave strategy will operate for 300 seconds.
- **TriggerSecondsBL**: a field for specifying the duration (seconds) during which the Slave strategy will not operate after activation by keys listed in TriggerKeysBL without the equals sign. A positive integer between 0 and 864000 (864k). If 0, it does not apply.\
  Example: \
  if a Master strategy is triggered and activates key 1 (for instance, from its TriggerKey=1 parameter), then any Slave strategy that contains key 1 in its TriggerKeysBL=1 parameter will stop for the duration specified in the Slave strategy’s TriggerSecondsBL=60 parameter (for 60 seconds).
- **SellByTriggerBL**: a field for specifying key **N** (1–200) or a list of keys (N1 N2 N3 …), taken from the keys used in **TriggerKeysBL**, upon receiving which all Sell orders will be closed on markets where those keys fired. If the field is empty, it does not apply.\
  Example:\
  If a Master strategy is triggered and activates key 1 (for example, from its TriggerKey=1 parameter), then any Slave strategy that contains key 1 in its TriggerKeysBL=1 parameter will stop for the duration specified in the Slave strategy’s TriggerSecondsBL=60 parameter (for 60 seconds). And if SellByTriggerBL=1 is additionally specified, all Sell orders will also be closed on the markets where key 1 was triggered.
- **CancelByTriggerBL**: **YES/NO** checkbox. \
  If **YES**, all Buy orders will be canceled when a key listed in **SellByTriggerBL** parameter.\
  Example: \
  if a Master strategy is triggered and activates key 1 (for example, from its TriggerKey=1 parameter), then any Slave strategy that contains key 1 in the TriggerKeysBL=1 parameter will stop for the duration specified in the Slave strategy’s TriggerSecondsBL=60 parameter (for 60 seconds). And if CancelByTriggerBL=YES is additionally specified, all Buy orders will also be canceled on the markets where key 1 was triggered.

### Trigger behavior specifics

The **Manual** strategy activates a trigger key in the following cases:

1. When a Buy order is placed using the **TriggerKey** parameter, if the ActiveTrigger=YES checkbox is enabled.
2. When a trade is closed, via the **TriggerKeyProfit** and **TriggerKeyLoss** parameters. In this case:
   - if the trade is closed in profit, the key specified in **TriggerKeyProfit** is activated (e.g., if TriggerKeyProfit=1, key 1 will be activated)
   - if the trade is closed at a loss, the key specified in **TriggerKeyLoss** is activated (e.g., if TriggerKeyLoss=2, key 2 will be activated).
   - If you need activation on any trade closure, whether profit or loss, set identical keys in both parameters (**TriggerKeyProfit** and **TriggerKeyLoss**). \
     Example: TriggerKeyProfit=3 and TriggerKeyLoss=3 → key 3 activates regardless of outcome.

If both parameters are set to zero (TriggerKeyProfit=0 and TriggerKeyLoss=0), the **Manual** strategy will not activate any keys upon trade closure.

All other strategies activate keys from **TriggerKey** on detection (even without AutoBuy). They may also activate keys from **TriggerKey** when placing a Buy order, if the **ActiveTrigger=YES** checkbox is enabled.

For convenient management of trigger keys — resetting, activation, checking free/used keys, and viewing associated strategies — use the **Manage Triggers** window, available via: **Menu → Manage Triggers**.

## Navigation

Path: [Main](https://moonbot.pro/?format=md) / [Documentation](https://moonbot.pro/documentation?format=md) / [Strategies](https://moonbot.pro/documentation/strategies?format=md) / [General Parameters for All Strategies](https://moonbot.pro/documentation/general-parameters-for-all-strategies?format=md) / “Triggers Master/Slave” Tab

Parent section: [General Parameters for All Strategies](https://moonbot.pro/documentation/general-parameters-for-all-strategies?format=md)

Previous: [“Dynamic White\\Black List” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/dynamic-whiteblack-list-tab?format=md)

Next: [“Session” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/session-tab?format=md)

## Related

- [“Session” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/session-tab?format=md)
- [“Buy conditions” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/buy-conditions-tab?format=md)
- [“Delta Modifiers” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/delta-modifiers-tab?format=md)
- [“Multiple Orders” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/multiple-orders-tab?format=md)
- [“Stops” Tab](https://moonbot.pro/documentation/general-parameters-for-all-strategies/stops-tab?format=md)
