Primitives
order
Basic order placement algorithm that allows placing market or limit orders with specified quantity and action (buy/sell).
order (tick)
Basic order placement algorithm that allows placing market or limit orders with specified quantity and action (buy/sell).
Input parameters
| Prop | Type | Default | Description |
|---|---|---|---|
type* | string | market | The order type (market, limit, stop, stopLimit) |
action* | string | The order action (buy or sell) | |
size* | number | The number of shares/contracts to order | |
limitPrice | number | The limit price for limit orders (optional) | |
transmit | boolean | false | Whether to transmit the order immediately |
leverage | number | 1 | The leverage for the order crypto only |
marginMode | string | cross | The margin mode for the order crypto only |
note | string | The note for the order |
SQL example
TICK volume WITH minutes=3 > 50 THEN order SET size=100, price=51.25, transmit=true