POST
Closes trade by market
Closes a specific take profit trade within a SmartTrade at market price using its ID. The endpoint is available for Take Profit Trades for the statuses to_process, order_placed, and trailing_activated.
POST/api/v1/smart_trades/:smart_trade_id/trades/:trade_id/close_by_market
dev_getting_started.permission:SMART_TRADES_WRITE
dev_getting_started.security:SIGNED
Path Parameters
smart_trade_idintegerdev_getting_started.required
Unique Quentrade ID for this SmartTrade entity.
trade_idintegerdev_getting_started.required
Unique Quentrade ID for Trade entity.
Example Request
POST/api/v1/smart_trades/12345678/trades/1047934729/close_by_market
Response Parameters
If successful, the response includes a copy of the updated SmartTrade entity.
Example Response
close_trade_response.json
200 OK