Trades & positions

Closed trades and currently open positions, paginated and filterable.

Two endpoints, deliberately separate: closed trades are history and can number in the thousands, open positions are a short list that changes minute to minute.

List closed trades

GET /api/v1/accounts/{slug}/trades

Newest first.

Query parameters

from
string
Only trades closed on or after this date. YYYY-MM-DD or a full ISO 8601 instant.
to
string
Only trades closed on or before this date.
page
integer
Defaults to 1.
Closed trades are served in fixed pages of 20, so limit has no effect on this endpoint — pagination.limit always reports the real page size. Page through with page and stop on has_more.Filtering by instrument or magic number is not available here yet: use by_symbol and by_magic_number on the account for the aggregated view.

Response

Response
{
  "data": [
    {
      "ticket": "46202135",
      "symbol": "EURUSD-ECN",
      "side": "buy",
      "volume": 0.01,
      "open_price": 1.15418,
      "close_price": 1.15657,
      "stop_loss": null,
      "take_profit": null,
      "opened_at": "2026-08-10T23:00:00Z",
      "closed_at": "2026-08-14T15:00:01Z",
      "profit": 2.39,
      "commission": -0.06,
      "swap": 0,
      "net_profit": 2.33,
      "comment": "Dark Algo",
      "magic_number": 501031
    }
  ],
  "pagination": { "page": 1, "limit": 20, "total": 16, "has_more": false }
}

The trade object

ticket
string
The broker's identifier for the trade. A string, because not every platform uses numbers and some are long enough to lose precision as a JSON number.
side
string
buy or sell.
volume
number
Size in lots.
stop_loss
number
The stop loss price, or null when none was set. Never 0 — see conventions.
take_profit
number
Same, for the take profit.
profit
number
Gross result, before commission and swap.
commission
number
Negative when charged.
swap
number
Overnight financing. Negative when charged, positive when credited.
net_profit
number
profit + commission + swap — what the trade actually did to the balance.
comment
string
The order comment from the platform, null if empty or hidden by the owner.
magic_number
integer
MT4 and MT5 only, null elsewhere. Usually identifies the strategy or EA that placed the trade.
Sum net_profit, not profit. Adding up the gross figures is the most common way to end up with a total that does not match the account balance.

List open positions

GET /api/v1/accounts/{slug}/positions

Same object, with close_price, closed_at and net_profit absent — the trade has not finished — and profit showing the current floating result.

Response
{
  "data": [
    {
      "ticket": "46318772",
      "symbol": "EURUSD-ECN",
      "side": "sell",
      "volume": 0.01,
      "open_price": 1.16104,
      "stop_loss": null,
      "take_profit": null,
      "opened_at": "2026-08-21T08:14:22Z",
      "profit": -3.42,
      "commission": -0.06,
      "swap": -0.11,
      "comment": "Dark Algo",
      "magic_number": 501031
    }
  ],
  "pagination": { "page": 1, "limit": 50, "total": 1, "has_more": false }
}
Open positions are as fresh as the account's last report. An account connected through our Expert Advisor reports continuously while its terminal is running; one connected by investor password or through a broker API updates on a schedule. updated_at on the account tells you how recent the data is.

Hidden data

An account owner can hide lot sizes, stop losses and take profits, order comments, or the trade list entirely. When something is hidden you still get the field, neutralised — null for prices and comments, 0 for volume — and a hidden list comes back empty with total: 0.

Your own accounts are never filtered.