Skip to content

staff.positions ​

11 methods on staff.positions. Each returns the answer's data and throws NoviqaError on a failed answer.

list ​

GET/admin/v1/positions

List open positions

One page of open positions across accounts, each with its account's group and the live current price, profit and margin from execution (the stored values stay when execution does not answer). Rows are limited to trading accounts whose group is in the caller's group scope. Filters: group a group mask (e.g. real\*), company the licence company of the group, login an exact login, symbol an exact symbol name (any case). page is 1-based (default 1), limit defaults to 100, at most 1000; total counts every match.

More details

Rights: the staff member needs every one of: trades.view.

Parameters
groupstring · query
companystring · query
logininteger · query
symbolstring · query
pageinteger · query
limitinteger · query
Returns
Promise<OpenPosition_>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.list({
  group: "string",
  company: "string",
  login: 1001
})
bash
curl -X GET "$NOVIQA_API_URL/admin/v1/positions?group=string&company=string&login=1001" \
  -H "Authorization: Bearer $NOVIQA_TOKEN"
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "items": [
      {
        "comment": "Deposit via bank",
        "contract_size": "1.08452",
        "dealer": 1,
        "digits": 5,
        "external_id": "string",
        "group": "real\\standard",
        "id": 1,
        "login": 1001,
        "margin": "108.45",
        "opened_at": "2026-09-25T10:15:00Z",
        "origin": {},
        "price_current": "1.08452"
      }
    ],
    "page": 1,
    "total": 1
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.list(query?: { group?, company?, login?, symbol?, page?, limit? }, options?: RequestOptions): Promise<http.tradePage_account.OpenPosition_>

bulkClose ​

POST/admin/v1/positions/bulk-close

Close positions in bulk

Over the open trades of trading accounts in the caller's scope: close positions (close_positions), delete pending orders (delete_orders) and/or clear stop loss and take profit (clear_stops, applied only where one is set); choose at least one. Pick the trades either by symbol (required then; exact name) and groups (a group mask, empty = every group in scope), or by id in positions / orders (then symbol and groups are ignored; ids out of scope are skipped). At most 1000 trades per request (total above 1000 means run it again for the rest); comment at most 64 characters. With preview true nothing is done: the answer lists the matching positions and orders. Otherwise each trade is sent as its own trade request with the caller as dealer (checked, routed and journaled on its own) and results holds each outcome: status done or rejected with its code (see POST /admin/v1/accounts/{login}/trades for the codes). One summary journal line. Each preview row carries the live price_current and floating profit (positions) / price_current (orders) from execution, as the positions and orders lists do (stored values when execution does not answer). With the confirm_actions right a non-preview request needs confirm_token and confirm_code from POST /admin/v1/confirmations, else 403 confirmation_required.

More details

Rights: the staff member needs every one of: trades.edit.

Request body
clear_stopsboolean
stop loss and take profit to 0
close_positionsboolean
commentstring
confirm_codestring
the code as the user typed it
confirm_tokenstring
from POST /admin/v1/confirmations
delete_ordersboolean
groupsstring
group mask, "" = every group in scope
ordersinteger[]
positionsinteger[]
picked positions; with orders, replaces symbol and groups
previewboolean
list what would be done, do nothing
symbolstring
name; required unless ids are given
Returns
Promise<BulkCloseReply>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.csrf_invalid: request refused: reload the page and try again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403confirmation_required: confirm this action with the code shown
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.bulkClose({
  close_positions: true,
  comment: "market halt",
  delete_orders: true,
  groups: "real\\*",
  preview: true,
  symbol: "EURUSD"
})
bash
curl -X POST "$NOVIQA_API_URL/admin/v1/positions/bulk-close" \
  -H "Authorization: Bearer $NOVIQA_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
  "close_positions": true,
  "comment": "market halt",
  "delete_orders": true,
  "groups": "real\\*",
  "preview": true,
  "symbol": "EURUSD"
}'
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "orders": [
      {
        "activated_at": "2026-09-25T10:15:00Z",
        "by_position_id": 1,
        "comment": "Deposit via bank",
        "contract_size": "1.08452",
        "created_at": "2026-09-25T10:15:00Z",
        "dealer": 1,
        "deviation_pts": 1,
        "digits": 5,
        "done_at": "2026-09-25T10:15:00Z",
        "expiration": "string",
        "expires_at": "2026-09-25T10:15:00Z",
        "external_id": "string"
      }
    ],
    "positions": [
      {
        "comment": "Deposit via bank",
        "contract_size": "1.08452",
        "dealer": 1,
        "digits": 5,
        "external_id": "string",
        "group": "real\\standard",
        "id": 1,
        "login": 1001,
        "margin": "108.45",
        "opened_at": "2026-09-25T10:15:00Z",
        "origin": {},
        "price_current": "1.08452"
      }
    ],
    "results": [
      {
        "code": "ok",
        "id": 1,
        "kind": "string",
        "login": 1001,
        "message": "string",
        "operation": "string",
        "status": "done",
        "symbol": "EURUSD"
      }
    ],
    "total": 1
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.bulkClose(body: account.BulkClose, options?: RequestOptions): Promise<account.BulkCloseReply>

