AlertCondition
forge.alertsclassSince Forge API 1
Signaturepython
forge.alerts.AlertCondition(label: str,/,*,when: object,message: str | None = None,frequency: str = 'bar_close') -> NoneOne condition an indicator can alert on: a label, the output that says when, a message.
Parameters
| Name | Type | Default |
|---|---|---|
| label | str | |
| when | object | |
| message | str | None | None |
| frequency | str | 'bar_close' |
AlertCondition("RSI above 70", when=hot, message="{symbol} RSI {out.rsi}"). The message
is optional; without one the alert says its label. See the module text for what when,
frequency and the placeholders mean.