Entering a Short Position
Entering a short position means you are going short on an asset. This is useful if you want to enter a position at once, for example when you want to enter a position when a certain condition is met.
Often, you want to enter a short position when you think the price will go down.
Currently, only market orders are supported. More order types will be added in the future.
Method
When you enter a short position, all open long positions will be closed.
Inputs
Parameter | Argument type | Description | Default Value |
---|---|---|---|
quantity | float | Quantity to short | - |
comment | Optional[str] | Comment to add to the order | "" |
tags | Optional[Dict[str, str]] | Tags to add to the order | {} |
stop_loss_percent | Optional[float] | Stop loss percentage | None |
take_profit_percent | Optional[float] | Take profit percentage | None |
Outputs
Order that was created to enter the position.