closed ​

GET/admin/v1/positions/closed

List closed positions

One page of positions closed across accounts, last closed first, built from their deals, with totals over every match. from and to apply to the close time; action is ignored. Rows are limited to trading accounts whose group is in the caller's group scope. Filters: group a group mask (at most 128 characters), company the licence company, login an exact login, symbol an exact symbol name (any case, at most 64 characters), from (inclusive) and to (exclusive) RFC3339 times such as 2026-09-24T00:00:00Z, either may be left out, to after from. page is 1-based (default 1), limit defaults to 100, at most 1000.

More details

Rights: the staff member needs every one of: trades.view.

Parameters
groupstring · query
mask
companystring · query
logininteger · query
symbolstring · query
actionstring · query
fromstring · query
tostring · query
pageinteger · query
limitinteger · query
Returns
Promise<ClosedPage>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.closed({
  group: "string",
  company: "string",
  login: 1001
})
bash
curl -X GET "$NOVIQA_API_URL/admin/v1/positions/closed?group=string&company=string&login=1001" \
  -H "Authorization: Bearer $NOVIQA_TOKEN"
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "items": [
      {
        "closed_at": "2026-09-25T10:15:00Z",
        "commission": "1.08452",
        "contract_size": "1.08452",
        "digits": 5,
        "fee": "1.08452",
        "group": "real\\standard",
        "login": 1001,
        "opened_at": "2026-09-25T10:15:00Z",
        "position_id": 1,
        "price_close": "1.08452",
        "price_open": "1.08452",
        "profit": "12.40"
      }
    ],
    "page": 1,
    "total": 1,
    "totals": {
      "commission": "1.08452",
      "count": 1,
      "fee": "1.08452",
      "profit": "12.40",
      "swap": "1.08452",
      "volume": "0.10"
    }
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.closed(query?: { group?, company?, login?, symbol?, action?, from?, to?, page?, limit? }, options?: RequestOptions): Promise<report.ClosedPage>

count ​

GET/admin/v1/positions/count

Count open positions

How many open positions GET /admin/v1/positions would list with the same authorized filters. Reads a database count only, without position rows or execution valuations. Page and limit do not restrict the count.

More details

Rights: the staff member needs every one of: trades.view.

Parameters
groupstring · query
companystring · query
logininteger · query
symbolstring · query
pageinteger · query
limitinteger · query
Returns
Promise<count>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.count({
  group: "string",
  company: "string",
  login: 1001
})
bash
curl -X GET "$NOVIQA_API_URL/admin/v1/positions/count?group=string&company=string&login=1001" \
  -H "Authorization: Bearer $NOVIQA_TOKEN"
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "total": 1
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.count(query?: { group?, company?, login?, symbol?, page?, limit? }, options?: RequestOptions): Promise<http.count>

delete ​

POST/admin/v1/positions/delete

Delete positions of any accounts

The Positions list delete: like the single-account route over 1-1000 position ids of any accounts. Answers every id in id order with its login and result: deleted, not_found, forbidden or error (with error). Runs in execution under the account's lock and is written to the trade log as one correction event (sent to the account's open terminals). A refusal by execution comes back as an error with its code.

More details

Rights: the staff member needs every one of: trades.edit, trades.delete.

