Skip to main content
POST
Place order

Authorizations

X-API-Key
string
header
required

API key generated at Dashboard, Settings, Developer. Format: doji_ak_...

X-API-Secret
string
header
required

API secret returned once at key creation. Format: doji_sk_...

Body

application/json
account_id
string<uuid>
required

UUID of the account to trade on. Must be owned by the authenticated user.

symbol
string
required

Tradable symbol, e.g. BTC-USD, ETH-USD, AAPL-USD. Use GET /tickers for the full catalog. Symbol variants like BTCUSD, BTC/USD, and btc-usd are also accepted.

Example:

"BTC-USD"

side
enum<string>
required

Order side.

Available options:
BUY,
SELL
kind
enum<string>
required

Order type.

Available options:
MARKET,
LIMIT,
STOP,
TAKE_PROFIT
quantity
number
required

Base-asset quantity. Must be positive.

Example:

0.05

price
number

Limit price. Required when kind is LIMIT.

Example:

62500

trigger_price
number

Trigger reference price. Required when kind is STOP or TAKE_PROFIT.

tif
enum<string>

Time-in-force. GTC good till cancelled, GTD good till date, GTX post-only intent (same as GTC plus post_only), IOC immediate or cancel, FOK fill or kill.

Available options:
GTC,
GTD,
GTX,
IOC,
FOK
flags
object

Order behaviour flags.

client_id
string

Your own deduplication ID. Retrying with the same client_id is safe, the engine returns the original result rather than placing a duplicate. Surfaces in fills and audit logs.

Example:

"my-bot:strategy-A:1234"

platform_id
enum<string>

Execution venue override. Overrides the account default for this order only.

Available options:
GMX,
OSTIUM
parent_order_id
string<uuid>

UUID of a parent order. Links a TP or SL to its entry.

position_id
string<uuid>

UUID of a specific open position to target when reducing.

Response

Order result. Check violations before assuming success.

order
object
trades
object[]

Fills generated immediately by the order (market orders, IOC/FOK).

violations
object[]

Non-empty when the order was rejected by a risk rule. The order is not placed when violations are present.