place_order
Places single-leg or bracket buy/sell orders for stocks, crypto, and options, including market, limit, stop, and take-profit/stop-loss exit legs; executes real trades.
Instructions
Place a single-leg order (buy/sell stocks, crypto, or options).
⚠️ This executes a real trade. Consider running preflight_order first.
Args:
symbol: Ticker symbol (e.g. "AAPL").
instrument_type: EQUITY, OPTION, or CRYPTO.
order_side: BUY or SELL.
order_type: MARKET, LIMIT, STOP, STOP_LIMIT, MARKET_ON_CLOSE or
LIMIT_ON_CLOSE. The on-close types execute at the closing auction.
time_in_force: DAY or GTD. Default is DAY.
quantity: Number of shares/contracts (mutually exclusive with amount).
amount: Dollar amount (mutually exclusive with quantity).
limit_price: Required for LIMIT, STOP_LIMIT and LIMIT_ON_CLOSE orders.
stop_price: Required for STOP and STOP_LIMIT orders.
open_close_indicator: For options only — OPEN or CLOSE.
expiration_time: Required when time_in_force is GTD. ISO 8601 format.
equity_market_session: CORE or EXTENDED. For equity orders only. Not the
REGULAR / REST_OF_DAY / TWENTY_FOUR_HOURS values that get_order and
search_orders report in equityMarketSession; never feed those back here.
tax_lot_matching_instructions: Optional list of specific tax lots to
sell, each a dict {"tax_lot_id": str, "quantity": str}. Constraints
enforced by the API: at most 8 per request; only for a SELL equity
order with open_close_indicator=CLOSE; every lot must be the same
symbol as the order; only MARKET or good-for-day LIMIT orders;
the quantities must sum to the order quantity; and the account's
tax-lot information must have been updated today. Omit to let the
broker apply its default lot-matching.
order_class: SIMPLE (default) places a standalone order. BRACKET, OCO or
OTO place a bracket order, where the exit legs below are submitted
automatically once this entry order fills. Bracket orders are for
EQUITY and OPTION only, need a whole-share quantity (not amount),
must use the CORE market session, and the entry order_type must be
LIMIT or MARKET — LIMIT only for OCO. Every leg of the bracket,
entry included, reports the entry's order ID as its bracketId.
preflight_order cannot check the exit legs — it validates the entry
order only.
take_profit_limit_price: Limit price of the take-profit exit leg, placed
on the opposite side of the entry. Requires a bracket order_class.
stop_loss_stop_price: Stop price of the stop-loss exit leg, placed on the
opposite side of the entry. Requires a bracket order_class. Placed as
a STOP order unless stop_loss_limit_price is given too.
stop_loss_limit_price: Limit price that makes the stop-loss leg a
STOP_LIMIT order instead of a STOP order. Requires
stop_loss_stop_price.
account_id: Account ID. Optional if PUBLIC_COM_ACCOUNT_ID is set.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"symbol": "<symbol>",
"instrument_type": "<instrument_type>",
"order_side": "<order_side>",
"order_type": "<order_type>"
},
"name": "place_order"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| amount | No | ||
| symbol | Yes | ||
| quantity | No | ||
| account_id | No | ||
| order_side | Yes | ||
| order_type | Yes | ||
| stop_price | No | ||
| limit_price | No | ||
| order_class | No | ||
| time_in_force | No | DAY | |
| expiration_time | No | ||
| instrument_type | Yes | ||
| open_close_indicator | No | ||
| stop_loss_stop_price | No | ||
| equity_market_session | No | ||
| stop_loss_limit_price | No | ||
| take_profit_limit_price | No | ||
| tax_lot_matching_instructions | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |