Place an order

Note

Place a US stock order for a client account. Supported order types are L (limit) and M (market). For a market order, send price: "0".

For GTD, provide orderExpiryDate. Conditional orders UT, DT, SL and OCO require triggerPrice; OCO also requires stopPrice; TIME requires timeToSend.

reference is your custom order identifier. If omitted, the server generates a UUID. Use orderNo for modifications; cancellation accepts either orderNo or reference.

Check data.orderStatus as well as code: a rejected order can return code: 200 with orderStatus: "REJ", a null orderNo, and a rejectReason. Acceptance does not mean the order has filled. Follow execution through Query orders, Query trades, or WebSocket.

Body Params
string
required

Account ID identifying the client account for the request.

string
enum
required

Market.

Allowed:
string
required

Security code, for example AAPL.

string
enum
required

B = buy; S = sell.

Allowed:
string
enum
required

L = limit; M = market.

Allowed:
string

Decimal price string. Required for L; send "0" for M.

string
required

Order quantity in shares.

string
enum

Defaults to Day,Time in force.

Allowed:
string

Required for GTD. Format YYYY-MM-DD.

string

Caller-supplied order reference. The server generates a UUID if omitted.

string
enum

Omit or leave empty to send immediately. Conditional order type.

Allowed:
string

Required for UT, DT, SL and OCO.

string

Required for OCO.

string

Required for TIME. Format yyyy-MM-dd HH:mm:ss.

string
enum

Y = extended hours only; N = regular hours only; A = all day.

Allowed:
Headers
string

Trace ID. Generated by the server if omitted.

Responses

Language
LoadingLoading…
Response
Choose an example:
application/json