Alerts
Lune Automated Strategies support a fully configurable alert system within TradingView, giving users real-time notifications for entries, exits, and partial exits. These alerts can
Overview#
Lune Automated Strategies support a configurable alert system within TradingView. It gives you real-time notifications for entries, exits, and partial exits. You can also use these alerts with Lune Auto Trader to run automated trade execution based on signal events.
The alert system lets you define custom messages, select alert types, and set how TradingView handles these notifications.
If you use Lune Auto Trader, alerts from this system can automate your trades.
Refer to this guide to get started with Lune Auto Trader automation: Automate TradingView Strategies Guide
How alerts work#
The alert system uses TradingView's built-in strategy alert function. When you create an alert, set your alert message to:
{{strategy.order.alert_message}}
This tells TradingView to listen to the alerts embedded in the Lune strategy and trigger the right alert messages.
Alert settings#
You can toggle alerts for the following event types in your strategy settings:
| Alert Type | Description |
|---|---|
| Entry Alerts | Get alerts when a long or short trade entry is triggered. |
| Exit Alerts | Get notified when a position is closed based on an exit condition. |
| Partial Exit Alerts | Alerts trigger when partial take profit levels are reached. |
You can enable or disable each alert type independently for long and short trades.
Custom alert messages#
You can define personalized alert messages for each trade event type. These messages are included in the alert sent by TradingView and can be set in the strategy settings.
| Alert Message Field | Purpose |
|---|---|
| Entry Long Alert Message | Triggered when a long entry is signaled. |
| Entry Short Alert Message | Triggered when a short entry is signaled. |
| Exit Long Alert Message | Triggered when a long trade exits. |
| Exit Short Alert Message | Triggered when a short trade exits. |
| Long Partial Exit Message | Triggered on a partial TP level for long trades. |
| Short Partial Exit Message | Triggered on a partial TP level for short trades. |
These messages suit webhook integrations, mobile push notifications, or automated systems like Lune Auto Trader.
Best practices#
- For automation: Copy your custom alert message into the alert box when you create an alert in TradingView.
- Webhook use: These messages can include JSON for integrations with third-party bots and systems.
- Always use the alert message
{{strategy.order.alert_message}}when you create an alert.
How to set up alerts in TradingView#
-
Open the chart with your configured Lune Automated Strategy.
-
Open your strategy settings and go to the Alert Configuration section. Make sure all alerts are enabled. Fill out the text boxes with your alert message.
-
Create a TradingView alert and set your alert message to
{{strategy.order.alert_message}}. Customize your settings and notifications. -
Click Create. That's it.