All Collections
Features
New Features
How to Create a Dynamic TradingView Alert Condition?
How to Create a Dynamic TradingView Alert Condition?

Un-trigger a Trading-View webhook condition to avoid strategy triggers when your TradingView condition is no longer met.

Daniel Bar avatar
Written by Daniel Bar
Updated over a week ago

What is a TradingView Alert Condition?

TradingView Alert Conditions allow a trader to create automated trading strategies triggered by one or more of the wide array of TradingView Alerts.

Why Would a Trader Want a TradingView Condition to be more Dynamic?

Whenever an automated strategy contains multiple conditions that are expected to be met simultaneously in order to trigger, having a webhook condition creates a problem.

Since the webhook message triggers the webhook condition, the condition is considered triggered even if the relevant scenario is not valid anymore. Adding an 'untriggering' message to a webhook condition allows you to make sure the webhook condition doesn't stay triggered when it is no longer valid. This is especially useful when one of the webhook conditions is time sensitive since a time-triggered condition once triggered could never untrigger on its own. Additionally, an 'untriggering' message also allows you to turn the trigger off if the asset moves in an unfavorable direction.

How to Untrigger a TradingView Alert Condition

  1. Decide which new trade or existing trade with a webhook message you would like to add an untriggering message.

  2. Create the untrigger message which acts as another webhook message and contains the the original alertId +"untrigger":true. An example might look like this:{"alertId": "0b47a939-fad1-4e1c-b9d4-768ac082e123", "untrigger":true}

  3. If or when Capitalise.ai receives a webhook msg that contains: "untrigger":true
    Then the original webhook message will untrigger changing the status from on to off.

    1. For example:
      The following message {"alertId": "0b47a939-fad1-4e1c-b9d4-768ac082e123", "untrigger":true}
      Will untrigger any webhook condition that has the alertid 0b47a939-fad1-4e1c-b9d4-768ac082e123

For example:

Entry Strategy: The Entry Condition is linking the Relative Strength Index with the Volume Weighted Average Price (VWAP) which is activated through a Trading View Webhook Alert

It can be entered into the Capitalise.ai trading platform Wizard as:

If the BTC/USDT RSI is below 30 and Webhook triggers buy 1,000 USD worth of BTC/USDT

There will be a URL code in the top to copy and below it a message code to copy. You can use Notepad or Stickies Apps to save the URL and message codes.

We then could go back to Trading View and set an alert condition that when BTC/USDT is greater than the Lower Band of the VWAP so this creates a triggering condition for this strategy..

Insert the URL code in the space Webhook URL. You could name the message the On Message and copy the message from the Wizard and put in the message box as shown above.

Insert the URL code in the space Webhook URL. You could name the message the Off Message and copy the message from the msg and put in the message box with “untrigger”: true as shown below.

Stay tuned for more examples of how to use TradingView Webhook messages (the trigger and untrigger messages) to further finetune your automated trading strategies.

Did this answer your question?