StaticbracketCalculates levels for a bracket order with custom TP and SL.
current asset price
stop loss percentage from 0 to 100
take profit percentage from 0 to 100
position type: "long" or "short"
priceTakeProfit and priceStopLoss in fiat
StaticmoonbagCalculates levels for the "moonbag" strategy — fixed TP at 50% from the current price.
current asset price
stop loss percentage from 0 to 100
position type: "long" or "short"
priceTakeProfit and priceStopLoss in fiat
Utilities for calculating take profit and stop loss price levels. Automatically inverts direction based on position type (long/short).