Parameters
Idempotency-Keystring · header
Optional UUID used as the correction request id: a retry with the same key is applied once.
Request body
idsinteger[]
Returns
Promise<DeleteResult>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.csrf_invalid: request refused: reload the page and try again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
403trade.disabled: trading is disabled
500internal: something went wrong
504trade.timeout: request timed out
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.delete({
  ids: [
    20451,
    31877
  ]
})
bash
curl -X POST "$NOVIQA_API_URL/admin/v1/positions/delete" \
  -H "Authorization: Bearer $NOVIQA_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
  "ids": [
    20451,
    31877
  ]
}'
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "deleted": 1,
    "items": [
      {
        "error": "string",
        "id": 1,
        "login": 1001,
        "result": "string"
      }
    ]
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.delete(body: account.idList, options?: RequestOptions): Promise<account.DeleteResult>

payments ​

POST/admin/v1/positions/payments

Pay by positions

MT5 Bulk Payments by Positions, Process: one balance operation per item and side with a non-zero amount (amount_buy with the buy action and comment, amount_sell with sell's; in net mode amount with side's), through the same path as POST /admin/v1/balance/bulk: each checked and journaled on its own. skip_margin_check as there; with confirm_actions send confirm_token / confirm_code. The buy (or net) payment uses the item's request_id, the sell payment the UUIDv5 of it and "sell" (uuid.NewSHA1), so a repeat never pays twice. Answers one row per payment: login, side, request_id, amount, status, code, message, deal_id.

More details

Rights: the staff member needs every one of: accounts.balance.

Request body
buyany
action and comment of buy-side payments
confirm_codestring
the code as the user typed it
confirm_tokenstring
from POST /admin/v1/confirmations
itemsobject[]
sellany
action and comment of sell-side payments
skip_margin_checkboolean
Returns
Promise<PaymentResult[]>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.csrf_invalid: request refused: reload the page and try again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403confirmation_required: confirm this action with the code shown
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.payments({
  buy: {
    action: "dividend",
    comment: "AA dividend"
  },
  items: [
    {
      amount_buy: "0.68",
      amount_sell: "-0.20",
      login: 100234,
      request_id: "0b8e2f4a-6c1d-4e3b-9a7f-5d2c1b0a9e8f"
    }
  ],
  sell: {
    action: "charge",
    comment: "AA dividend"
  },
  skip_margin_check: false
})
bash
curl -X POST "$NOVIQA_API_URL/admin/v1/positions/payments" \
  -H "Authorization: Bearer $NOVIQA_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
  "buy": {
    "action": "dividend",
    "comment": "AA dividend"
  },
  "items": [
    {
      "amount_buy": "0.68",
      "amount_sell": "-0.20",
      "login": 100234,
      "request_id": "0b8e2f4a-6c1d-4e3b-9a7f-5d2c1b0a9e8f"
    }
  ],
  "sell": {
    "action": "charge",
    "comment": "AA dividend"
  },
  "skip_margin_check": false
}'
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": [
    {
      "amount": "1.08452",
      "code": "ok",
      "deal_id": 1,
      "login": 1001,
      "message": "string",
      "request_id": "3f2a9c1e-8b7d-4e6f-a5c4-1b2d3e4f5a6b",
      "side": "string",
      "status": "done"
    }
  ],
  "request_id": "5b7f2c1e"
}
ts
staff.positions.payments(body: account.PaymentsRun, options?: RequestOptions): Promise<account.PaymentResult[]>

paymentsPreview ​

POST/admin/v1/positions/payments/preview

Preview payments by positions

MT5 Bulk Payments by Positions, Calculate: for every account in groups with open positions in symbols (comma separated masks of symbol paths or names) sums the buy and sell lots and prices the payment: amount = lots × amount_per_lot × (1 − tax_percent / 100) × rate, rounded to the account currency digits. With net the net volume (buy − sell) is paid with the settings of its side (amount, net_side). A side's currency other than the account's needs a rate in rates ("FROM->TO": rate); rates_needed lists every conversion with the rate given (0 when missing, and those amounts are left out). Current positions only: past dates are not supported. Nothing is paid.

More details

Rights: the staff member needs every one of: accounts.balance.

