Place Order
POST/api/v1.0/accounts/{acc_id}/ordersPlace a new order.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
acc_id | string | Yes | Business account ID. |
Request Parameters
| Parameter | Type | Position | Required | Description |
|---|---|---|---|---|
code | string | body | Yes | Tradable symbol. Format: exchange.symbol, e.g. US.AAPL, US.AAPL250926C235000 |
qty | string | body | Yes | Order quantity. The unit of options and futures is "contract". |
price | string | body | No | Order price. 4 decimal place accuracy (9 for futures), excess part will be rounded. |
side | string | body | Yes | Trading direction. Values: BUY, SELL, SELL_SHORT, BUY_BACK |
order_type | string | body | Yes | Order type. Values: LIMIT, MARKET, AUCTION, AUCTION_LIMIT, STOP, STOP_LIMIT, MARKET_IF_TOUCHED, LIMIT_IF_TOUCHED |
time_in_force | string | body | Yes | Valid period. Values: DAY (good for the day), GTC (good until cancel) |
session | string | body | No | Trading session (US stocks only). Values: RTH (regular trading hours), RTH+Pre/Post-Mkt, OVERNIGHT (night trading only), ALL_DAY. Market orders only support RTH. |
aux_price | string | body | No | Trigger price. Required when order type is STOP, STOP_LIMIT, MARKET_IF_TOUCHED, or LIMIT_IF_TOUCHED. The price will be rounded to 3 decimals for securities account, and 9 decimals for futures account. |
lot_type | string | body | No | Lot type, default round lot. Used for HK stock trading. |
remark | string | body | No | Remark. Maximum length after converting to UTF-8 is 64 bytes. |
order_class | string | body | No | Order class. Specify as MLEG for multi-leg orders. |
multi_leg_info | object | body | No | Multi-leg order info. Required when placing multi-leg orders. |
Request Example
bash
curl -X POST 'https://webapi.moomoo.com/api/v1.0/accounts/{acc_id}/orders' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <AccessToken>' \
-d '{
"code": "US.AAPL",
"qty": "100",
"price": "150.00",
"side": "BUY",
"order_type": "LIMIT",
"time_in_force": "DAY"
}' | jqResponse Example
json
{
"s": "ok",
"d": {
"order_id": "New order identifier."
}
}Failure:
json
{
"s": "error",
"errcode": -1200,
"errmsg": "Error message.",
"jump_url": "a jump url",
"need_order_confirm": true,
"confirm_id": "a confirm id"
}TIP
When need_order_confirm is true in the response, you need to call the Order Confirm endpoint.