How to Send TradingView Alerts to ByBit Inverse Perpetual

Bybit

Tradingview to Anywhere tool has made it possible to automate TradingView alerts and TradingView strategy to ByBit Inverse Perpetual . The bot uses human-like commands that can be combined with TradingView’s dynamic alert messages. Once you have set up your TradingView to ByBit Webhook, proceed to set up alerts on TradingView as explained below:

Automating TradingView Strategy to ByBit Inverse Perpertual
Use either {{strategy.order.action}} - which returns the string “buy” or “sell” for the executed order or {{strategy.market_position}} - which returns the current position of the strategy in string form: “long”, “flat”, or “short” (recommended for a strategy with a close command). Specify the exchange, quantity, and account using the TradingView to Anywhere commands. For Example:
{{strategy.order.action}} BTCUSD q=150 tp=10% sl=5% - this will only work if the position mode settings is on one way position mode.
{{strategy.order.action}} BTCUSDT q=150 tp=10% sl=5% hedge - this will only work if the position mode settings is in hedge mode.

For a strategy with a close command:
{{strategy.market_position}} BTCUSD q=150 tp=10% sl=5% - this will only work if the position mode settings is on one way position mode.
{{strategy.market_position}} BTCUSDT q=150 tp=10% sl=5% hedge - this will only work if the position mode settings is in hedge mode.
You can add more parameters such as p= to convert positions into pending orders.

Automating TradingView Indicator to ByBit Inverse Perpetual
To automate an indicator, select the indicator as to the condition, choose long or short condition, select once per bar to avoid repainting issues, and input the applicable buy/sell command in the message field. For example:
Buy BTCUSDT q=150 tp=10% sl=5% - this will only work if the position mode settings are one-way position mode.
Buy BTCUSDT q=150 tp=10% sl=5% hedge - this will only work if the position mode settings are in hedge mode.

In the above example for a long, this will buy BTC worth 150USD and place the take profit and stop loss accordingly on your ByBit Inverse Perpetual. A short condition will follow the same process but this time it would be Sell.

We are now supporting multi commands meaning you can send more than one command with a single alert. The only requirement is for each command to start on a new line. The commands are also executed in the order in which they occur.
Example:
Close BTCUSD
BUY ETHUSD Q=150
The above command will first close any open BTCUSD positions before opening an ETHUSD position worth 150USD
That’s all, it is that simple!