Request body
buyPaymentSide
PaymentSide is how one side (buy or sell positions) is paid.
groupsstring
group mask, "" or "*" = every group in scope
netboolean
pay net volume (buy − sell) instead of each side
ratesobject
"FROM->TO": rate, payment currency to account currency
sellPaymentSide
PaymentSide is how one side (buy or sell positions) is paid.
symbolsstring
comma separated masks of symbol paths or names, e.g. "Stocks\*, CFD\AA"
Returns
Promise<PaymentsPreview>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.csrf_invalid: request refused: reload the page and try again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.paymentsPreview({
  buy: {
    action: "dividend",
    amount_per_lot: "10",
    comment: "AA dividend",
    currency: "USD",
    tax_percent: "3"
  },
  groups: "*",
  net: false,
  rates: {
    "USD->EUR": "0.92"
  },
  sell: {
    action: "charge",
    amount_per_lot: "-10",
    comment: "AA dividend",
    currency: "USD",
    tax_percent: "0"
  },
  symbols: "Stocks\\*"
})
bash
curl -X POST "$NOVIQA_API_URL/admin/v1/positions/payments/preview" \
  -H "Authorization: Bearer $NOVIQA_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
  "buy": {
    "action": "dividend",
    "amount_per_lot": "10",
    "comment": "AA dividend",
    "currency": "USD",
    "tax_percent": "3"
  },
  "groups": "*",
  "net": false,
  "rates": {
    "USD->EUR": "0.92"
  },
  "sell": {
    "action": "charge",
    "amount_per_lot": "-10",
    "comment": "AA dividend",
    "currency": "USD",
    "tax_percent": "0"
  },
  "symbols": "Stocks\\*"
}'
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "items": [
      {
        "amount": "1.08452",
        "amount_buy": "1.08452",
        "amount_sell": "1.08452",
        "currency": "USD",
        "group": "real\\standard",
        "login": 1001,
        "name": "Ann Smith",
        "net_side": "string",
        "vol_buy": "1.08452",
        "vol_sell": "1.08452"
      }
    ],
    "rates_needed": [
      {
        "from": "string",
        "rate": "1.08452",
        "to": "string"
      }
    ]
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.paymentsPreview(body: account.PaymentsRequest, options?: RequestOptions): Promise<account.PaymentsPreview>

split ​

POST/admin/v1/positions/split

Split positions

MT5 Split Positions, Process: the preview's settings applied. Per account, in execution under the account lock, one trade log event: each position keeps its ticket and is closed at its open price (no profit, its swap stays) and reopened at the new volume and price, two deals with reason split and no commission; clear_sl_tp clears its stop loss and take profit; the adjustment is a separate balance deal (comment split adjustment #ticket, reason split, same position); a position below the minimum is closed at the market with close_below_min, else skipped. Margin is recalculated. adjustments (position id → amount) replace computed adjustments. Adjustments need accounts.balance too (403 otherwise); with confirm_actions send confirm_token / confirm_code (403 confirmation_required). Idempotency-Key (UUID) is each account's request id: a retry is applied once and journaled once. Answers each position: result split (with deal_out, deal_in, adjustment_deal), closed (deal_out), skipped or error (error). Journaled per position (position #T of account 'L' split 7:3: 100 → 233 at 34.91 → 14.96 (adjustment 0.05 USD)).

More details

Rights: the staff member needs every one of: trades.edit.

Parameters
Idempotency-Keystring · header
Optional UUID used as the correction request id: a retry with the same key is applied once.
Request body
adjustmentsobject
Adjustments replace the computed adjustment of positions (position id → amount in the account currency; "0" = none). Processing only.
calculate_adjustmentsboolean
pay the value lost/gained by rounding as a balance operation
clear_sl_tpboolean
close_below_minboolean
close positions the split would leave below the minimum volume
confirm_codestring
the code as the user typed it
confirm_tokenstring
from POST /admin/v1/confirmations
groupsstring
group mask, "" or "*" = every group in scope
loginsinteger[]
new_sharesinteger
old_sharesinteger
price_roundingSplitRounding
SplitRounding is a rounding rule of a split: standard (half away from zero), down (towards zero for these positive values: against the trader) or up. The rule is numeric and the same for buy and sell positions, as in the MT5 examples (35.15 at 2:1 → 17.57 down / 17.58 up whatever the side).
standard down up
symbolstring
volume_roundingSplitRounding
SplitRounding is a rounding rule of a split: standard (half away from zero), down (towards zero for these positive values: against the trader) or up. The rule is numeric and the same for buy and sell positions, as in the MT5 examples (35.15 at 2:1 → 17.57 down / 17.58 up whatever the side).
standard down up
Returns
Promise<SplitReply>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.csrf_invalid: request refused: reload the page and try again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403confirmation_required: confirm this action with the code shown
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.split({
  adjustments: {
    "100096325": "0.05"
  },
  calculate_adjustments: true,
  clear_sl_tp: true,
  groups: "*",
  new_shares: 7,
  old_shares: 3,
  price_rounding: "down",
  symbol: "AA",
  volume_rounding: "down"
})
bash
curl -X POST "$NOVIQA_API_URL/admin/v1/positions/split" \
  -H "Authorization: Bearer $NOVIQA_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
  "adjustments": {
    "100096325": "0.05"
  },
  "calculate_adjustments": true,
  "clear_sl_tp": true,
  "groups": "*",
  "new_shares": 7,
  "old_shares": 3,
  "price_rounding": "down",
  "symbol": "AA",
  "volume_rounding": "down"
}'
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "items": [
      {
        "adjustment": "1.08452",
        "adjustment_deal": 1,
        "deal_in": 1,
        "deal_out": 1,
        "error": "string",
        "login": 1001,
        "new_price": "1.08452",
        "new_volume": "1.08452",
        "position_id": 1,
        "result": "string"
      }
    ]
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.split(body: account.SplitRequest, options?: RequestOptions): Promise<account.SplitReply>

