Trading API

Get account positions

Changed on
get/rest/api/v1/accounts/{accountId}/positions

Request

Path parameters

accountIdstring uuid required

Response

OK

brokerTimeClosestring

Original time string from the broker

brokerTimeOpenstring

Original time string from the broker

closePricenumber
closeTimestring date-time

ISO 8601

commentstring
commissionnumber
copierIdstring uuid

Copier that opened this position. Null when the position was not opened by a copier.

dealType'DealBuy' | 'DealSell' | 'Balance' | 'Credit' | 'Charge' | 'Correction' | 'Bonus' | 'Commission' | 'DailyCommission' | 'MonthlyCommission' | 'DailyAgentCommission' | 'MonthlyAgentCommission' | 'InterestRate' | 'CanceledBuy' | 'CanceledSell' | 'Dividend' | 'FrankedDividend' | 'Tax' | 'AgentCommission' | 'SoCompensation' | 'SoCreditCompensation'
idstring
lossProtectedboolean

True when the position is held by the Loss-Protected Exit feature: the master closed it while it was in loss, so the close was not replicated. Held positions stay open until their Take Profit or Stop Loss triggers or they are closed manually. Null for positions that are not held.

magicNumberstring

Magic number carried by the position, as a string. Absent/null when no magic number was set on the order (a magic of 0 on the broker side is reported as absent rather than as the string "0").

netProfitnumber
openPricenumber
openTimestring date-time

ISO 8601

orderType'Buy' | 'Sell' | 'BuyLimit' | 'SellLimit' | 'BuyStop' | 'SellStop'
placedType'Manually' | 'Mobile' | 'Web' | 'ByExpert' | 'OnSL' | 'OnTP' | 'OnStopOut' | 'OnRollover' | 'OnVmargin' | 'OnSplit' | 'ByDealer' | 'Gateway' | 'Signal' | 'Settlement' | 'Transfer' | 'Sync' | 'ExternalService' | 'Migration'
profitnumber
requestIdstring
signalProviderIdstring uuid

Signal provider the position was copied from. Null when the position was not opened through a signal subscription.

sourceAccountIdstring uuid

Source (master) account of the copied position. Null when the position was not opened by a copier or when the source account belongs to another user (signal provider or investor program).

sourcePositionIdstring

Position id on the source (master) account. Null when the position was not opened by a copier.

statestring
stopLossnumber
swapnumber
symbolstring
takeProfitnumber
volumenumber

Changes

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status

    • info

      added the optional property / to the response with the status