Place a take-profit / stop-loss trigger
Perpetuals
Place a take-profit / stop-loss trigger
Place a TP/SL trigger on an existing position. Routed through
createDecreasePositionRequest2 with requestType=Trigger.
trigger_above_threshold encodes the direction the price must cross
to fire (true = oracle ≥ trigger, false = oracle ≤ trigger). The
caller maps this to TP vs SL based on position side; the on-chain ix
does not distinguish between them.
POST
Place a take-profit / stop-loss trigger
Authorizations
Body
application/json
Minimum array length:
1Available options:
long, short Trigger price in USDC micros.
Direction the price must cross to fire the trigger. true =
oracle ≥ trigger; false = oracle ≤ trigger. The caller maps
this to TP vs SL based on position side.
True = close the entire position on trigger.
Required when entire_position=false.