splitPreview ​

POST/admin/v1/positions/split/preview

Preview a stock split of positions

MT5 Split Positions, Calculate: for the open positions of symbol in the groups of groups (a mask, "*" = all in scope; optionally only logins) works out a split of new_shares:old_shares (both 1-1000000). new_volume = volume × New/Old counted in contracts and rounded by volume_rounding at the precision of the volume step in contracts, then back in lots and always rounded down to the volume step (no volume is added). new_price = price × Old/New rounded by price_rounding to the symbol digits. Rules: standard (half away from zero), down, up; numeric, the same for buy and sell (MT5: 35.15 at 2:1 → 17.57 down / 17.58 up; 1.19 lots 1:3 up, contract 100000, step 0.01 → 0.39). old_value / new_value are volume × contract size × price × the position's profit rate (account currency); with calculate_adjustments adjustment = old_value − new_value rounded to the currency digits, positive credited to the client. A new volume below the symbol minimum is action skip (reason), or close with close_below_min. Nothing changes. Rows in position order with account name, group, currency. Up to 1000 positions.

More details

Rights: the staff member needs every one of: trades.view.

Request body
adjustmentsobject
Adjustments replace the computed adjustment of positions (position id → amount in the account currency; "0" = none). Processing only.
calculate_adjustmentsboolean
pay the value lost/gained by rounding as a balance operation
clear_sl_tpboolean
close_below_minboolean
close positions the split would leave below the minimum volume
confirm_codestring
the code as the user typed it
confirm_tokenstring
from POST /admin/v1/confirmations
groupsstring
group mask, "" or "*" = every group in scope
loginsinteger[]
new_sharesinteger
old_sharesinteger
price_roundingSplitRounding
SplitRounding is a rounding rule of a split: standard (half away from zero), down (towards zero for these positive values: against the trader) or up. The rule is numeric and the same for buy and sell positions, as in the MT5 examples (35.15 at 2:1 → 17.57 down / 17.58 up whatever the side).
standard down up
symbolstring
volume_roundingSplitRounding
SplitRounding is a rounding rule of a split: standard (half away from zero), down (towards zero for these positive values: against the trader) or up. The rule is numeric and the same for buy and sell positions, as in the MT5 examples (35.15 at 2:1 → 17.57 down / 17.58 up whatever the side).
standard down up
Returns
Promise<SplitPreviewReply>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.csrf_invalid: request refused: reload the page and try again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.splitPreview({
  calculate_adjustments: true,
  clear_sl_tp: true,
  close_below_min: false,
  groups: "*",
  new_shares: 7,
  old_shares: 3,
  price_rounding: "down",
  symbol: "AA",
  volume_rounding: "down"
})
bash
curl -X POST "$NOVIQA_API_URL/admin/v1/positions/split/preview" \
  -H "Authorization: Bearer $NOVIQA_TOKEN" \
  -H "Content-Type: application/json" \
  --data-raw '{
  "calculate_adjustments": true,
  "clear_sl_tp": true,
  "close_below_min": false,
  "groups": "*",
  "new_shares": 7,
  "old_shares": 3,
  "price_rounding": "down",
  "symbol": "AA",
  "volume_rounding": "down"
}'
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "items": [
      {
        "action": "string",
        "adjustment": "1.08452",
        "currency": "USD",
        "group": "real\\standard",
        "login": 1001,
        "name": "Ann Smith",
        "new_price": "1.08452",
        "new_value": "1.08452",
        "new_volume": "1.08452",
        "old_value": "1.08452",
        "position_id": 1,
        "price": "1.08452"
      }
    ]
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.splitPreview(body: account.SplitRequest, options?: RequestOptions): Promise<account.SplitPreviewReply>

window ​

GET/admin/v1/positions/window

Read a bounded positions window

At most 100 positions in deterministic stored-field order, using first/last/after/before/around keyset navigation. All current trading scope and hidden-account permissions apply. IDs and decimals are lossless strings; dealer may be null. Filter is a JSON array of typed AND predicates. Live profit/current-price ranking is unsupported. The deals projection sequence and rows share one repeatable-read snapshot; a requested minimum ahead of projection returns projection_pending without rows or proof. Query-bound cursors confer no authority. Proof and valuation remain unavailable until separately proven.

More details

Rights: the staff member needs every one of: trades.view.

Parameters
limitinteger · query
edgestring · query
cursorstring · query
anchor_idstring · query
sort_fieldstring · query
sort_directionstring · query
filterstring · query
searchstring · query
loginstring · query
symbolstring · query
groupstring · query
companystring · query
min_projection_seqstring · query
Returns
Promise<PositionWindowPage>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.window({
  limit: 1,
  edge: "string",
  anchor_id: "string"
})
bash
curl -X GET "$NOVIQA_API_URL/admin/v1/positions/window?limit=1&edge=string&anchor_id=string" \
  -H "Authorization: Bearer $NOVIQA_TOKEN"
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "after": "string",
    "before": "string",
    "calculated_at": "2026-09-25T10:15:00Z",
    "consistency": "string",
    "first_key": "string",
    "has_after": true,
    "has_before": true,
    "items": [
      {
        "comment": "Deposit via bank",
        "contract_size": "string",
        "dealer": "string",
        "digits": 5,
        "external_id": "string",
        "group": "real\\standard",
        "id": "string",
        "login": 1001,
        "margin": "108.45",
        "opened_at": "2026-09-25T10:15:00Z",
        "price_current": "string",
        "price_open": "string"
      }
    ],
    "last_key": "string",
    "page_id": "string",
    "projection_seq": "string",
    "proof": "string"
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.window(query?: { limit?, edge?, cursor?, anchor_id?, sort_field?, sort_direction?, filter?, search?, login?, symbol?, group?, company?, min_projection_seq? }, options?: RequestOptions): Promise<account.PositionWindowPage>

windowCount ​

GET/admin/v1/positions/window/count

Count a filtered positions window

Exact full-filter count with the same typed predicates and authorization as positions/window. Does not materialize rows or value positions. Pagination does not restrict total. Total is null when the requested minimum projection sequence is ahead; legacy positions/count is unchanged.

More details

Rights: the staff member needs every one of: trades.view.

Parameters
limitinteger · query
edgestring · query
cursorstring · query
anchor_idstring · query
sort_fieldstring · query
sort_directionstring · query
filterstring · query
searchstring · query
loginstring · query
symbolstring · query
groupstring · query
companystring · query
min_projection_seqstring · query
Returns
Promise<PositionWindowCount>
The answer's data.
Errors
400invalid_input: invalid input
401auth.session_expired: session expired, sign in again
403auth.invalid_terminal: this terminal cannot be used here
403auth.otp_enrol_required: your group requires one-time codes: set them up to continue
403auth.password_change_required: you must change your password first
403forbidden: you do not have access to this action
500internal: something went wrong
ts
import { staff } from "@/lib/noviqa"

const data = await staff.positions.windowCount({
  limit: 1,
  edge: "string",
  anchor_id: "string"
})
bash
curl -X GET "$NOVIQA_API_URL/admin/v1/positions/window/count?limit=1&edge=string&anchor_id=string" \
  -H "Authorization: Bearer $NOVIQA_TOKEN"
json
{
  "success": true,
  "code": "ok",
  "message": "done",
  "data": {
    "consistency": "string",
    "projection_seq": "string",
    "query_id": "string",
    "resource": "string",
    "retry_after_ms": 1,
    "total": 1
  },
  "request_id": "5b7f2c1e"
}
ts
staff.positions.windowCount(query?: { limit?, edge?, cursor?, anchor_id?, sort_field?, sort_direction?, filter?, search?, login?, symbol?, group?, company?, min_projection_seq? }, options?: RequestOptions): Promise<account.PositionWindowCount>